1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.71 for PHP 8.1.1.
4#
5# Report bugs to <https://bugs.php.net>.
6#
7#
8# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
9# Inc.
10#
11#
12# This configure script is free software; the Free Software Foundation
13# gives unlimited permission to copy, distribute and modify it.
14## -------------------- ##
15## M4sh Initialization. ##
16## -------------------- ##
17
18# Be more Bourne compatible
19DUALCASE=1; export DUALCASE # for MKS sh
20as_nop=:
21if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
22then :
23  emulate sh
24  NULLCMD=:
25  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26  # is contrary to our usage.  Disable this feature.
27  alias -g '${1+"$@"}'='"$@"'
28  setopt NO_GLOB_SUBST
29else $as_nop
30  case `(set -o) 2>/dev/null` in #(
31  *posix*) :
32    set -o posix ;; #(
33  *) :
34     ;;
35esac
36fi
37
38
39
40# Reset variables that may have inherited troublesome values from
41# the environment.
42
43# IFS needs to be set, to space, tab, and newline, in precisely that order.
44# (If _AS_PATH_WALK were called with IFS unset, it would have the
45# side effect of setting IFS to empty, thus disabling word splitting.)
46# Quoting is to prevent editors from complaining about space-tab.
47as_nl='
48'
49export as_nl
50IFS=" ""	$as_nl"
51
52PS1='$ '
53PS2='> '
54PS4='+ '
55
56# Ensure predictable behavior from utilities with locale-dependent output.
57LC_ALL=C
58export LC_ALL
59LANGUAGE=C
60export LANGUAGE
61
62# We cannot yet rely on "unset" to work, but we need these variables
63# to be unset--not just set to an empty or harmless value--now, to
64# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
65# also avoids known problems related to "unset" and subshell syntax
66# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
67for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
68do eval test \${$as_var+y} \
69  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
70done
71
72# Ensure that fds 0, 1, and 2 are open.
73if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
74if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
75if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
76
77# The user is always right.
78if ${PATH_SEPARATOR+false} :; then
79  PATH_SEPARATOR=:
80  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
81    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
82      PATH_SEPARATOR=';'
83  }
84fi
85
86
87# Find who we are.  Look in the path if we contain no directory separator.
88as_myself=
89case $0 in #((
90  *[\\/]* ) as_myself=$0 ;;
91  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
92for as_dir in $PATH
93do
94  IFS=$as_save_IFS
95  case $as_dir in #(((
96    '') as_dir=./ ;;
97    */) ;;
98    *) as_dir=$as_dir/ ;;
99  esac
100    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
101  done
102IFS=$as_save_IFS
103
104     ;;
105esac
106# We did not find ourselves, most probably we were run as `sh COMMAND'
107# in which case we are not to be found in the path.
108if test "x$as_myself" = x; then
109  as_myself=$0
110fi
111if test ! -f "$as_myself"; then
112  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113  exit 1
114fi
115
116
117# Use a proper internal environment variable to ensure we don't fall
118  # into an infinite loop, continuously re-executing ourselves.
119  if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
120    _as_can_reexec=no; export _as_can_reexec;
121    # We cannot yet assume a decent shell, so we have to provide a
122# neutralization value for shells without unset; and this also
123# works around shells that cannot unset nonexistent variables.
124# Preserve -v and -x to the replacement shell.
125BASH_ENV=/dev/null
126ENV=/dev/null
127(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
128case $- in # ((((
129  *v*x* | *x*v* ) as_opts=-vx ;;
130  *v* ) as_opts=-v ;;
131  *x* ) as_opts=-x ;;
132  * ) as_opts= ;;
133esac
134exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
135# Admittedly, this is quite paranoid, since all the known shells bail
136# out after a failed `exec'.
137printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
138exit 255
139  fi
140  # We don't want this to propagate to other subprocesses.
141          { _as_can_reexec=; unset _as_can_reexec;}
142if test "x$CONFIG_SHELL" = x; then
143  as_bourne_compatible="as_nop=:
144if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
145then :
146  emulate sh
147  NULLCMD=:
148  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
149  # is contrary to our usage.  Disable this feature.
150  alias -g '\${1+\"\$@\"}'='\"\$@\"'
151  setopt NO_GLOB_SUBST
152else \$as_nop
153  case \`(set -o) 2>/dev/null\` in #(
154  *posix*) :
155    set -o posix ;; #(
156  *) :
157     ;;
158esac
159fi
160"
161  as_required="as_fn_return () { (exit \$1); }
162as_fn_success () { as_fn_return 0; }
163as_fn_failure () { as_fn_return 1; }
164as_fn_ret_success () { return 0; }
165as_fn_ret_failure () { return 1; }
166
167exitcode=0
168as_fn_success || { exitcode=1; echo as_fn_success failed.; }
169as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
170as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
171as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
172if ( set x; as_fn_ret_success y && test x = \"\$1\" )
173then :
174
175else \$as_nop
176  exitcode=1; echo positional parameters were not saved.
177fi
178test x\$exitcode = x0 || exit 1
179blah=\$(echo \$(echo blah))
180test x\"\$blah\" = xblah || exit 1
181test -x / || exit 1"
182  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
183  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
184  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
185  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
186test \$(( 1 + 1 )) = 2 || exit 1"
187  if (eval "$as_required") 2>/dev/null
188then :
189  as_have_required=yes
190else $as_nop
191  as_have_required=no
192fi
193  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
194then :
195
196else $as_nop
197  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
198as_found=false
199for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
200do
201  IFS=$as_save_IFS
202  case $as_dir in #(((
203    '') as_dir=./ ;;
204    */) ;;
205    *) as_dir=$as_dir/ ;;
206  esac
207  as_found=:
208  case $as_dir in #(
209	 /*)
210	   for as_base in sh bash ksh sh5; do
211	     # Try only shells that exist, to save several forks.
212	     as_shell=$as_dir$as_base
213	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
214		    as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
215then :
216  CONFIG_SHELL=$as_shell as_have_required=yes
217		   if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
218then :
219  break 2
220fi
221fi
222	   done;;
223       esac
224  as_found=false
225done
226IFS=$as_save_IFS
227if $as_found
228then :
229
230else $as_nop
231  if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
232	      as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
233then :
234  CONFIG_SHELL=$SHELL as_have_required=yes
235fi
236fi
237
238
239      if test "x$CONFIG_SHELL" != x
240then :
241  export CONFIG_SHELL
242             # We cannot yet assume a decent shell, so we have to provide a
243# neutralization value for shells without unset; and this also
244# works around shells that cannot unset nonexistent variables.
245# Preserve -v and -x to the replacement shell.
246BASH_ENV=/dev/null
247ENV=/dev/null
248(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
249case $- in # ((((
250  *v*x* | *x*v* ) as_opts=-vx ;;
251  *v* ) as_opts=-v ;;
252  *x* ) as_opts=-x ;;
253  * ) as_opts= ;;
254esac
255exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
256# Admittedly, this is quite paranoid, since all the known shells bail
257# out after a failed `exec'.
258printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
259exit 255
260fi
261
262    if test x$as_have_required = xno
263then :
264  printf "%s\n" "$0: This script requires a shell more modern than all"
265  printf "%s\n" "$0: the shells that I found on your system."
266  if test ${ZSH_VERSION+y} ; then
267    printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
268    printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
269  else
270    printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and
271$0: https://bugs.php.net about your system, including any
272$0: error possibly output before this message. Then install
273$0: a modern shell, or manually run the script under such a
274$0: shell if you do have one."
275  fi
276  exit 1
277fi
278fi
279fi
280SHELL=${CONFIG_SHELL-/bin/sh}
281export SHELL
282# Unset more variables known to interfere with behavior of common tools.
283CLICOLOR_FORCE= GREP_OPTIONS=
284unset CLICOLOR_FORCE GREP_OPTIONS
285
286## --------------------- ##
287## M4sh Shell Functions. ##
288## --------------------- ##
289# as_fn_unset VAR
290# ---------------
291# Portably unset VAR.
292as_fn_unset ()
293{
294  { eval $1=; unset $1;}
295}
296as_unset=as_fn_unset
297
298
299# as_fn_set_status STATUS
300# -----------------------
301# Set $? to STATUS, without forking.
302as_fn_set_status ()
303{
304  return $1
305} # as_fn_set_status
306
307# as_fn_exit STATUS
308# -----------------
309# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
310as_fn_exit ()
311{
312  set +e
313  as_fn_set_status $1
314  exit $1
315} # as_fn_exit
316# as_fn_nop
317# ---------
318# Do nothing but, unlike ":", preserve the value of $?.
319as_fn_nop ()
320{
321  return $?
322}
323as_nop=as_fn_nop
324
325# as_fn_mkdir_p
326# -------------
327# Create "$as_dir" as a directory, including parents if necessary.
328as_fn_mkdir_p ()
329{
330
331  case $as_dir in #(
332  -*) as_dir=./$as_dir;;
333  esac
334  test -d "$as_dir" || eval $as_mkdir_p || {
335    as_dirs=
336    while :; do
337      case $as_dir in #(
338      *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
339      *) as_qdir=$as_dir;;
340      esac
341      as_dirs="'$as_qdir' $as_dirs"
342      as_dir=`$as_dirname -- "$as_dir" ||
343$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
344	 X"$as_dir" : 'X\(//\)[^/]' \| \
345	 X"$as_dir" : 'X\(//\)$' \| \
346	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
347printf "%s\n" X"$as_dir" |
348    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
349	    s//\1/
350	    q
351	  }
352	  /^X\(\/\/\)[^/].*/{
353	    s//\1/
354	    q
355	  }
356	  /^X\(\/\/\)$/{
357	    s//\1/
358	    q
359	  }
360	  /^X\(\/\).*/{
361	    s//\1/
362	    q
363	  }
364	  s/.*/./; q'`
365      test -d "$as_dir" && break
366    done
367    test -z "$as_dirs" || eval "mkdir $as_dirs"
368  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
369
370
371} # as_fn_mkdir_p
372
373# as_fn_executable_p FILE
374# -----------------------
375# Test if FILE is an executable regular file.
376as_fn_executable_p ()
377{
378  test -f "$1" && test -x "$1"
379} # as_fn_executable_p
380# as_fn_append VAR VALUE
381# ----------------------
382# Append the text in VALUE to the end of the definition contained in VAR. Take
383# advantage of any shell optimizations that allow amortized linear growth over
384# repeated appends, instead of the typical quadratic growth present in naive
385# implementations.
386if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
387then :
388  eval 'as_fn_append ()
389  {
390    eval $1+=\$2
391  }'
392else $as_nop
393  as_fn_append ()
394  {
395    eval $1=\$$1\$2
396  }
397fi # as_fn_append
398
399# as_fn_arith ARG...
400# ------------------
401# Perform arithmetic evaluation on the ARGs, and store the result in the
402# global $as_val. Take advantage of shells that can avoid forks. The arguments
403# must be portable across $(()) and expr.
404if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
405then :
406  eval 'as_fn_arith ()
407  {
408    as_val=$(( $* ))
409  }'
410else $as_nop
411  as_fn_arith ()
412  {
413    as_val=`expr "$@" || test $? -eq 1`
414  }
415fi # as_fn_arith
416
417# as_fn_nop
418# ---------
419# Do nothing but, unlike ":", preserve the value of $?.
420as_fn_nop ()
421{
422  return $?
423}
424as_nop=as_fn_nop
425
426# as_fn_error STATUS ERROR [LINENO LOG_FD]
427# ----------------------------------------
428# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
429# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
430# script with STATUS, using 1 if that was 0.
431as_fn_error ()
432{
433  as_status=$1; test $as_status -eq 0 && as_status=1
434  if test "$4"; then
435    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
436    printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
437  fi
438  printf "%s\n" "$as_me: error: $2" >&2
439  as_fn_exit $as_status
440} # as_fn_error
441
442if expr a : '\(a\)' >/dev/null 2>&1 &&
443   test "X`expr 00001 : '.*\(...\)'`" = X001; then
444  as_expr=expr
445else
446  as_expr=false
447fi
448
449if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
450  as_basename=basename
451else
452  as_basename=false
453fi
454
455if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
456  as_dirname=dirname
457else
458  as_dirname=false
459fi
460
461as_me=`$as_basename -- "$0" ||
462$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
463	 X"$0" : 'X\(//\)$' \| \
464	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
465printf "%s\n" X/"$0" |
466    sed '/^.*\/\([^/][^/]*\)\/*$/{
467	    s//\1/
468	    q
469	  }
470	  /^X\/\(\/\/\)$/{
471	    s//\1/
472	    q
473	  }
474	  /^X\/\(\/\).*/{
475	    s//\1/
476	    q
477	  }
478	  s/.*/./; q'`
479
480# Avoid depending upon Character Ranges.
481as_cr_letters='abcdefghijklmnopqrstuvwxyz'
482as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
483as_cr_Letters=$as_cr_letters$as_cr_LETTERS
484as_cr_digits='0123456789'
485as_cr_alnum=$as_cr_Letters$as_cr_digits
486
487
488  as_lineno_1=$LINENO as_lineno_1a=$LINENO
489  as_lineno_2=$LINENO as_lineno_2a=$LINENO
490  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
491  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
492  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
493  sed -n '
494    p
495    /[$]LINENO/=
496  ' <$as_myself |
497    sed '
498      s/[$]LINENO.*/&-/
499      t lineno
500      b
501      :lineno
502      N
503      :loop
504      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
505      t loop
506      s/-\n.*//
507    ' >$as_me.lineno &&
508  chmod +x "$as_me.lineno" ||
509    { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
510
511  # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
512  # already done that, so ensure we don't try to do so again and fall
513  # in an infinite loop.  This has already happened in practice.
514  _as_can_reexec=no; export _as_can_reexec
515  # Don't try to exec as it changes $[0], causing all sort of problems
516  # (the dirname of $[0] is not the place where we might find the
517  # original and so on.  Autoconf is especially sensitive to this).
518  . "./$as_me.lineno"
519  # Exit status is that of the last command.
520  exit
521}
522
523
524# Determine whether it's possible to make 'echo' print without a newline.
525# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
526# for compatibility with existing Makefiles.
527ECHO_C= ECHO_N= ECHO_T=
528case `echo -n x` in #(((((
529-n*)
530  case `echo 'xy\c'` in
531  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
532  xy)  ECHO_C='\c';;
533  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
534       ECHO_T='	';;
535  esac;;
536*)
537  ECHO_N='-n';;
538esac
539
540# For backward compatibility with old third-party macros, we provide
541# the shell variables $as_echo and $as_echo_n.  New code should use
542# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
543as_echo='printf %s\n'
544as_echo_n='printf %s'
545
546
547rm -f conf$$ conf$$.exe conf$$.file
548if test -d conf$$.dir; then
549  rm -f conf$$.dir/conf$$.file
550else
551  rm -f conf$$.dir
552  mkdir conf$$.dir 2>/dev/null
553fi
554if (echo >conf$$.file) 2>/dev/null; then
555  if ln -s conf$$.file conf$$ 2>/dev/null; then
556    as_ln_s='ln -s'
557    # ... but there are two gotchas:
558    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
559    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
560    # In both cases, we have to default to `cp -pR'.
561    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
562      as_ln_s='cp -pR'
563  elif ln conf$$.file conf$$ 2>/dev/null; then
564    as_ln_s=ln
565  else
566    as_ln_s='cp -pR'
567  fi
568else
569  as_ln_s='cp -pR'
570fi
571rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
572rmdir conf$$.dir 2>/dev/null
573
574if mkdir -p . 2>/dev/null; then
575  as_mkdir_p='mkdir -p "$as_dir"'
576else
577  test -d ./-p && rmdir ./-p
578  as_mkdir_p=false
579fi
580
581as_test_x='test -x'
582as_executable_p=as_fn_executable_p
583
584# Sed expression to map a string onto a valid CPP name.
585as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
586
587# Sed expression to map a string onto a valid variable name.
588as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
589
590
591
592# Check that we are running under the correct shell.
593SHELL=${CONFIG_SHELL-/bin/sh}
594
595case X$ECHO in
596X*--fallback-echo)
597  # Remove one level of quotation (which was required for Make).
598  ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','`
599  ;;
600esac
601
602echo=${ECHO-echo}
603if test "X$1" = X--no-reexec; then
604  # Discard the --no-reexec flag, and continue.
605  shift
606elif test "X$1" = X--fallback-echo; then
607  # Avoid inline document here, it may be left over
608  :
609elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
610  # Yippee, $echo works!
611  :
612else
613  # Restart under the correct shell.
614  exec $SHELL "$0" --no-reexec ${1+"$@"}
615fi
616
617if test "X$1" = X--fallback-echo; then
618  # used as fallback echo
619  shift
620  cat <<EOF
621$*
622EOF
623  exit 0
624fi
625
626# The HP-UX ksh and POSIX shell print the target directory to stdout
627# if CDPATH is set.
628(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
629
630if test -z "$ECHO"; then
631if test "X${echo_test_string+set}" != Xset; then
632# find a string as large as possible, as long as the shell can cope with it
633  for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
634    # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
635    if (echo_test_string=`eval $cmd`) 2>/dev/null &&
636       echo_test_string=`eval $cmd` &&
637       (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
638    then
639      break
640    fi
641  done
642fi
643
644if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
645   echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
646   test "X$echo_testing_string" = "X$echo_test_string"; then
647  :
648else
649  # The Solaris, AIX, and Digital Unix default echo programs unquote
650  # backslashes.  This makes it impossible to quote backslashes using
651  #   echo "$something" | sed 's/\\/\\\\/g'
652  #
653  # So, first we look for a working echo in the user's PATH.
654
655  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
656  for dir in $PATH /usr/ucb; do
657    IFS="$lt_save_ifs"
658    if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
659       test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
660       echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
661       test "X$echo_testing_string" = "X$echo_test_string"; then
662      echo="$dir/echo"
663      break
664    fi
665  done
666  IFS="$lt_save_ifs"
667
668  if test "X$echo" = Xecho; then
669    # We didn't find a better echo, so look for alternatives.
670    if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
671       echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
672       test "X$echo_testing_string" = "X$echo_test_string"; then
673      # This shell has a builtin print -r that does the trick.
674      echo='print -r'
675    elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
676	 test "X$CONFIG_SHELL" != X/bin/ksh; then
677      # If we have ksh, try running configure again with it.
678      ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
679      export ORIGINAL_CONFIG_SHELL
680      CONFIG_SHELL=/bin/ksh
681      export CONFIG_SHELL
682      exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
683    else
684      # Try using printf.
685      echo='printf %s\n'
686      if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
687	 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
688	 test "X$echo_testing_string" = "X$echo_test_string"; then
689	# Cool, printf works
690	:
691      elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
692	   test "X$echo_testing_string" = 'X\t' &&
693	   echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
694	   test "X$echo_testing_string" = "X$echo_test_string"; then
695	CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
696	export CONFIG_SHELL
697	SHELL="$CONFIG_SHELL"
698	export SHELL
699	echo="$CONFIG_SHELL $0 --fallback-echo"
700      elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
701	   test "X$echo_testing_string" = 'X\t' &&
702	   echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
703	   test "X$echo_testing_string" = "X$echo_test_string"; then
704	echo="$CONFIG_SHELL $0 --fallback-echo"
705      else
706	# maybe with a smaller string...
707	prev=:
708
709	for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
710	  if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
711	  then
712	    break
713	  fi
714	  prev="$cmd"
715	done
716
717	if test "$prev" != 'sed 50q "$0"'; then
718	  echo_test_string=`eval $prev`
719	  export echo_test_string
720	  exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
721	else
722	  # Oops.  We lost completely, so just stick with echo.
723	  echo=echo
724	fi
725      fi
726    fi
727  fi
728fi
729fi
730
731# Copy echo and quote the copy suitably for passing to libtool from
732# the Makefile, instead of quoting the original, which is used later.
733ECHO=$echo
734if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
735   ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
736fi
737
738
739
740
741tagnames=${tagnames+${tagnames},}CXX
742
743test -n "$DJDIR" || exec 7<&0 </dev/null
744exec 6>&1
745
746# Name of the host.
747# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
748# so uname gets run too.
749ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
750
751#
752# Initializations.
753#
754ac_default_prefix=/usr/local
755ac_clean_files=
756ac_config_libobj_dir=.
757LIBOBJS=
758cross_compiling=no
759subdirs=
760MFLAGS=
761MAKEFLAGS=
762
763# Identity of this package.
764PACKAGE_NAME='PHP'
765PACKAGE_TARNAME='php'
766PACKAGE_VERSION='8.1.1'
767PACKAGE_STRING='PHP 8.1.1'
768PACKAGE_BUGREPORT='https://bugs.php.net'
769PACKAGE_URL='https://www.php.net'
770
771ac_unique_file="main/php_version.h"
772# Factoring default headers for most tests.
773ac_includes_default="\
774#include <stddef.h>
775#ifdef HAVE_STDIO_H
776# include <stdio.h>
777#endif
778#ifdef HAVE_STDLIB_H
779# include <stdlib.h>
780#endif
781#ifdef HAVE_STRING_H
782# include <string.h>
783#endif
784#ifdef HAVE_INTTYPES_H
785# include <inttypes.h>
786#endif
787#ifdef HAVE_STDINT_H
788# include <stdint.h>
789#endif
790#ifdef HAVE_STRINGS_H
791# include <strings.h>
792#endif
793#ifdef HAVE_SYS_TYPES_H
794# include <sys/types.h>
795#endif
796#ifdef HAVE_SYS_STAT_H
797# include <sys/stat.h>
798#endif
799#ifdef HAVE_UNISTD_H
800# include <unistd.h>
801#endif"
802
803ac_header_c_list=
804ac_subst_vars='LTLIBOBJS
805LIBTOOL
806NMEDIT
807DSYMUTIL
808STRIP
809RANLIB
810AR
811ECHO
812AR_FLAGS
813PHP_VERSION_ID
814PHP_VERSION
815PHP_LIBS
816PHP_LDFLAGS
817PEAR_INSTALLDIR
818NATIVE_RPATHS
819INSTALL_IT
820EXTRA_INCLUDES
821INCLUDES
822ZEND_EXTRA_LIBS
823EXTRA_LIBS
824EXTRA_LDFLAGS_PROGRAM
825EXTRA_LDFLAGS
826EXTENSION_DIR
827DEBUG_CFLAGS
828program_suffix
829program_prefix
830abs_srcdir
831abs_builddir
832PHP_INSTALLED_SAPIS
833EXPANDED_PHP_CONFIG_FILE_SCAN_DIR
834EXPANDED_PHP_CONFIG_FILE_PATH
835EXPANDED_LOCALSTATEDIR
836EXPANDED_SYSCONFDIR
837EXPANDED_DATADIR
838EXPANDED_LIBDIR
839EXPANDED_MANDIR
840EXPANDED_SBINDIR
841EXPANDED_BINDIR
842EXPANDED_EXTENSION_DIR
843EXPANDED_PEAR_INSTALLDIR
844INCLUDE_PATH
845LIBZIP_LIBS
846LIBZIP_CFLAGS
847EXSLT_LIBS
848EXSLT_CFLAGS
849XSL_LIBS
850XSL_CFLAGS
851EXPAT_LIBS
852EXPAT_CFLAGS
853ARGON2_LIBS
854ARGON2_CFLAGS
855LIBSODIUM_LIBS
856LIBSODIUM_CFLAGS
857SNMP_CONFIG
858EDIT_LIBS
859EDIT_CFLAGS
860PDO_OCI_VERSION
861PDO_OCI_DIR
862PDO_OCI_SHARED_LIBADD
863PDO_MYSQL_MODULE_TYPE
864FB_CONFIG
865CAPSTONE_LIBS
866CAPSTONE_CFLAGS
867ODBC_TYPE
868ODBC_LFLAGS
869ODBC_LIBS
870ODBC_CFLAGS
871OCI8_ORACLE_VERSION
872OCI8_DIR
873OCI8_SHARED_LIBADD
874ONIG_LIBS
875ONIG_CFLAGS
876SASL_LIBS
877SASL_CFLAGS
878HAVE_CXX11
879ICU_LIBS
880ICU_CFLAGS
881GDLIB_LIBS
882GDLIB_CFLAGS
883FREETYPE2_LIBS
884FREETYPE2_CFLAGS
885XPM_LIBS
886XPM_CFLAGS
887JPEG_LIBS
888JPEG_CFLAGS
889WEBP_LIBS
890WEBP_CFLAGS
891AVIF_LIBS
892AVIF_CFLAGS
893PNG_LIBS
894PNG_CFLAGS
895FFI_LIBS
896FFI_CFLAGS
897ENCHANT_LIBS
898ENCHANT_CFLAGS
899ENCHANT2_LIBS
900ENCHANT2_CFLAGS
901CURL_FEATURES
902CURL_LIBS
903CURL_CFLAGS
904ZLIB_LIBS
905ZLIB_CFLAGS
906SQLITE_LIBS
907SQLITE_CFLAGS
908PCRE2_LIBS
909PCRE2_CFLAGS
910OPENSSL_LIBS
911OPENSSL_CFLAGS
912KERBEROS_LIBS
913KERBEROS_CFLAGS
914LIBXML_LIBS
915LIBXML_CFLAGS
916VALGRIND_LIBS
917VALGRIND_CFLAGS
918ALLOCA
919LIBOBJS
920PROG_SENDMAIL
921CXXCPP
922ac_ct_CXX
923CXXFLAGS
924CXX
925php_fpm_prefix
926php_fpm_localstatedir
927php_fpm_sysconfdir
928php_fpm_group
929php_fpm_user
930php_fpm_systemd
931SYSTEMD_LIBS
932SYSTEMD_CFLAGS
933SHLIB_DL_SUFFIX_NAME
934SHLIB_SUFFIX_NAME
935PHP
936RE2C
937YFLAGS
938YACC
939AWK
940BUILD_CC
941LN_S
942CPP
943OBJEXT
944EXEEXT
945ac_ct_CC
946CPPFLAGS
947LDFLAGS
948CFLAGS
949CC
950PKG_CONFIG_LIBDIR
951PKG_CONFIG_PATH
952PKG_CONFIG
953target_os
954target_vendor
955target_cpu
956target
957host_os
958host_vendor
959host_cpu
960host
961build_os
962build_vendor
963build_cpu
964build
965CONFIGURE_OPTIONS
966CONFIGURE_COMMAND
967SED
968EGREP
969GREP
970target_alias
971host_alias
972build_alias
973LIBS
974ECHO_T
975ECHO_N
976ECHO_C
977DEFS
978mandir
979localedir
980libdir
981psdir
982pdfdir
983dvidir
984htmldir
985infodir
986docdir
987oldincludedir
988includedir
989runstatedir
990localstatedir
991sharedstatedir
992sysconfdir
993datadir
994datarootdir
995libexecdir
996sbindir
997bindir
998program_transform_name
999prefix
1000exec_prefix
1001PACKAGE_URL
1002PACKAGE_BUGREPORT
1003PACKAGE_STRING
1004PACKAGE_VERSION
1005PACKAGE_TARNAME
1006PACKAGE_NAME
1007PATH_SEPARATOR
1008SHELL'
1009ac_subst_files=''
1010ac_user_opts='
1011enable_option_checking
1012with_libdir
1013enable_rpath
1014enable_re2c_cgoto
1015enable_gcc_global_regs
1016enable_
1017with_apxs2
1018enable_cli
1019enable_embed
1020enable_fpm
1021with_fpm_user
1022with_fpm_group
1023with_fpm_systemd
1024with_fpm_acl
1025with_fpm_apparmor
1026enable_fuzzer
1027enable_fuzzer_msan
1028enable_litespeed
1029enable_phpdbg
1030enable_phpdbg_debug
1031enable_phpdbg_readline
1032enable_cgi
1033with_valgrind
1034enable_gcov
1035enable_debug
1036enable_debug_assertions
1037enable_zts
1038enable_rtld_now
1039with_layout
1040with_config_file_path
1041with_config_file_scan_dir
1042enable_sigchild
1043enable_libgcc
1044enable_short_tags
1045enable_dmalloc
1046enable_ipv6
1047enable_dtrace
1048enable_fd_setsize
1049enable_werror
1050enable_memory_sanitizer
1051enable_address_sanitizer
1052enable_undefined_sanitizer
1053enable_all
1054with_libxml
1055with_openssl
1056with_kerberos
1057with_system_ciphers
1058with_external_pcre
1059with_pcre_jit
1060with_sqlite3
1061with_zlib
1062enable_bcmath
1063with_bz2
1064enable_calendar
1065enable_ctype
1066with_curl
1067enable_dba
1068with_qdbm
1069with_gdbm
1070with_ndbm
1071with_db4
1072with_db3
1073with_db2
1074with_db1
1075with_dbm
1076with_tcadb
1077with_lmdb
1078with_cdb
1079enable_inifile
1080enable_flatfile
1081enable_dom
1082with_enchant
1083enable_exif
1084with_ffi
1085enable_fileinfo
1086enable_filter
1087enable_ftp
1088with_openssl_dir
1089enable_gd
1090with_external_gd
1091with_avif
1092with_webp
1093with_jpeg
1094with_xpm
1095with_freetype
1096enable_gd_jis_conv
1097with_gettext
1098with_gmp
1099with_mhash
1100with_iconv
1101with_imap
1102with_imap_ssl
1103enable_intl
1104with_ldap
1105with_ldap_sasl
1106enable_mbstring
1107enable_mbregex
1108with_mysqli
1109with_mysql_sock
1110with_oci8
1111with_odbcver
1112with_adabas
1113with_sapdb
1114with_solid
1115with_ibm_db2
1116with_empress
1117with_empress_bcs
1118with_custom_odbc
1119with_iodbc
1120with_esoob
1121with_unixODBC
1122with_dbmaker
1123enable_opcache
1124enable_huge_code_pages
1125enable_opcache_jit
1126enable_pcntl
1127enable_pdo
1128with_pdo_dblib
1129with_pdo_firebird
1130with_pdo_mysql
1131with_zlib_dir
1132with_pdo_oci
1133with_pdo_odbc
1134with_pdo_pgsql
1135with_pdo_sqlite
1136with_pgsql
1137enable_phar
1138enable_posix
1139with_pspell
1140with_libedit
1141with_readline
1142enable_session
1143with_mm
1144enable_shmop
1145enable_simplexml
1146with_snmp
1147enable_soap
1148enable_sockets
1149with_sodium
1150with_external_libcrypt
1151with_password_argon2
1152enable_sysvmsg
1153enable_sysvsem
1154enable_sysvshm
1155with_tidy
1156enable_tokenizer
1157enable_xml
1158with_expat
1159enable_xmlreader
1160enable_xmlwriter
1161with_xsl
1162enable_zend_test
1163with_zip
1164enable_mysqlnd
1165enable_mysqlnd_compression_support
1166with_pear
1167enable_fiber_asm
1168enable_zend_signals
1169enable_shared
1170enable_static
1171enable_fast_install
1172with_gnu_ld
1173enable_libtool_lock
1174with_pic
1175with_tags
1176'
1177      ac_precious_vars='build_alias
1178host_alias
1179target_alias
1180PKG_CONFIG
1181PKG_CONFIG_PATH
1182PKG_CONFIG_LIBDIR
1183CC
1184CFLAGS
1185LDFLAGS
1186LIBS
1187CPPFLAGS
1188CPP
1189SYSTEMD_CFLAGS
1190SYSTEMD_LIBS
1191CXX
1192CXXFLAGS
1193CCC
1194CXXCPP
1195VALGRIND_CFLAGS
1196VALGRIND_LIBS
1197LIBXML_CFLAGS
1198LIBXML_LIBS
1199KERBEROS_CFLAGS
1200KERBEROS_LIBS
1201OPENSSL_CFLAGS
1202OPENSSL_LIBS
1203PCRE2_CFLAGS
1204PCRE2_LIBS
1205SQLITE_CFLAGS
1206SQLITE_LIBS
1207ZLIB_CFLAGS
1208ZLIB_LIBS
1209CURL_CFLAGS
1210CURL_LIBS
1211CURL_FEATURES
1212ENCHANT2_CFLAGS
1213ENCHANT2_LIBS
1214ENCHANT_CFLAGS
1215ENCHANT_LIBS
1216FFI_CFLAGS
1217FFI_LIBS
1218PNG_CFLAGS
1219PNG_LIBS
1220AVIF_CFLAGS
1221AVIF_LIBS
1222WEBP_CFLAGS
1223WEBP_LIBS
1224JPEG_CFLAGS
1225JPEG_LIBS
1226XPM_CFLAGS
1227XPM_LIBS
1228FREETYPE2_CFLAGS
1229FREETYPE2_LIBS
1230GDLIB_CFLAGS
1231GDLIB_LIBS
1232ICU_CFLAGS
1233ICU_LIBS
1234SASL_CFLAGS
1235SASL_LIBS
1236ONIG_CFLAGS
1237ONIG_LIBS
1238ODBC_CFLAGS
1239ODBC_LIBS
1240CAPSTONE_CFLAGS
1241CAPSTONE_LIBS
1242EDIT_CFLAGS
1243EDIT_LIBS
1244LIBSODIUM_CFLAGS
1245LIBSODIUM_LIBS
1246ARGON2_CFLAGS
1247ARGON2_LIBS
1248EXPAT_CFLAGS
1249EXPAT_LIBS
1250XSL_CFLAGS
1251XSL_LIBS
1252EXSLT_CFLAGS
1253EXSLT_LIBS
1254LIBZIP_CFLAGS
1255LIBZIP_LIBS'
1256
1257
1258# Initialize some variables set by options.
1259ac_init_help=
1260ac_init_version=false
1261ac_unrecognized_opts=
1262ac_unrecognized_sep=
1263# The variables have the same names as the options, with
1264# dashes changed to underlines.
1265cache_file=/dev/null
1266exec_prefix=NONE
1267no_create=
1268no_recursion=
1269prefix=NONE
1270program_prefix=NONE
1271program_suffix=NONE
1272program_transform_name=s,x,x,
1273silent=
1274site=
1275srcdir=
1276verbose=
1277x_includes=NONE
1278x_libraries=NONE
1279
1280# Installation directory options.
1281# These are left unexpanded so users can "make install exec_prefix=/foo"
1282# and all the variables that are supposed to be based on exec_prefix
1283# by default will actually change.
1284# Use braces instead of parens because sh, perl, etc. also accept them.
1285# (The list follows the same order as the GNU Coding Standards.)
1286bindir='${exec_prefix}/bin'
1287sbindir='${exec_prefix}/sbin'
1288libexecdir='${exec_prefix}/libexec'
1289datarootdir='${prefix}/share'
1290datadir='${datarootdir}'
1291sysconfdir='${prefix}/etc'
1292sharedstatedir='${prefix}/com'
1293localstatedir='${prefix}/var'
1294runstatedir='${localstatedir}/run'
1295includedir='${prefix}/include'
1296oldincludedir='/usr/include'
1297docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1298infodir='${datarootdir}/info'
1299htmldir='${docdir}'
1300dvidir='${docdir}'
1301pdfdir='${docdir}'
1302psdir='${docdir}'
1303libdir='${exec_prefix}/lib'
1304localedir='${datarootdir}/locale'
1305mandir='${datarootdir}/man'
1306
1307ac_prev=
1308ac_dashdash=
1309for ac_option
1310do
1311  # If the previous option needs an argument, assign it.
1312  if test -n "$ac_prev"; then
1313    eval $ac_prev=\$ac_option
1314    ac_prev=
1315    continue
1316  fi
1317
1318  case $ac_option in
1319  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1320  *=)   ac_optarg= ;;
1321  *)    ac_optarg=yes ;;
1322  esac
1323
1324  case $ac_dashdash$ac_option in
1325  --)
1326    ac_dashdash=yes ;;
1327
1328  -bindir | --bindir | --bindi | --bind | --bin | --bi)
1329    ac_prev=bindir ;;
1330  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1331    bindir=$ac_optarg ;;
1332
1333  -build | --build | --buil | --bui | --bu)
1334    ac_prev=build_alias ;;
1335  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1336    build_alias=$ac_optarg ;;
1337
1338  -cache-file | --cache-file | --cache-fil | --cache-fi \
1339  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1340    ac_prev=cache_file ;;
1341  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1342  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1343    cache_file=$ac_optarg ;;
1344
1345  --config-cache | -C)
1346    cache_file=config.cache ;;
1347
1348  -datadir | --datadir | --datadi | --datad)
1349    ac_prev=datadir ;;
1350  -datadir=* | --datadir=* | --datadi=* | --datad=*)
1351    datadir=$ac_optarg ;;
1352
1353  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1354  | --dataroo | --dataro | --datar)
1355    ac_prev=datarootdir ;;
1356  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1357  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1358    datarootdir=$ac_optarg ;;
1359
1360  -disable-* | --disable-*)
1361    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1362    # Reject names that are not valid shell variable names.
1363    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1364      as_fn_error $? "invalid feature name: \`$ac_useropt'"
1365    ac_useropt_orig=$ac_useropt
1366    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1367    case $ac_user_opts in
1368      *"
1369"enable_$ac_useropt"
1370"*) ;;
1371      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1372	 ac_unrecognized_sep=', ';;
1373    esac
1374    eval enable_$ac_useropt=no ;;
1375
1376  -docdir | --docdir | --docdi | --doc | --do)
1377    ac_prev=docdir ;;
1378  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1379    docdir=$ac_optarg ;;
1380
1381  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1382    ac_prev=dvidir ;;
1383  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1384    dvidir=$ac_optarg ;;
1385
1386  -enable-* | --enable-*)
1387    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1388    # Reject names that are not valid shell variable names.
1389    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1390      as_fn_error $? "invalid feature name: \`$ac_useropt'"
1391    ac_useropt_orig=$ac_useropt
1392    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1393    case $ac_user_opts in
1394      *"
1395"enable_$ac_useropt"
1396"*) ;;
1397      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1398	 ac_unrecognized_sep=', ';;
1399    esac
1400    eval enable_$ac_useropt=\$ac_optarg ;;
1401
1402  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1403  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1404  | --exec | --exe | --ex)
1405    ac_prev=exec_prefix ;;
1406  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1407  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1408  | --exec=* | --exe=* | --ex=*)
1409    exec_prefix=$ac_optarg ;;
1410
1411  -gas | --gas | --ga | --g)
1412    # Obsolete; use --with-gas.
1413    with_gas=yes ;;
1414
1415  -help | --help | --hel | --he | -h)
1416    ac_init_help=long ;;
1417  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1418    ac_init_help=recursive ;;
1419  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1420    ac_init_help=short ;;
1421
1422  -host | --host | --hos | --ho)
1423    ac_prev=host_alias ;;
1424  -host=* | --host=* | --hos=* | --ho=*)
1425    host_alias=$ac_optarg ;;
1426
1427  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1428    ac_prev=htmldir ;;
1429  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1430  | --ht=*)
1431    htmldir=$ac_optarg ;;
1432
1433  -includedir | --includedir | --includedi | --included | --include \
1434  | --includ | --inclu | --incl | --inc)
1435    ac_prev=includedir ;;
1436  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1437  | --includ=* | --inclu=* | --incl=* | --inc=*)
1438    includedir=$ac_optarg ;;
1439
1440  -infodir | --infodir | --infodi | --infod | --info | --inf)
1441    ac_prev=infodir ;;
1442  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1443    infodir=$ac_optarg ;;
1444
1445  -libdir | --libdir | --libdi | --libd)
1446    ac_prev=libdir ;;
1447  -libdir=* | --libdir=* | --libdi=* | --libd=*)
1448    libdir=$ac_optarg ;;
1449
1450  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1451  | --libexe | --libex | --libe)
1452    ac_prev=libexecdir ;;
1453  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1454  | --libexe=* | --libex=* | --libe=*)
1455    libexecdir=$ac_optarg ;;
1456
1457  -localedir | --localedir | --localedi | --localed | --locale)
1458    ac_prev=localedir ;;
1459  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1460    localedir=$ac_optarg ;;
1461
1462  -localstatedir | --localstatedir | --localstatedi | --localstated \
1463  | --localstate | --localstat | --localsta | --localst | --locals)
1464    ac_prev=localstatedir ;;
1465  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1466  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1467    localstatedir=$ac_optarg ;;
1468
1469  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1470    ac_prev=mandir ;;
1471  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1472    mandir=$ac_optarg ;;
1473
1474  -nfp | --nfp | --nf)
1475    # Obsolete; use --without-fp.
1476    with_fp=no ;;
1477
1478  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1479  | --no-cr | --no-c | -n)
1480    no_create=yes ;;
1481
1482  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1483  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1484    no_recursion=yes ;;
1485
1486  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1487  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1488  | --oldin | --oldi | --old | --ol | --o)
1489    ac_prev=oldincludedir ;;
1490  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1491  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1492  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1493    oldincludedir=$ac_optarg ;;
1494
1495  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1496    ac_prev=prefix ;;
1497  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1498    prefix=$ac_optarg ;;
1499
1500  -program-prefix | --program-prefix | --program-prefi | --program-pref \
1501  | --program-pre | --program-pr | --program-p)
1502    ac_prev=program_prefix ;;
1503  -program-prefix=* | --program-prefix=* | --program-prefi=* \
1504  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1505    program_prefix=$ac_optarg ;;
1506
1507  -program-suffix | --program-suffix | --program-suffi | --program-suff \
1508  | --program-suf | --program-su | --program-s)
1509    ac_prev=program_suffix ;;
1510  -program-suffix=* | --program-suffix=* | --program-suffi=* \
1511  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1512    program_suffix=$ac_optarg ;;
1513
1514  -program-transform-name | --program-transform-name \
1515  | --program-transform-nam | --program-transform-na \
1516  | --program-transform-n | --program-transform- \
1517  | --program-transform | --program-transfor \
1518  | --program-transfo | --program-transf \
1519  | --program-trans | --program-tran \
1520  | --progr-tra | --program-tr | --program-t)
1521    ac_prev=program_transform_name ;;
1522  -program-transform-name=* | --program-transform-name=* \
1523  | --program-transform-nam=* | --program-transform-na=* \
1524  | --program-transform-n=* | --program-transform-=* \
1525  | --program-transform=* | --program-transfor=* \
1526  | --program-transfo=* | --program-transf=* \
1527  | --program-trans=* | --program-tran=* \
1528  | --progr-tra=* | --program-tr=* | --program-t=*)
1529    program_transform_name=$ac_optarg ;;
1530
1531  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1532    ac_prev=pdfdir ;;
1533  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1534    pdfdir=$ac_optarg ;;
1535
1536  -psdir | --psdir | --psdi | --psd | --ps)
1537    ac_prev=psdir ;;
1538  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1539    psdir=$ac_optarg ;;
1540
1541  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1542  | -silent | --silent | --silen | --sile | --sil)
1543    silent=yes ;;
1544
1545  -runstatedir | --runstatedir | --runstatedi | --runstated \
1546  | --runstate | --runstat | --runsta | --runst | --runs \
1547  | --run | --ru | --r)
1548    ac_prev=runstatedir ;;
1549  -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1550  | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1551  | --run=* | --ru=* | --r=*)
1552    runstatedir=$ac_optarg ;;
1553
1554  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1555    ac_prev=sbindir ;;
1556  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1557  | --sbi=* | --sb=*)
1558    sbindir=$ac_optarg ;;
1559
1560  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1561  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1562  | --sharedst | --shareds | --shared | --share | --shar \
1563  | --sha | --sh)
1564    ac_prev=sharedstatedir ;;
1565  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1566  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1567  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1568  | --sha=* | --sh=*)
1569    sharedstatedir=$ac_optarg ;;
1570
1571  -site | --site | --sit)
1572    ac_prev=site ;;
1573  -site=* | --site=* | --sit=*)
1574    site=$ac_optarg ;;
1575
1576  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1577    ac_prev=srcdir ;;
1578  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1579    srcdir=$ac_optarg ;;
1580
1581  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1582  | --syscon | --sysco | --sysc | --sys | --sy)
1583    ac_prev=sysconfdir ;;
1584  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1585  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1586    sysconfdir=$ac_optarg ;;
1587
1588  -target | --target | --targe | --targ | --tar | --ta | --t)
1589    ac_prev=target_alias ;;
1590  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1591    target_alias=$ac_optarg ;;
1592
1593  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1594    verbose=yes ;;
1595
1596  -version | --version | --versio | --versi | --vers | -V)
1597    ac_init_version=: ;;
1598
1599  -with-* | --with-*)
1600    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1601    # Reject names that are not valid shell variable names.
1602    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1603      as_fn_error $? "invalid package name: \`$ac_useropt'"
1604    ac_useropt_orig=$ac_useropt
1605    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1606    case $ac_user_opts in
1607      *"
1608"with_$ac_useropt"
1609"*) ;;
1610      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1611	 ac_unrecognized_sep=', ';;
1612    esac
1613    eval with_$ac_useropt=\$ac_optarg ;;
1614
1615  -without-* | --without-*)
1616    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1617    # Reject names that are not valid shell variable names.
1618    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1619      as_fn_error $? "invalid package name: \`$ac_useropt'"
1620    ac_useropt_orig=$ac_useropt
1621    ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1622    case $ac_user_opts in
1623      *"
1624"with_$ac_useropt"
1625"*) ;;
1626      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1627	 ac_unrecognized_sep=', ';;
1628    esac
1629    eval with_$ac_useropt=no ;;
1630
1631  --x)
1632    # Obsolete; use --with-x.
1633    with_x=yes ;;
1634
1635  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1636  | --x-incl | --x-inc | --x-in | --x-i)
1637    ac_prev=x_includes ;;
1638  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1639  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1640    x_includes=$ac_optarg ;;
1641
1642  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1643  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1644    ac_prev=x_libraries ;;
1645  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1646  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1647    x_libraries=$ac_optarg ;;
1648
1649  -*) as_fn_error $? "unrecognized option: \`$ac_option'
1650Try \`$0 --help' for more information"
1651    ;;
1652
1653  *=*)
1654    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1655    # Reject names that are not valid shell variable names.
1656    case $ac_envvar in #(
1657      '' | [0-9]* | *[!_$as_cr_alnum]* )
1658      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1659    esac
1660    eval $ac_envvar=\$ac_optarg
1661    export $ac_envvar ;;
1662
1663  *)
1664    # FIXME: should be removed in autoconf 3.0.
1665    printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
1666    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1667      printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
1668    : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1669    ;;
1670
1671  esac
1672done
1673
1674if test -n "$ac_prev"; then
1675  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1676  as_fn_error $? "missing argument to $ac_option"
1677fi
1678
1679if test -n "$ac_unrecognized_opts"; then
1680  case $enable_option_checking in
1681    no) ;;
1682    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1683    *)     printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1684  esac
1685fi
1686
1687# Check all directory arguments for consistency.
1688for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1689		datadir sysconfdir sharedstatedir localstatedir includedir \
1690		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1691		libdir localedir mandir runstatedir
1692do
1693  eval ac_val=\$$ac_var
1694  # Remove trailing slashes.
1695  case $ac_val in
1696    */ )
1697      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1698      eval $ac_var=\$ac_val;;
1699  esac
1700  # Be sure to have absolute directory names.
1701  case $ac_val in
1702    [\\/$]* | ?:[\\/]* )  continue;;
1703    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1704  esac
1705  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1706done
1707
1708# There might be people who depend on the old broken behavior: `$host'
1709# used to hold the argument of --host etc.
1710# FIXME: To remove some day.
1711build=$build_alias
1712host=$host_alias
1713target=$target_alias
1714
1715# FIXME: To remove some day.
1716if test "x$host_alias" != x; then
1717  if test "x$build_alias" = x; then
1718    cross_compiling=maybe
1719  elif test "x$build_alias" != "x$host_alias"; then
1720    cross_compiling=yes
1721  fi
1722fi
1723
1724ac_tool_prefix=
1725test -n "$host_alias" && ac_tool_prefix=$host_alias-
1726
1727test "$silent" = yes && exec 6>/dev/null
1728
1729
1730ac_pwd=`pwd` && test -n "$ac_pwd" &&
1731ac_ls_di=`ls -di .` &&
1732ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1733  as_fn_error $? "working directory cannot be determined"
1734test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1735  as_fn_error $? "pwd does not report name of working directory"
1736
1737
1738# Find the source files, if location was not specified.
1739if test -z "$srcdir"; then
1740  ac_srcdir_defaulted=yes
1741  # Try the directory containing this script, then the parent directory.
1742  ac_confdir=`$as_dirname -- "$as_myself" ||
1743$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1744	 X"$as_myself" : 'X\(//\)[^/]' \| \
1745	 X"$as_myself" : 'X\(//\)$' \| \
1746	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1747printf "%s\n" X"$as_myself" |
1748    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1749	    s//\1/
1750	    q
1751	  }
1752	  /^X\(\/\/\)[^/].*/{
1753	    s//\1/
1754	    q
1755	  }
1756	  /^X\(\/\/\)$/{
1757	    s//\1/
1758	    q
1759	  }
1760	  /^X\(\/\).*/{
1761	    s//\1/
1762	    q
1763	  }
1764	  s/.*/./; q'`
1765  srcdir=$ac_confdir
1766  if test ! -r "$srcdir/$ac_unique_file"; then
1767    srcdir=..
1768  fi
1769else
1770  ac_srcdir_defaulted=no
1771fi
1772if test ! -r "$srcdir/$ac_unique_file"; then
1773  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1774  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1775fi
1776ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1777ac_abs_confdir=`(
1778	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1779	pwd)`
1780# When building in place, set srcdir=.
1781if test "$ac_abs_confdir" = "$ac_pwd"; then
1782  srcdir=.
1783fi
1784# Remove unnecessary trailing slashes from srcdir.
1785# Double slashes in file names in object file debugging info
1786# mess up M-x gdb in Emacs.
1787case $srcdir in
1788*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1789esac
1790for ac_var in $ac_precious_vars; do
1791  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1792  eval ac_env_${ac_var}_value=\$${ac_var}
1793  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1794  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1795done
1796
1797#
1798# Report the --help message.
1799#
1800if test "$ac_init_help" = "long"; then
1801  # Omit some internal or obsolete options to make the list less imposing.
1802  # This message is too long to be a string in the A/UX 3.1 sh.
1803  cat <<_ACEOF
1804\`configure' configures PHP 8.1.1 to adapt to many kinds of systems.
1805
1806Usage: $0 [OPTION]... [VAR=VALUE]...
1807
1808To assign environment variables (e.g., CC, CFLAGS...), specify them as
1809VAR=VALUE.  See below for descriptions of some of the useful variables.
1810
1811Defaults for the options are specified in brackets.
1812
1813Configuration:
1814  -h, --help              display this help and exit
1815      --help=short        display options specific to this package
1816      --help=recursive    display the short help of all the included packages
1817  -V, --version           display version information and exit
1818  -q, --quiet, --silent   do not print \`checking ...' messages
1819      --cache-file=FILE   cache test results in FILE [disabled]
1820  -C, --config-cache      alias for \`--cache-file=config.cache'
1821  -n, --no-create         do not create output files
1822      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1823
1824Installation directories:
1825  --prefix=PREFIX         install architecture-independent files in PREFIX
1826                          [$ac_default_prefix]
1827  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1828                          [PREFIX]
1829
1830By default, \`make install' will install all the files in
1831\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1832an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1833for instance \`--prefix=\$HOME'.
1834
1835For better control, use the options below.
1836
1837Fine tuning of the installation directories:
1838  --bindir=DIR            user executables [EPREFIX/bin]
1839  --sbindir=DIR           system admin executables [EPREFIX/sbin]
1840  --libexecdir=DIR        program executables [EPREFIX/libexec]
1841  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1842  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1843  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1844  --runstatedir=DIR       modifiable per-process data [LOCALSTATEDIR/run]
1845  --libdir=DIR            object code libraries [EPREFIX/lib]
1846  --includedir=DIR        C header files [PREFIX/include]
1847  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1848  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1849  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1850  --infodir=DIR           info documentation [DATAROOTDIR/info]
1851  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1852  --mandir=DIR            man documentation [DATAROOTDIR/man]
1853  --docdir=DIR            documentation root [DATAROOTDIR/doc/php]
1854  --htmldir=DIR           html documentation [DOCDIR]
1855  --dvidir=DIR            dvi documentation [DOCDIR]
1856  --pdfdir=DIR            pdf documentation [DOCDIR]
1857  --psdir=DIR             ps documentation [DOCDIR]
1858_ACEOF
1859
1860  cat <<\_ACEOF
1861
1862Program names:
1863  --program-prefix=PREFIX            prepend PREFIX to installed program names
1864  --program-suffix=SUFFIX            append SUFFIX to installed program names
1865  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1866
1867System types:
1868  --build=BUILD     configure for building on BUILD [guessed]
1869  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1870  --target=TARGET   configure for building compilers for TARGET [HOST]
1871_ACEOF
1872fi
1873
1874if test -n "$ac_init_help"; then
1875  case $ac_init_help in
1876     short | recursive ) echo "Configuration of PHP 8.1.1:";;
1877   esac
1878  cat <<\_ACEOF
1879
1880Optional Features and Packages:
1881  --disable-option-checking  ignore unrecognized --enable/--with options
1882  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1883  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1884  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1885  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1886  --with-libdir=NAME      Look for libraries in .../NAME rather than .../lib
1887  --disable-rpath         Disable passing additional runtime library search
1888                          paths
1889  --enable-re2c-cgoto     Enable -g flag to re2c to use computed goto gcc
1890                          extension
1891  --disable-gcc-global-regs
1892                          whether to enable GCC global register variables
1893
1894SAPI modules:
1895
1896  --with-apxs2[=FILE]     Build shared Apache 2 handler module. FILE is the
1897                          optional pathname to the Apache apxs tool [apxs]
1898  --disable-cli           Disable building CLI version of PHP (this forces
1899                          --without-pear)
1900  --enable-embed[=TYPE]   EXPERIMENTAL: Enable building of embedded SAPI
1901                          library TYPE is either 'shared' or 'static'.
1902                          [TYPE=shared]
1903  --enable-fpm            Enable building of the fpm SAPI executable
1904  --with-fpm-user[=USER]  Set the user for php-fpm to run as. (default:
1905                          nobody)
1906  --with-fpm-group[=GRP]  Set the group for php-fpm to run as. For a system
1907                          user, this should usually be set to match the fpm
1908                          username (default: nobody)
1909  --with-fpm-systemd      Activate systemd integration
1910  --with-fpm-acl          Use POSIX Access Control Lists
1911  --with-fpm-apparmor     Support AppArmor confinement through libapparmor
1912  --enable-fuzzer         Build PHP as clang fuzzing test module (for
1913                          developers)
1914  --enable-fuzzer-msan    Enable msan instead of asan/ubsan when fuzzing
1915  --enable-litespeed      Build PHP as litespeed module
1916  --enable-phpdbg         Build phpdbg
1917  --enable-phpdbg-debug   Build phpdbg in debug mode
1918  --enable-phpdbg-readline
1919                          Enable readline support in phpdbg (depends on static
1920                          ext/readline)
1921  --disable-cgi           Disable building CGI version of PHP
1922  --with-valgrind         Enable valgrind support
1923
1924General settings:
1925
1926  --enable-gcov           Enable GCOV code coverage - FOR DEVELOPERS ONLY!!
1927  --enable-debug          Compile with debugging symbols
1928  --enable-debug-assertions
1929                          Compile with debug assertions even in release mode
1930  --enable-zts            Enable thread safety
1931  --enable-rtld-now       Use dlopen with RTLD_NOW instead of RTLD_LAZY
1932  --with-layout=TYPE      Set how installed files will be laid out. Type can
1933                          be either PHP or GNU [PHP]
1934  --with-config-file-path=PATH
1935                          Set the path in which to look for php.ini
1936                          [PREFIX/lib]
1937  --with-config-file-scan-dir=PATH
1938                          Set the path where to scan for configuration files
1939  --enable-sigchild       Enable PHP's own SIGCHLD handler
1940  --enable-libgcc         Enable explicitly linking against libgcc
1941  --disable-short-tags    Disable the short-form <? start tag by default
1942  --enable-dmalloc        Enable dmalloc
1943  --disable-ipv6          Disable IPv6 support
1944  --enable-dtrace         Enable DTrace support
1945  --enable-fd-setsize     Set size of descriptor sets
1946  --enable-werror         Enable -Werror
1947  --enable-memory-sanitizer
1948                          Enable memory sanitizer (clang only)
1949  --enable-address-sanitizer
1950                          Enable address sanitizer
1951  --enable-undefined-sanitizer
1952                          Enable undefined sanitizer
1953
1954Extensions:
1955
1956  --with-EXTENSION=shared[,PATH]
1957
1958    NOTE: Not all extensions can be build as 'shared'.
1959
1960    Example: --with-foobar=shared,/usr/local/foobar/
1961
1962      o Builds the foobar extension as shared extension.
1963      o foobar package install prefix is /usr/local/foobar/
1964
1965
1966  --disable-all           Disable all extensions which are enabled by default
1967  --without-libxml        Build without LIBXML support
1968  --with-openssl          Include OpenSSL support (requires OpenSSL >= 1.0.2)
1969  --with-kerberos         OPENSSL: Include Kerberos support
1970  --with-system-ciphers   OPENSSL: Use system default cipher list instead of
1971                          hardcoded value
1972  --with-external-pcre    Use external library for PCRE support
1973  --without-pcre-jit      Disable PCRE JIT functionality
1974  --without-sqlite3       Do not include SQLite3 support.
1975  --with-zlib             Include ZLIB support (requires zlib >= 1.2.0.4)
1976  --enable-bcmath         Enable bc style precision math functions
1977  --with-bz2[=DIR]        Include BZip2 support
1978  --enable-calendar       Enable support for calendar conversion
1979  --disable-ctype         Disable ctype functions
1980  --with-curl             Include cURL support
1981  --enable-dba            Build DBA with bundled modules. To build shared DBA
1982                          extension use --enable-dba=shared
1983  --with-qdbm[=DIR]       DBA: QDBM support
1984  --with-gdbm[=DIR]       DBA: GDBM support
1985  --with-ndbm[=DIR]       DBA: NDBM support
1986  --with-db4[=DIR]        DBA: Oracle Berkeley DB 4.x or 5.x support
1987  --with-db3[=DIR]        DBA: Oracle Berkeley DB 3.x support
1988  --with-db2[=DIR]        DBA: Oracle Berkeley DB 2.x support
1989  --with-db1[=DIR]        DBA: Oracle Berkeley DB 1.x support/emulation
1990  --with-dbm[=DIR]        DBA: DBM support
1991  --with-tcadb[=DIR]      DBA: Tokyo Cabinet abstract DB support
1992  --with-lmdb[=DIR]       DBA: Lightning memory-mapped database support
1993  --without-cdb[=DIR]     DBA: CDB support (bundled)
1994  --disable-inifile       DBA: INI support (bundled)
1995  --disable-flatfile      DBA: FlatFile support (bundled)
1996  --disable-dom           Disable DOM support
1997  --with-enchant          Include Enchant support
1998  --enable-exif           Enable EXIF (metadata from images) support
1999  --with-ffi              Include FFI support
2000  --disable-fileinfo      Disable fileinfo support
2001  --disable-filter        Disable input filter support
2002  --enable-ftp            Enable FTP support
2003  --with-openssl-dir      FTP: Whether to enable FTP SSL support without
2004                          ext/openssl
2005  --enable-gd             Include GD support
2006  --with-external-gd      Use external libgd
2007  --with-avif             GD: Enable AVIF support (only for bundled libgd)
2008  --with-webp             GD: Enable WEBP support (only for bundled libgd)
2009  --with-jpeg             GD: Enable JPEG support (only for bundled libgd)
2010  --with-xpm              GD: Enable XPM support (only for bundled libgd)
2011  --with-freetype         GD: Enable FreeType 2 support (only for bundled
2012                          libgd)
2013  --enable-gd-jis-conv    GD: Enable JIS-mapped Japanese font support (only
2014                          for bundled libgd)
2015  --with-gettext[=DIR]    Include GNU gettext support
2016  --with-gmp[=DIR]        Include GNU MP support
2017  --with-mhash            Include mhash support
2018  --without-iconv[=DIR]   Exclude iconv support
2019  --with-imap[=DIR]       Include IMAP support. DIR is the c-client install
2020                          prefix
2021  --with-kerberos         IMAP: Include Kerberos support
2022  --with-imap-ssl         IMAP: Include SSL support
2023  --enable-intl           Enable internationalization support
2024  --with-ldap[=DIR]       Include LDAP support
2025  --with-ldap-sasl        LDAP: Build with Cyrus SASL support
2026  --enable-mbstring       Enable multibyte string support
2027  --disable-mbregex       MBSTRING: Disable multibyte regex support
2028  --with-mysqli[=FILE]    Include MySQLi support. FILE is the path to
2029                          mysql_config. If no value or mysqlnd is passed as
2030                          FILE, the MySQL native driver will be used
2031  --with-mysql-sock[=SOCKPATH]
2032                          MySQLi/PDO_MYSQL: Location of the MySQL unix socket
2033                          pointer. If unspecified, the default locations are
2034                          searched
2035  --with-oci8[=DIR]       Include Oracle Database OCI8 support. DIR defaults
2036                          to $ORACLE_HOME. Use
2037                          --with-oci8=instantclient,/path/to/instant/client/lib
2038                          to use an Oracle Instant Client installation
2039  --with-odbcver[=HEX]    Force support for the passed ODBC version. A hex
2040                          number is expected, default 0x0350. Use the special
2041                          value of 0 to prevent an explicit ODBCVER to be
2042                          defined.
2043  --with-adabas[=DIR]     Include Adabas D support [/usr/local]
2044  --with-sapdb[=DIR]      Include SAP DB support [/usr/local]
2045  --with-solid[=DIR]      Include Solid support [/usr/local/solid]
2046  --with-ibm-db2[=DIR]    Include IBM DB2 support [/home/db2inst1/sqllib]
2047  --with-empress[=DIR]    Include Empress support $EMPRESSPATH (Empress
2048                          Version >= 8.60 required)
2049  --with-empress-bcs[=DIR]
2050                          Include Empress Local Access support $EMPRESSPATH
2051                          (Empress Version >= 8.60 required)
2052  --with-custom-odbc[=DIR]
2053                          Include user defined ODBC support. DIR is ODBC
2054                          install base directory [/usr/local]. Make sure to
2055                          define CUSTOM_ODBC_LIBS and have some odbc.h in your
2056                          include dirs. For example, you should define
2057                          following for Sybase SQL Anywhere 5.5.00 on QNX,
2058                          prior to running this configure script:
2059                          CPPFLAGS="-DODBC_QNX -DSQLANY_BUG" LDFLAGS=-lunix
2060                          CUSTOM_ODBC_LIBS="-ldblib -lodbc"
2061  --with-iodbc            Include iODBC support
2062  --with-esoob[=DIR]      Include Easysoft OOB support
2063                          [/usr/local/easysoft/oob/client]
2064  --with-unixODBC         Include unixODBC support
2065  --with-dbmaker[=DIR]    Include DBMaker support
2066  --disable-opcache       Disable Zend OPcache support
2067  --disable-huge-code-pages
2068                          Disable copying PHP CODE pages into HUGE PAGES
2069  --disable-opcache-jit   Disable JIT
2070  --enable-pcntl          Enable pcntl support (CLI/CGI only)
2071  --disable-pdo           Disable PHP Data Objects support
2072  --with-pdo-dblib[=DIR]  PDO: DBLIB-DB support. DIR is the FreeTDS home
2073                          directory
2074  --with-pdo-firebird[=DIR]
2075                          PDO: Firebird support. DIR is the Firebird base
2076                          install directory [/opt/firebird]
2077  --with-pdo-mysql[=DIR]  PDO: MySQL support. DIR is the MySQL base directory.
2078                          If no value or mysqlnd is passed as DIR, the MySQL
2079                          native driver will be used
2080  --with-zlib-dir[=DIR]   PDO_MySQL: Set the path to libz install prefix
2081  --with-pdo-oci[=DIR]    PDO: Oracle OCI support. DIR defaults to
2082                          $ORACLE_HOME. Use
2083                          --with-pdo-oci=instantclient,/path/to/instant/client/lib
2084                          for an Oracle Instant Client installation.
2085  --with-pdo-odbc=flavour,dir
2086                          PDO: Support for 'flavour' ODBC driver. The include
2087                          and lib dirs are looked for under 'dir'. The
2088                          'flavour' can be one of: ibm-db2, iODBC, unixODBC,
2089                          generic. If ',dir' part is omitted, default for the
2090                          flavour you have selected will be used. e.g.:
2091                          --with-pdo-odbc=unixODBC will check for unixODBC
2092                          under /usr/local. You may attempt to use an
2093                          otherwise unsupported driver using the 'generic'
2094                          flavour. The syntax for generic ODBC support is:
2095                          --with-pdo-odbc=generic,dir,libname,ldflags,cflags.
2096                          When built as 'shared' the extension filename is
2097                          always pdo_odbc.so
2098  --with-pdo-pgsql[=DIR]  PDO: PostgreSQL support. DIR is the PostgreSQL base
2099                          install directory or the path to pg_config
2100  --without-pdo-sqlite    PDO: sqlite 3 support.
2101  --with-pgsql[=DIR]      Include PostgreSQL support. DIR is the PostgreSQL
2102                          base install directory or the path to pg_config
2103  --disable-phar          Disable phar support
2104  --disable-posix         Disable POSIX-like functions
2105  --with-pspell[=DIR]     Include PSPELL support. GNU Aspell version 0.50.0 or
2106                          higher required
2107  --with-libedit          Include libedit readline replacement (CLI/CGI only)
2108  --with-readline[=DIR]   Include readline support (CLI/CGI only)
2109  --disable-session       Disable session support
2110  --with-mm[=DIR]         SESSION: Include mm support for session storage
2111  --enable-shmop          Enable shmop support
2112  --disable-simplexml     Disable SimpleXML support
2113  --with-snmp[=DIR]       Include SNMP support
2114  --enable-soap           Enable SOAP support
2115  --enable-sockets        Enable sockets support
2116  --with-sodium           Include sodium support
2117  --with-external-libcrypt
2118                          Use external libcrypt or libxcrypt
2119  --with-password-argon2  Include Argon2 support in password_*
2120  --enable-sysvmsg        Enable sysvmsg support
2121  --enable-sysvsem        Enable System V semaphore support
2122  --enable-sysvshm        Enable the System V shared memory support
2123  --with-tidy[=DIR]       Include TIDY support
2124  --disable-tokenizer     Disable tokenizer support
2125  --disable-xml           Disable XML support
2126  --with-expat            XML: use expat instead of libxml2
2127  --disable-xmlreader     Disable XMLReader support
2128  --disable-xmlwriter     Disable XMLWriter support
2129  --with-xsl              Build with XSL support
2130  --enable-zend-test      Enable zend_test extension
2131  --with-zip              Include Zip read/write support
2132  --enable-mysqlnd        Enable mysqlnd explicitly, will be done implicitly
2133                          when required by other extensions
2134  --disable-mysqlnd-compression-support
2135                          Disable support for the MySQL compressed protocol in
2136                          mysqlnd
2137
2138PEAR:
2139
2140  --with-pear[=DIR]       Install PEAR in DIR [PREFIX/lib/php]
2141  --disable-fiber-asm     Disable the use of boost fiber assembly files
2142
2143Zend:
2144
2145  --disable-zend-signals  whether to enable zend signal handling
2146
2147TSRM:
2148
2149
2150Libtool:
2151
2152  --enable-shared=PKGS    Build shared libraries default=yes
2153  --enable-static=PKGS    Build static libraries default=yes
2154  --enable-fast-install=PKGS
2155                          Optimize for fast installation default=yes
2156  --with-gnu-ld           Assume the C compiler uses GNU ld default=no
2157  --disable-libtool-lock  Avoid locking (might break parallel builds)
2158  --with-pic              Try to use only PIC/non-PIC objects default=use both
2159  --with-tags=TAGS        Include additional configurations automatic
2160
2161
2162Some influential environment variables:
2163  PKG_CONFIG  path to pkg-config utility
2164  PKG_CONFIG_PATH
2165              directories to add to pkg-config's search path
2166  PKG_CONFIG_LIBDIR
2167              path overriding pkg-config's built-in search path
2168  CC          C compiler command
2169  CFLAGS      C compiler flags
2170  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2171              nonstandard directory <lib dir>
2172  LIBS        libraries to pass to the linker, e.g. -l<library>
2173  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2174              you have headers in a nonstandard directory <include dir>
2175  CPP         C preprocessor
2176  SYSTEMD_CFLAGS
2177              C compiler flags for SYSTEMD, overriding pkg-config
2178  SYSTEMD_LIBS
2179              linker flags for SYSTEMD, overriding pkg-config
2180  CXX         C++ compiler command
2181  CXXFLAGS    C++ compiler flags
2182  CXXCPP      C++ preprocessor
2183  VALGRIND_CFLAGS
2184              C compiler flags for VALGRIND, overriding pkg-config
2185  VALGRIND_LIBS
2186              linker flags for VALGRIND, overriding pkg-config
2187  LIBXML_CFLAGS
2188              C compiler flags for LIBXML, overriding pkg-config
2189  LIBXML_LIBS linker flags for LIBXML, overriding pkg-config
2190  KERBEROS_CFLAGS
2191              C compiler flags for KERBEROS, overriding pkg-config
2192  KERBEROS_LIBS
2193              linker flags for KERBEROS, overriding pkg-config
2194  OPENSSL_CFLAGS
2195              C compiler flags for OPENSSL, overriding pkg-config
2196  OPENSSL_LIBS
2197              linker flags for OPENSSL, overriding pkg-config
2198  PCRE2_CFLAGS
2199              C compiler flags for PCRE2, overriding pkg-config
2200  PCRE2_LIBS  linker flags for PCRE2, overriding pkg-config
2201  SQLITE_CFLAGS
2202              C compiler flags for SQLITE, overriding pkg-config
2203  SQLITE_LIBS linker flags for SQLITE, overriding pkg-config
2204  ZLIB_CFLAGS C compiler flags for ZLIB, overriding pkg-config
2205  ZLIB_LIBS   linker flags for ZLIB, overriding pkg-config
2206  CURL_CFLAGS C compiler flags for CURL, overriding pkg-config
2207  CURL_LIBS   linker flags for CURL, overriding pkg-config
2208  CURL_FEATURES
2209              value of supported_features for libcurl, overriding pkg-config
2210  ENCHANT2_CFLAGS
2211              C compiler flags for ENCHANT2, overriding pkg-config
2212  ENCHANT2_LIBS
2213              linker flags for ENCHANT2, overriding pkg-config
2214  ENCHANT_CFLAGS
2215              C compiler flags for ENCHANT, overriding pkg-config
2216  ENCHANT_LIBS
2217              linker flags for ENCHANT, overriding pkg-config
2218  FFI_CFLAGS  C compiler flags for FFI, overriding pkg-config
2219  FFI_LIBS    linker flags for FFI, overriding pkg-config
2220  PNG_CFLAGS  C compiler flags for PNG, overriding pkg-config
2221  PNG_LIBS    linker flags for PNG, overriding pkg-config
2222  AVIF_CFLAGS C compiler flags for AVIF, overriding pkg-config
2223  AVIF_LIBS   linker flags for AVIF, overriding pkg-config
2224  WEBP_CFLAGS C compiler flags for WEBP, overriding pkg-config
2225  WEBP_LIBS   linker flags for WEBP, overriding pkg-config
2226  JPEG_CFLAGS C compiler flags for JPEG, overriding pkg-config
2227  JPEG_LIBS   linker flags for JPEG, overriding pkg-config
2228  XPM_CFLAGS  C compiler flags for XPM, overriding pkg-config
2229  XPM_LIBS    linker flags for XPM, overriding pkg-config
2230  FREETYPE2_CFLAGS
2231              C compiler flags for FREETYPE2, overriding pkg-config
2232  FREETYPE2_LIBS
2233              linker flags for FREETYPE2, overriding pkg-config
2234  GDLIB_CFLAGS
2235              C compiler flags for GDLIB, overriding pkg-config
2236  GDLIB_LIBS  linker flags for GDLIB, overriding pkg-config
2237  ICU_CFLAGS  C compiler flags for ICU, overriding pkg-config
2238  ICU_LIBS    linker flags for ICU, overriding pkg-config
2239  SASL_CFLAGS C compiler flags for SASL, overriding pkg-config
2240  SASL_LIBS   linker flags for SASL, overriding pkg-config
2241  ONIG_CFLAGS C compiler flags for ONIG, overriding pkg-config
2242  ONIG_LIBS   linker flags for ONIG, overriding pkg-config
2243  ODBC_CFLAGS C compiler flags for ODBC, overriding pkg-config
2244  ODBC_LIBS   linker flags for ODBC, overriding pkg-config
2245  CAPSTONE_CFLAGS
2246              C compiler flags for CAPSTONE, overriding pkg-config
2247  CAPSTONE_LIBS
2248              linker flags for CAPSTONE, overriding pkg-config
2249  EDIT_CFLAGS C compiler flags for EDIT, overriding pkg-config
2250  EDIT_LIBS   linker flags for EDIT, overriding pkg-config
2251  LIBSODIUM_CFLAGS
2252              C compiler flags for LIBSODIUM, overriding pkg-config
2253  LIBSODIUM_LIBS
2254              linker flags for LIBSODIUM, overriding pkg-config
2255  ARGON2_CFLAGS
2256              C compiler flags for ARGON2, overriding pkg-config
2257  ARGON2_LIBS linker flags for ARGON2, overriding pkg-config
2258  EXPAT_CFLAGS
2259              C compiler flags for EXPAT, overriding pkg-config
2260  EXPAT_LIBS  linker flags for EXPAT, overriding pkg-config
2261  XSL_CFLAGS  C compiler flags for XSL, overriding pkg-config
2262  XSL_LIBS    linker flags for XSL, overriding pkg-config
2263  EXSLT_CFLAGS
2264              C compiler flags for EXSLT, overriding pkg-config
2265  EXSLT_LIBS  linker flags for EXSLT, overriding pkg-config
2266  LIBZIP_CFLAGS
2267              C compiler flags for LIBZIP, overriding pkg-config
2268  LIBZIP_LIBS linker flags for LIBZIP, overriding pkg-config
2269
2270Use these variables to override the choices made by `configure' or to help
2271it to find libraries and programs with nonstandard names/locations.
2272
2273Report bugs to <https://bugs.php.net>.
2274PHP home page: <https://www.php.net>.
2275_ACEOF
2276ac_status=$?
2277fi
2278
2279if test "$ac_init_help" = "recursive"; then
2280  # If there are subdirs, report their specific --help.
2281  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2282    test -d "$ac_dir" ||
2283      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2284      continue
2285    ac_builddir=.
2286
2287case "$ac_dir" in
2288.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2289*)
2290  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
2291  # A ".." for each directory in $ac_dir_suffix.
2292  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2293  case $ac_top_builddir_sub in
2294  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2295  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2296  esac ;;
2297esac
2298ac_abs_top_builddir=$ac_pwd
2299ac_abs_builddir=$ac_pwd$ac_dir_suffix
2300# for backward compatibility:
2301ac_top_builddir=$ac_top_build_prefix
2302
2303case $srcdir in
2304  .)  # We are building in place.
2305    ac_srcdir=.
2306    ac_top_srcdir=$ac_top_builddir_sub
2307    ac_abs_top_srcdir=$ac_pwd ;;
2308  [\\/]* | ?:[\\/]* )  # Absolute name.
2309    ac_srcdir=$srcdir$ac_dir_suffix;
2310    ac_top_srcdir=$srcdir
2311    ac_abs_top_srcdir=$srcdir ;;
2312  *) # Relative name.
2313    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2314    ac_top_srcdir=$ac_top_build_prefix$srcdir
2315    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2316esac
2317ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2318
2319    cd "$ac_dir" || { ac_status=$?; continue; }
2320    # Check for configure.gnu first; this name is used for a wrapper for
2321    # Metaconfig's "Configure" on case-insensitive file systems.
2322    if test -f "$ac_srcdir/configure.gnu"; then
2323      echo &&
2324      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2325    elif test -f "$ac_srcdir/configure"; then
2326      echo &&
2327      $SHELL "$ac_srcdir/configure" --help=recursive
2328    else
2329      printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2330    fi || ac_status=$?
2331    cd "$ac_pwd" || { ac_status=$?; break; }
2332  done
2333fi
2334
2335test -n "$ac_init_help" && exit $ac_status
2336if $ac_init_version; then
2337  cat <<\_ACEOF
2338PHP configure 8.1.1
2339generated by GNU Autoconf 2.71
2340
2341Copyright (C) 2021 Free Software Foundation, Inc.
2342This configure script is free software; the Free Software Foundation
2343gives unlimited permission to copy, distribute and modify it.
2344_ACEOF
2345  exit
2346fi
2347
2348## ------------------------ ##
2349## Autoconf initialization. ##
2350## ------------------------ ##
2351
2352# ac_fn_c_try_compile LINENO
2353# --------------------------
2354# Try to compile conftest.$ac_ext, and return whether this succeeded.
2355ac_fn_c_try_compile ()
2356{
2357  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2358  rm -f conftest.$ac_objext conftest.beam
2359  if { { ac_try="$ac_compile"
2360case "(($ac_try" in
2361  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2362  *) ac_try_echo=$ac_try;;
2363esac
2364eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2365printf "%s\n" "$ac_try_echo"; } >&5
2366  (eval "$ac_compile") 2>conftest.err
2367  ac_status=$?
2368  if test -s conftest.err; then
2369    grep -v '^ *+' conftest.err >conftest.er1
2370    cat conftest.er1 >&5
2371    mv -f conftest.er1 conftest.err
2372  fi
2373  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2374  test $ac_status = 0; } && {
2375	 test -z "$ac_c_werror_flag" ||
2376	 test ! -s conftest.err
2377       } && test -s conftest.$ac_objext
2378then :
2379  ac_retval=0
2380else $as_nop
2381  printf "%s\n" "$as_me: failed program was:" >&5
2382sed 's/^/| /' conftest.$ac_ext >&5
2383
2384	ac_retval=1
2385fi
2386  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2387  as_fn_set_status $ac_retval
2388
2389} # ac_fn_c_try_compile
2390
2391# ac_fn_c_try_cpp LINENO
2392# ----------------------
2393# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2394ac_fn_c_try_cpp ()
2395{
2396  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2397  if { { ac_try="$ac_cpp conftest.$ac_ext"
2398case "(($ac_try" in
2399  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2400  *) ac_try_echo=$ac_try;;
2401esac
2402eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2403printf "%s\n" "$ac_try_echo"; } >&5
2404  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2405  ac_status=$?
2406  if test -s conftest.err; then
2407    grep -v '^ *+' conftest.err >conftest.er1
2408    cat conftest.er1 >&5
2409    mv -f conftest.er1 conftest.err
2410  fi
2411  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2412  test $ac_status = 0; } > conftest.i && {
2413	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2414	 test ! -s conftest.err
2415       }
2416then :
2417  ac_retval=0
2418else $as_nop
2419  printf "%s\n" "$as_me: failed program was:" >&5
2420sed 's/^/| /' conftest.$ac_ext >&5
2421
2422    ac_retval=1
2423fi
2424  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2425  as_fn_set_status $ac_retval
2426
2427} # ac_fn_c_try_cpp
2428
2429# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2430# -------------------------------------------------------
2431# Tests whether HEADER exists and can be compiled using the include files in
2432# INCLUDES, setting the cache variable VAR accordingly.
2433ac_fn_c_check_header_compile ()
2434{
2435  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2436  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2437printf %s "checking for $2... " >&6; }
2438if eval test \${$3+y}
2439then :
2440  printf %s "(cached) " >&6
2441else $as_nop
2442  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2443/* end confdefs.h.  */
2444$4
2445#include <$2>
2446_ACEOF
2447if ac_fn_c_try_compile "$LINENO"
2448then :
2449  eval "$3=yes"
2450else $as_nop
2451  eval "$3=no"
2452fi
2453rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2454fi
2455eval ac_res=\$$3
2456	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2457printf "%s\n" "$ac_res" >&6; }
2458  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2459
2460} # ac_fn_c_check_header_compile
2461
2462# ac_fn_c_try_link LINENO
2463# -----------------------
2464# Try to link conftest.$ac_ext, and return whether this succeeded.
2465ac_fn_c_try_link ()
2466{
2467  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2468  rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
2469  if { { ac_try="$ac_link"
2470case "(($ac_try" in
2471  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2472  *) ac_try_echo=$ac_try;;
2473esac
2474eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2475printf "%s\n" "$ac_try_echo"; } >&5
2476  (eval "$ac_link") 2>conftest.err
2477  ac_status=$?
2478  if test -s conftest.err; then
2479    grep -v '^ *+' conftest.err >conftest.er1
2480    cat conftest.er1 >&5
2481    mv -f conftest.er1 conftest.err
2482  fi
2483  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2484  test $ac_status = 0; } && {
2485	 test -z "$ac_c_werror_flag" ||
2486	 test ! -s conftest.err
2487       } && test -s conftest$ac_exeext && {
2488	 test "$cross_compiling" = yes ||
2489	 test -x conftest$ac_exeext
2490       }
2491then :
2492  ac_retval=0
2493else $as_nop
2494  printf "%s\n" "$as_me: failed program was:" >&5
2495sed 's/^/| /' conftest.$ac_ext >&5
2496
2497	ac_retval=1
2498fi
2499  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2500  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2501  # interfere with the next link command; also delete a directory that is
2502  # left behind by Apple's compiler.  We do this before executing the actions.
2503  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2504  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2505  as_fn_set_status $ac_retval
2506
2507} # ac_fn_c_try_link
2508
2509# ac_fn_c_check_func LINENO FUNC VAR
2510# ----------------------------------
2511# Tests whether FUNC exists, setting the cache variable VAR accordingly
2512ac_fn_c_check_func ()
2513{
2514  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2515  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2516printf %s "checking for $2... " >&6; }
2517if eval test \${$3+y}
2518then :
2519  printf %s "(cached) " >&6
2520else $as_nop
2521  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2522/* end confdefs.h.  */
2523/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2524   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2525#define $2 innocuous_$2
2526
2527/* System header to define __stub macros and hopefully few prototypes,
2528   which can conflict with char $2 (); below.  */
2529
2530#include <limits.h>
2531#undef $2
2532
2533/* Override any GCC internal prototype to avoid an error.
2534   Use char because int might match the return type of a GCC
2535   builtin and then its argument prototype would still apply.  */
2536#ifdef __cplusplus
2537extern "C"
2538#endif
2539char $2 ();
2540/* The GNU C library defines this for functions which it implements
2541    to always fail with ENOSYS.  Some functions are actually named
2542    something starting with __ and the normal name is an alias.  */
2543#if defined __stub_$2 || defined __stub___$2
2544choke me
2545#endif
2546
2547int
2548main (void)
2549{
2550return $2 ();
2551  ;
2552  return 0;
2553}
2554_ACEOF
2555if ac_fn_c_try_link "$LINENO"
2556then :
2557  eval "$3=yes"
2558else $as_nop
2559  eval "$3=no"
2560fi
2561rm -f core conftest.err conftest.$ac_objext conftest.beam \
2562    conftest$ac_exeext conftest.$ac_ext
2563fi
2564eval ac_res=\$$3
2565	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2566printf "%s\n" "$ac_res" >&6; }
2567  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2568
2569} # ac_fn_c_check_func
2570
2571# ac_fn_c_try_run LINENO
2572# ----------------------
2573# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
2574# executables *can* be run.
2575ac_fn_c_try_run ()
2576{
2577  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2578  if { { ac_try="$ac_link"
2579case "(($ac_try" in
2580  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2581  *) ac_try_echo=$ac_try;;
2582esac
2583eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2584printf "%s\n" "$ac_try_echo"; } >&5
2585  (eval "$ac_link") 2>&5
2586  ac_status=$?
2587  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2588  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2589  { { case "(($ac_try" in
2590  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2591  *) ac_try_echo=$ac_try;;
2592esac
2593eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2594printf "%s\n" "$ac_try_echo"; } >&5
2595  (eval "$ac_try") 2>&5
2596  ac_status=$?
2597  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2598  test $ac_status = 0; }; }
2599then :
2600  ac_retval=0
2601else $as_nop
2602  printf "%s\n" "$as_me: program exited with status $ac_status" >&5
2603       printf "%s\n" "$as_me: failed program was:" >&5
2604sed 's/^/| /' conftest.$ac_ext >&5
2605
2606       ac_retval=$ac_status
2607fi
2608  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2609  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2610  as_fn_set_status $ac_retval
2611
2612} # ac_fn_c_try_run
2613
2614# ac_fn_cxx_try_compile LINENO
2615# ----------------------------
2616# Try to compile conftest.$ac_ext, and return whether this succeeded.
2617ac_fn_cxx_try_compile ()
2618{
2619  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2620  rm -f conftest.$ac_objext conftest.beam
2621  if { { ac_try="$ac_compile"
2622case "(($ac_try" in
2623  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2624  *) ac_try_echo=$ac_try;;
2625esac
2626eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2627printf "%s\n" "$ac_try_echo"; } >&5
2628  (eval "$ac_compile") 2>conftest.err
2629  ac_status=$?
2630  if test -s conftest.err; then
2631    grep -v '^ *+' conftest.err >conftest.er1
2632    cat conftest.er1 >&5
2633    mv -f conftest.er1 conftest.err
2634  fi
2635  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2636  test $ac_status = 0; } && {
2637	 test -z "$ac_cxx_werror_flag" ||
2638	 test ! -s conftest.err
2639       } && test -s conftest.$ac_objext
2640then :
2641  ac_retval=0
2642else $as_nop
2643  printf "%s\n" "$as_me: failed program was:" >&5
2644sed 's/^/| /' conftest.$ac_ext >&5
2645
2646	ac_retval=1
2647fi
2648  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2649  as_fn_set_status $ac_retval
2650
2651} # ac_fn_cxx_try_compile
2652
2653# ac_fn_cxx_try_cpp LINENO
2654# ------------------------
2655# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2656ac_fn_cxx_try_cpp ()
2657{
2658  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2659  if { { ac_try="$ac_cpp conftest.$ac_ext"
2660case "(($ac_try" in
2661  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2662  *) ac_try_echo=$ac_try;;
2663esac
2664eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2665printf "%s\n" "$ac_try_echo"; } >&5
2666  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2667  ac_status=$?
2668  if test -s conftest.err; then
2669    grep -v '^ *+' conftest.err >conftest.er1
2670    cat conftest.er1 >&5
2671    mv -f conftest.er1 conftest.err
2672  fi
2673  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2674  test $ac_status = 0; } > conftest.i && {
2675	 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2676	 test ! -s conftest.err
2677       }
2678then :
2679  ac_retval=0
2680else $as_nop
2681  printf "%s\n" "$as_me: failed program was:" >&5
2682sed 's/^/| /' conftest.$ac_ext >&5
2683
2684    ac_retval=1
2685fi
2686  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2687  as_fn_set_status $ac_retval
2688
2689} # ac_fn_cxx_try_cpp
2690
2691# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2692# ----------------------------------------------------
2693# Tries to find if the field MEMBER exists in type AGGR, after including
2694# INCLUDES, setting cache variable VAR accordingly.
2695ac_fn_c_check_member ()
2696{
2697  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2698  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2699printf %s "checking for $2.$3... " >&6; }
2700if eval test \${$4+y}
2701then :
2702  printf %s "(cached) " >&6
2703else $as_nop
2704  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2705/* end confdefs.h.  */
2706$5
2707int
2708main (void)
2709{
2710static $2 ac_aggr;
2711if (ac_aggr.$3)
2712return 0;
2713  ;
2714  return 0;
2715}
2716_ACEOF
2717if ac_fn_c_try_compile "$LINENO"
2718then :
2719  eval "$4=yes"
2720else $as_nop
2721  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2722/* end confdefs.h.  */
2723$5
2724int
2725main (void)
2726{
2727static $2 ac_aggr;
2728if (sizeof ac_aggr.$3)
2729return 0;
2730  ;
2731  return 0;
2732}
2733_ACEOF
2734if ac_fn_c_try_compile "$LINENO"
2735then :
2736  eval "$4=yes"
2737else $as_nop
2738  eval "$4=no"
2739fi
2740rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2741fi
2742rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2743fi
2744eval ac_res=\$$4
2745	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2746printf "%s\n" "$ac_res" >&6; }
2747  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2748
2749} # ac_fn_c_check_member
2750
2751# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR
2752# ------------------------------------------------------------------
2753# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2754# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR.
2755ac_fn_check_decl ()
2756{
2757  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2758  as_decl_name=`echo $2|sed 's/ *(.*//'`
2759  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2760printf %s "checking whether $as_decl_name is declared... " >&6; }
2761if eval test \${$3+y}
2762then :
2763  printf %s "(cached) " >&6
2764else $as_nop
2765  as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2766  eval ac_save_FLAGS=\$$6
2767  as_fn_append $6 " $5"
2768  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2769/* end confdefs.h.  */
2770$4
2771int
2772main (void)
2773{
2774#ifndef $as_decl_name
2775#ifdef __cplusplus
2776  (void) $as_decl_use;
2777#else
2778  (void) $as_decl_name;
2779#endif
2780#endif
2781
2782  ;
2783  return 0;
2784}
2785_ACEOF
2786if ac_fn_c_try_compile "$LINENO"
2787then :
2788  eval "$3=yes"
2789else $as_nop
2790  eval "$3=no"
2791fi
2792rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2793  eval $6=\$ac_save_FLAGS
2794
2795fi
2796eval ac_res=\$$3
2797	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2798printf "%s\n" "$ac_res" >&6; }
2799  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2800
2801} # ac_fn_check_decl
2802
2803# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2804# -------------------------------------------
2805# Tests whether TYPE exists after having included INCLUDES, setting cache
2806# variable VAR accordingly.
2807ac_fn_c_check_type ()
2808{
2809  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2810  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2811printf %s "checking for $2... " >&6; }
2812if eval test \${$3+y}
2813then :
2814  printf %s "(cached) " >&6
2815else $as_nop
2816  eval "$3=no"
2817  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2818/* end confdefs.h.  */
2819$4
2820int
2821main (void)
2822{
2823if (sizeof ($2))
2824	 return 0;
2825  ;
2826  return 0;
2827}
2828_ACEOF
2829if ac_fn_c_try_compile "$LINENO"
2830then :
2831  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2832/* end confdefs.h.  */
2833$4
2834int
2835main (void)
2836{
2837if (sizeof (($2)))
2838	    return 0;
2839  ;
2840  return 0;
2841}
2842_ACEOF
2843if ac_fn_c_try_compile "$LINENO"
2844then :
2845
2846else $as_nop
2847  eval "$3=yes"
2848fi
2849rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2850fi
2851rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2852fi
2853eval ac_res=\$$3
2854	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2855printf "%s\n" "$ac_res" >&6; }
2856  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2857
2858} # ac_fn_c_check_type
2859
2860# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2861# --------------------------------------------
2862# Tries to find the compile-time value of EXPR in a program that includes
2863# INCLUDES, setting VAR accordingly. Returns whether the value could be
2864# computed
2865ac_fn_c_compute_int ()
2866{
2867  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2868  if test "$cross_compiling" = yes; then
2869    # Depending upon the size, compute the lo and hi bounds.
2870cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2871/* end confdefs.h.  */
2872$4
2873int
2874main (void)
2875{
2876static int test_array [1 - 2 * !(($2) >= 0)];
2877test_array [0] = 0;
2878return test_array [0];
2879
2880  ;
2881  return 0;
2882}
2883_ACEOF
2884if ac_fn_c_try_compile "$LINENO"
2885then :
2886  ac_lo=0 ac_mid=0
2887  while :; do
2888    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2889/* end confdefs.h.  */
2890$4
2891int
2892main (void)
2893{
2894static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2895test_array [0] = 0;
2896return test_array [0];
2897
2898  ;
2899  return 0;
2900}
2901_ACEOF
2902if ac_fn_c_try_compile "$LINENO"
2903then :
2904  ac_hi=$ac_mid; break
2905else $as_nop
2906  as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2907			if test $ac_lo -le $ac_mid; then
2908			  ac_lo= ac_hi=
2909			  break
2910			fi
2911			as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2912fi
2913rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2914  done
2915else $as_nop
2916  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2917/* end confdefs.h.  */
2918$4
2919int
2920main (void)
2921{
2922static int test_array [1 - 2 * !(($2) < 0)];
2923test_array [0] = 0;
2924return test_array [0];
2925
2926  ;
2927  return 0;
2928}
2929_ACEOF
2930if ac_fn_c_try_compile "$LINENO"
2931then :
2932  ac_hi=-1 ac_mid=-1
2933  while :; do
2934    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2935/* end confdefs.h.  */
2936$4
2937int
2938main (void)
2939{
2940static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2941test_array [0] = 0;
2942return test_array [0];
2943
2944  ;
2945  return 0;
2946}
2947_ACEOF
2948if ac_fn_c_try_compile "$LINENO"
2949then :
2950  ac_lo=$ac_mid; break
2951else $as_nop
2952  as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2953			if test $ac_mid -le $ac_hi; then
2954			  ac_lo= ac_hi=
2955			  break
2956			fi
2957			as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2958fi
2959rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2960  done
2961else $as_nop
2962  ac_lo= ac_hi=
2963fi
2964rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2965fi
2966rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2967# Binary search between lo and hi bounds.
2968while test "x$ac_lo" != "x$ac_hi"; do
2969  as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2970  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2971/* end confdefs.h.  */
2972$4
2973int
2974main (void)
2975{
2976static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2977test_array [0] = 0;
2978return test_array [0];
2979
2980  ;
2981  return 0;
2982}
2983_ACEOF
2984if ac_fn_c_try_compile "$LINENO"
2985then :
2986  ac_hi=$ac_mid
2987else $as_nop
2988  as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2989fi
2990rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2991done
2992case $ac_lo in #((
2993?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2994'') ac_retval=1 ;;
2995esac
2996  else
2997    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2998/* end confdefs.h.  */
2999$4
3000static long int longval (void) { return $2; }
3001static unsigned long int ulongval (void) { return $2; }
3002#include <stdio.h>
3003#include <stdlib.h>
3004int
3005main (void)
3006{
3007
3008  FILE *f = fopen ("conftest.val", "w");
3009  if (! f)
3010    return 1;
3011  if (($2) < 0)
3012    {
3013      long int i = longval ();
3014      if (i != ($2))
3015	return 1;
3016      fprintf (f, "%ld", i);
3017    }
3018  else
3019    {
3020      unsigned long int i = ulongval ();
3021      if (i != ($2))
3022	return 1;
3023      fprintf (f, "%lu", i);
3024    }
3025  /* Do not output a trailing newline, as this causes \r\n confusion
3026     on some platforms.  */
3027  return ferror (f) || fclose (f) != 0;
3028
3029  ;
3030  return 0;
3031}
3032_ACEOF
3033if ac_fn_c_try_run "$LINENO"
3034then :
3035  echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3036else $as_nop
3037  ac_retval=1
3038fi
3039rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3040  conftest.$ac_objext conftest.beam conftest.$ac_ext
3041rm -f conftest.val
3042
3043  fi
3044  eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3045  as_fn_set_status $ac_retval
3046
3047} # ac_fn_c_compute_int
3048ac_configure_args_raw=
3049for ac_arg
3050do
3051  case $ac_arg in
3052  *\'*)
3053    ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3054  esac
3055  as_fn_append ac_configure_args_raw " '$ac_arg'"
3056done
3057
3058case $ac_configure_args_raw in
3059  *$as_nl*)
3060    ac_safe_unquote= ;;
3061  *)
3062    ac_unsafe_z='|&;<>()$`\\"*?[ ''	' # This string ends in space, tab.
3063    ac_unsafe_a="$ac_unsafe_z#~"
3064    ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
3065    ac_configure_args_raw=`      printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
3066esac
3067
3068cat >config.log <<_ACEOF
3069This file contains any messages produced by compilers while
3070running configure, to aid debugging if configure makes a mistake.
3071
3072It was created by PHP $as_me 8.1.1, which was
3073generated by GNU Autoconf 2.71.  Invocation command line was
3074
3075  $ $0$ac_configure_args_raw
3076
3077_ACEOF
3078exec 5>>config.log
3079{
3080cat <<_ASUNAME
3081## --------- ##
3082## Platform. ##
3083## --------- ##
3084
3085hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3086uname -m = `(uname -m) 2>/dev/null || echo unknown`
3087uname -r = `(uname -r) 2>/dev/null || echo unknown`
3088uname -s = `(uname -s) 2>/dev/null || echo unknown`
3089uname -v = `(uname -v) 2>/dev/null || echo unknown`
3090
3091/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3092/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
3093
3094/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
3095/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
3096/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3097/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
3098/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
3099/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
3100/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
3101
3102_ASUNAME
3103
3104as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3105for as_dir in $PATH
3106do
3107  IFS=$as_save_IFS
3108  case $as_dir in #(((
3109    '') as_dir=./ ;;
3110    */) ;;
3111    *) as_dir=$as_dir/ ;;
3112  esac
3113    printf "%s\n" "PATH: $as_dir"
3114  done
3115IFS=$as_save_IFS
3116
3117} >&5
3118
3119cat >&5 <<_ACEOF
3120
3121
3122## ----------- ##
3123## Core tests. ##
3124## ----------- ##
3125
3126_ACEOF
3127
3128
3129# Keep a trace of the command line.
3130# Strip out --no-create and --no-recursion so they do not pile up.
3131# Strip out --silent because we don't want to record it for future runs.
3132# Also quote any args containing shell meta-characters.
3133# Make two passes to allow for proper duplicate-argument suppression.
3134ac_configure_args=
3135ac_configure_args0=
3136ac_configure_args1=
3137ac_must_keep_next=false
3138for ac_pass in 1 2
3139do
3140  for ac_arg
3141  do
3142    case $ac_arg in
3143    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3144    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3145    | -silent | --silent | --silen | --sile | --sil)
3146      continue ;;
3147    *\'*)
3148      ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3149    esac
3150    case $ac_pass in
3151    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3152    2)
3153      as_fn_append ac_configure_args1 " '$ac_arg'"
3154      if test $ac_must_keep_next = true; then
3155	ac_must_keep_next=false # Got value, back to normal.
3156      else
3157	case $ac_arg in
3158	  *=* | --config-cache | -C | -disable-* | --disable-* \
3159	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3160	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3161	  | -with-* | --with-* | -without-* | --without-* | --x)
3162	    case "$ac_configure_args0 " in
3163	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3164	    esac
3165	    ;;
3166	  -* ) ac_must_keep_next=true ;;
3167	esac
3168      fi
3169      as_fn_append ac_configure_args " '$ac_arg'"
3170      ;;
3171    esac
3172  done
3173done
3174{ ac_configure_args0=; unset ac_configure_args0;}
3175{ ac_configure_args1=; unset ac_configure_args1;}
3176
3177# When interrupted or exit'd, cleanup temporary files, and complete
3178# config.log.  We remove comments because anyway the quotes in there
3179# would cause problems or look ugly.
3180# WARNING: Use '\'' to represent an apostrophe within the trap.
3181# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3182trap 'exit_status=$?
3183  # Sanitize IFS.
3184  IFS=" ""	$as_nl"
3185  # Save into config.log some information that might help in debugging.
3186  {
3187    echo
3188
3189    printf "%s\n" "## ---------------- ##
3190## Cache variables. ##
3191## ---------------- ##"
3192    echo
3193    # The following way of writing the cache mishandles newlines in values,
3194(
3195  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3196    eval ac_val=\$$ac_var
3197    case $ac_val in #(
3198    *${as_nl}*)
3199      case $ac_var in #(
3200      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3201printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3202      esac
3203      case $ac_var in #(
3204      _ | IFS | as_nl) ;; #(
3205      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3206      *) { eval $ac_var=; unset $ac_var;} ;;
3207      esac ;;
3208    esac
3209  done
3210  (set) 2>&1 |
3211    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3212    *${as_nl}ac_space=\ *)
3213      sed -n \
3214	"s/'\''/'\''\\\\'\'''\''/g;
3215	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3216      ;; #(
3217    *)
3218      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3219      ;;
3220    esac |
3221    sort
3222)
3223    echo
3224
3225    printf "%s\n" "## ----------------- ##
3226## Output variables. ##
3227## ----------------- ##"
3228    echo
3229    for ac_var in $ac_subst_vars
3230    do
3231      eval ac_val=\$$ac_var
3232      case $ac_val in
3233      *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3234      esac
3235      printf "%s\n" "$ac_var='\''$ac_val'\''"
3236    done | sort
3237    echo
3238
3239    if test -n "$ac_subst_files"; then
3240      printf "%s\n" "## ------------------- ##
3241## File substitutions. ##
3242## ------------------- ##"
3243      echo
3244      for ac_var in $ac_subst_files
3245      do
3246	eval ac_val=\$$ac_var
3247	case $ac_val in
3248	*\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3249	esac
3250	printf "%s\n" "$ac_var='\''$ac_val'\''"
3251      done | sort
3252      echo
3253    fi
3254
3255    if test -s confdefs.h; then
3256      printf "%s\n" "## ----------- ##
3257## confdefs.h. ##
3258## ----------- ##"
3259      echo
3260      cat confdefs.h
3261      echo
3262    fi
3263    test "$ac_signal" != 0 &&
3264      printf "%s\n" "$as_me: caught signal $ac_signal"
3265    printf "%s\n" "$as_me: exit $exit_status"
3266  } >&5
3267  rm -f core *.core core.conftest.* &&
3268    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3269    exit $exit_status
3270' 0
3271for ac_signal in 1 2 13 15; do
3272  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3273done
3274ac_signal=0
3275
3276# confdefs.h avoids OS command line length limits that DEFS can exceed.
3277rm -f -r conftest* confdefs.h
3278
3279printf "%s\n" "/* confdefs.h */" > confdefs.h
3280
3281# Predefined preprocessor variables.
3282
3283printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
3284
3285printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
3286
3287printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
3288
3289printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
3290
3291printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
3292
3293printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
3294
3295
3296# Let the site file select an alternate cache file if it wants to.
3297# Prefer an explicitly selected file to automatically selected ones.
3298if test -n "$CONFIG_SITE"; then
3299  ac_site_files="$CONFIG_SITE"
3300elif test "x$prefix" != xNONE; then
3301  ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
3302else
3303  ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
3304fi
3305
3306for ac_site_file in $ac_site_files
3307do
3308  case $ac_site_file in #(
3309  */*) :
3310     ;; #(
3311  *) :
3312    ac_site_file=./$ac_site_file ;;
3313esac
3314  if test -f "$ac_site_file" && test -r "$ac_site_file"; then
3315    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3316printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
3317    sed 's/^/| /' "$ac_site_file" >&5
3318    . "$ac_site_file" \
3319      || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3320printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3321as_fn_error $? "failed to load site script $ac_site_file
3322See \`config.log' for more details" "$LINENO" 5; }
3323  fi
3324done
3325
3326if test -r "$cache_file"; then
3327  # Some versions of bash will fail to source /dev/null (special files
3328  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3329  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3330    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3331printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
3332    case $cache_file in
3333      [\\/]* | ?:[\\/]* ) . "$cache_file";;
3334      *)                      . "./$cache_file";;
3335    esac
3336  fi
3337else
3338  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3339printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
3340  >$cache_file
3341fi
3342
3343# Test code for whether the C compiler supports C89 (global declarations)
3344ac_c_conftest_c89_globals='
3345/* Does the compiler advertise C89 conformance?
3346   Do not test the value of __STDC__, because some compilers set it to 0
3347   while being otherwise adequately conformant. */
3348#if !defined __STDC__
3349# error "Compiler does not advertise C89 conformance"
3350#endif
3351
3352#include <stddef.h>
3353#include <stdarg.h>
3354struct stat;
3355/* Most of the following tests are stolen from RCS 5.7 src/conf.sh.  */
3356struct buf { int x; };
3357struct buf * (*rcsopen) (struct buf *, struct stat *, int);
3358static char *e (p, i)
3359     char **p;
3360     int i;
3361{
3362  return p[i];
3363}
3364static char *f (char * (*g) (char **, int), char **p, ...)
3365{
3366  char *s;
3367  va_list v;
3368  va_start (v,p);
3369  s = g (p, va_arg (v,int));
3370  va_end (v);
3371  return s;
3372}
3373
3374/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3375   function prototypes and stuff, but not \xHH hex character constants.
3376   These do not provoke an error unfortunately, instead are silently treated
3377   as an "x".  The following induces an error, until -std is added to get
3378   proper ANSI mode.  Curiously \x00 != x always comes out true, for an
3379   array size at least.  It is necessary to write \x00 == 0 to get something
3380   that is true only with -std.  */
3381int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
3382
3383/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3384   inside strings and character constants.  */
3385#define FOO(x) '\''x'\''
3386int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
3387
3388int test (int i, double x);
3389struct s1 {int (*f) (int a);};
3390struct s2 {int (*f) (double a);};
3391int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
3392               int, int);'
3393
3394# Test code for whether the C compiler supports C89 (body of main).
3395ac_c_conftest_c89_main='
3396ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
3397'
3398
3399# Test code for whether the C compiler supports C99 (global declarations)
3400ac_c_conftest_c99_globals='
3401// Does the compiler advertise C99 conformance?
3402#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
3403# error "Compiler does not advertise C99 conformance"
3404#endif
3405
3406#include <stdbool.h>
3407extern int puts (const char *);
3408extern int printf (const char *, ...);
3409extern int dprintf (int, const char *, ...);
3410extern void *malloc (size_t);
3411
3412// Check varargs macros.  These examples are taken from C99 6.10.3.5.
3413// dprintf is used instead of fprintf to avoid needing to declare
3414// FILE and stderr.
3415#define debug(...) dprintf (2, __VA_ARGS__)
3416#define showlist(...) puts (#__VA_ARGS__)
3417#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
3418static void
3419test_varargs_macros (void)
3420{
3421  int x = 1234;
3422  int y = 5678;
3423  debug ("Flag");
3424  debug ("X = %d\n", x);
3425  showlist (The first, second, and third items.);
3426  report (x>y, "x is %d but y is %d", x, y);
3427}
3428
3429// Check long long types.
3430#define BIG64 18446744073709551615ull
3431#define BIG32 4294967295ul
3432#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
3433#if !BIG_OK
3434  #error "your preprocessor is broken"
3435#endif
3436#if BIG_OK
3437#else
3438  #error "your preprocessor is broken"
3439#endif
3440static long long int bignum = -9223372036854775807LL;
3441static unsigned long long int ubignum = BIG64;
3442
3443struct incomplete_array
3444{
3445  int datasize;
3446  double data[];
3447};
3448
3449struct named_init {
3450  int number;
3451  const wchar_t *name;
3452  double average;
3453};
3454
3455typedef const char *ccp;
3456
3457static inline int
3458test_restrict (ccp restrict text)
3459{
3460  // See if C++-style comments work.
3461  // Iterate through items via the restricted pointer.
3462  // Also check for declarations in for loops.
3463  for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
3464    continue;
3465  return 0;
3466}
3467
3468// Check varargs and va_copy.
3469static bool
3470test_varargs (const char *format, ...)
3471{
3472  va_list args;
3473  va_start (args, format);
3474  va_list args_copy;
3475  va_copy (args_copy, args);
3476
3477  const char *str = "";
3478  int number = 0;
3479  float fnumber = 0;
3480
3481  while (*format)
3482    {
3483      switch (*format++)
3484	{
3485	case '\''s'\'': // string
3486	  str = va_arg (args_copy, const char *);
3487	  break;
3488	case '\''d'\'': // int
3489	  number = va_arg (args_copy, int);
3490	  break;
3491	case '\''f'\'': // float
3492	  fnumber = va_arg (args_copy, double);
3493	  break;
3494	default:
3495	  break;
3496	}
3497    }
3498  va_end (args_copy);
3499  va_end (args);
3500
3501  return *str && number && fnumber;
3502}
3503'
3504
3505# Test code for whether the C compiler supports C99 (body of main).
3506ac_c_conftest_c99_main='
3507  // Check bool.
3508  _Bool success = false;
3509  success |= (argc != 0);
3510
3511  // Check restrict.
3512  if (test_restrict ("String literal") == 0)
3513    success = true;
3514  char *restrict newvar = "Another string";
3515
3516  // Check varargs.
3517  success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
3518  test_varargs_macros ();
3519
3520  // Check flexible array members.
3521  struct incomplete_array *ia =
3522    malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
3523  ia->datasize = 10;
3524  for (int i = 0; i < ia->datasize; ++i)
3525    ia->data[i] = i * 1.234;
3526
3527  // Check named initializers.
3528  struct named_init ni = {
3529    .number = 34,
3530    .name = L"Test wide string",
3531    .average = 543.34343,
3532  };
3533
3534  ni.number = 58;
3535
3536  int dynamic_array[ni.number];
3537  dynamic_array[0] = argv[0][0];
3538  dynamic_array[ni.number - 1] = 543;
3539
3540  // work around unused variable warnings
3541  ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
3542	 || dynamic_array[ni.number - 1] != 543);
3543'
3544
3545# Test code for whether the C compiler supports C11 (global declarations)
3546ac_c_conftest_c11_globals='
3547// Does the compiler advertise C11 conformance?
3548#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
3549# error "Compiler does not advertise C11 conformance"
3550#endif
3551
3552// Check _Alignas.
3553char _Alignas (double) aligned_as_double;
3554char _Alignas (0) no_special_alignment;
3555extern char aligned_as_int;
3556char _Alignas (0) _Alignas (int) aligned_as_int;
3557
3558// Check _Alignof.
3559enum
3560{
3561  int_alignment = _Alignof (int),
3562  int_array_alignment = _Alignof (int[100]),
3563  char_alignment = _Alignof (char)
3564};
3565_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
3566
3567// Check _Noreturn.
3568int _Noreturn does_not_return (void) { for (;;) continue; }
3569
3570// Check _Static_assert.
3571struct test_static_assert
3572{
3573  int x;
3574  _Static_assert (sizeof (int) <= sizeof (long int),
3575                  "_Static_assert does not work in struct");
3576  long int y;
3577};
3578
3579// Check UTF-8 literals.
3580#define u8 syntax error!
3581char const utf8_literal[] = u8"happens to be ASCII" "another string";
3582
3583// Check duplicate typedefs.
3584typedef long *long_ptr;
3585typedef long int *long_ptr;
3586typedef long_ptr long_ptr;
3587
3588// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
3589struct anonymous
3590{
3591  union {
3592    struct { int i; int j; };
3593    struct { int k; long int l; } w;
3594  };
3595  int m;
3596} v1;
3597'
3598
3599# Test code for whether the C compiler supports C11 (body of main).
3600ac_c_conftest_c11_main='
3601  _Static_assert ((offsetof (struct anonymous, i)
3602		   == offsetof (struct anonymous, w.k)),
3603		  "Anonymous union alignment botch");
3604  v1.i = 2;
3605  v1.w.k = 5;
3606  ok |= v1.i != 5;
3607'
3608
3609# Test code for whether the C compiler supports C11 (complete).
3610ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
3611${ac_c_conftest_c99_globals}
3612${ac_c_conftest_c11_globals}
3613
3614int
3615main (int argc, char **argv)
3616{
3617  int ok = 0;
3618  ${ac_c_conftest_c89_main}
3619  ${ac_c_conftest_c99_main}
3620  ${ac_c_conftest_c11_main}
3621  return ok;
3622}
3623"
3624
3625# Test code for whether the C compiler supports C99 (complete).
3626ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
3627${ac_c_conftest_c99_globals}
3628
3629int
3630main (int argc, char **argv)
3631{
3632  int ok = 0;
3633  ${ac_c_conftest_c89_main}
3634  ${ac_c_conftest_c99_main}
3635  return ok;
3636}
3637"
3638
3639# Test code for whether the C compiler supports C89 (complete).
3640ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
3641
3642int
3643main (int argc, char **argv)
3644{
3645  int ok = 0;
3646  ${ac_c_conftest_c89_main}
3647  return ok;
3648}
3649"
3650
3651as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
3652as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
3653as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
3654as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
3655as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
3656as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
3657as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
3658as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
3659as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
3660as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H"
3661as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H"
3662# Test code for whether the C++ compiler supports C++98 (global declarations)
3663ac_cxx_conftest_cxx98_globals='
3664// Does the compiler advertise C++98 conformance?
3665#if !defined __cplusplus || __cplusplus < 199711L
3666# error "Compiler does not advertise C++98 conformance"
3667#endif
3668
3669// These inclusions are to reject old compilers that
3670// lack the unsuffixed header files.
3671#include <cstdlib>
3672#include <exception>
3673
3674// <cassert> and <cstring> are *not* freestanding headers in C++98.
3675extern void assert (int);
3676namespace std {
3677  extern int strcmp (const char *, const char *);
3678}
3679
3680// Namespaces, exceptions, and templates were all added after "C++ 2.0".
3681using std::exception;
3682using std::strcmp;
3683
3684namespace {
3685
3686void test_exception_syntax()
3687{
3688  try {
3689    throw "test";
3690  } catch (const char *s) {
3691    // Extra parentheses suppress a warning when building autoconf itself,
3692    // due to lint rules shared with more typical C programs.
3693    assert (!(strcmp) (s, "test"));
3694  }
3695}
3696
3697template <typename T> struct test_template
3698{
3699  T const val;
3700  explicit test_template(T t) : val(t) {}
3701  template <typename U> T add(U u) { return static_cast<T>(u) + val; }
3702};
3703
3704} // anonymous namespace
3705'
3706
3707# Test code for whether the C++ compiler supports C++98 (body of main)
3708ac_cxx_conftest_cxx98_main='
3709  assert (argc);
3710  assert (! argv[0]);
3711{
3712  test_exception_syntax ();
3713  test_template<double> tt (2.0);
3714  assert (tt.add (4) == 6.0);
3715  assert (true && !false);
3716}
3717'
3718
3719# Test code for whether the C++ compiler supports C++11 (global declarations)
3720ac_cxx_conftest_cxx11_globals='
3721// Does the compiler advertise C++ 2011 conformance?
3722#if !defined __cplusplus || __cplusplus < 201103L
3723# error "Compiler does not advertise C++11 conformance"
3724#endif
3725
3726namespace cxx11test
3727{
3728  constexpr int get_val() { return 20; }
3729
3730  struct testinit
3731  {
3732    int i;
3733    double d;
3734  };
3735
3736  class delegate
3737  {
3738  public:
3739    delegate(int n) : n(n) {}
3740    delegate(): delegate(2354) {}
3741
3742    virtual int getval() { return this->n; };
3743  protected:
3744    int n;
3745  };
3746
3747  class overridden : public delegate
3748  {
3749  public:
3750    overridden(int n): delegate(n) {}
3751    virtual int getval() override final { return this->n * 2; }
3752  };
3753
3754  class nocopy
3755  {
3756  public:
3757    nocopy(int i): i(i) {}
3758    nocopy() = default;
3759    nocopy(const nocopy&) = delete;
3760    nocopy & operator=(const nocopy&) = delete;
3761  private:
3762    int i;
3763  };
3764
3765  // for testing lambda expressions
3766  template <typename Ret, typename Fn> Ret eval(Fn f, Ret v)
3767  {
3768    return f(v);
3769  }
3770
3771  // for testing variadic templates and trailing return types
3772  template <typename V> auto sum(V first) -> V
3773  {
3774    return first;
3775  }
3776  template <typename V, typename... Args> auto sum(V first, Args... rest) -> V
3777  {
3778    return first + sum(rest...);
3779  }
3780}
3781'
3782
3783# Test code for whether the C++ compiler supports C++11 (body of main)
3784ac_cxx_conftest_cxx11_main='
3785{
3786  // Test auto and decltype
3787  auto a1 = 6538;
3788  auto a2 = 48573953.4;
3789  auto a3 = "String literal";
3790
3791  int total = 0;
3792  for (auto i = a3; *i; ++i) { total += *i; }
3793
3794  decltype(a2) a4 = 34895.034;
3795}
3796{
3797  // Test constexpr
3798  short sa[cxx11test::get_val()] = { 0 };
3799}
3800{
3801  // Test initializer lists
3802  cxx11test::testinit il = { 4323, 435234.23544 };
3803}
3804{
3805  // Test range-based for
3806  int array[] = {9, 7, 13, 15, 4, 18, 12, 10, 5, 3,
3807                 14, 19, 17, 8, 6, 20, 16, 2, 11, 1};
3808  for (auto &x : array) { x += 23; }
3809}
3810{
3811  // Test lambda expressions
3812  using cxx11test::eval;
3813  assert (eval ([](int x) { return x*2; }, 21) == 42);
3814  double d = 2.0;
3815  assert (eval ([&](double x) { return d += x; }, 3.0) == 5.0);
3816  assert (d == 5.0);
3817  assert (eval ([=](double x) mutable { return d += x; }, 4.0) == 9.0);
3818  assert (d == 5.0);
3819}
3820{
3821  // Test use of variadic templates
3822  using cxx11test::sum;
3823  auto a = sum(1);
3824  auto b = sum(1, 2);
3825  auto c = sum(1.0, 2.0, 3.0);
3826}
3827{
3828  // Test constructor delegation
3829  cxx11test::delegate d1;
3830  cxx11test::delegate d2();
3831  cxx11test::delegate d3(45);
3832}
3833{
3834  // Test override and final
3835  cxx11test::overridden o1(55464);
3836}
3837{
3838  // Test nullptr
3839  char *c = nullptr;
3840}
3841{
3842  // Test template brackets
3843  test_template<::test_template<int>> v(test_template<int>(12));
3844}
3845{
3846  // Unicode literals
3847  char const *utf8 = u8"UTF-8 string \u2500";
3848  char16_t const *utf16 = u"UTF-8 string \u2500";
3849  char32_t const *utf32 = U"UTF-32 string \u2500";
3850}
3851'
3852
3853# Test code for whether the C compiler supports C++11 (complete).
3854ac_cxx_conftest_cxx11_program="${ac_cxx_conftest_cxx98_globals}
3855${ac_cxx_conftest_cxx11_globals}
3856
3857int
3858main (int argc, char **argv)
3859{
3860  int ok = 0;
3861  ${ac_cxx_conftest_cxx98_main}
3862  ${ac_cxx_conftest_cxx11_main}
3863  return ok;
3864}
3865"
3866
3867# Test code for whether the C compiler supports C++98 (complete).
3868ac_cxx_conftest_cxx98_program="${ac_cxx_conftest_cxx98_globals}
3869int
3870main (int argc, char **argv)
3871{
3872  int ok = 0;
3873  ${ac_cxx_conftest_cxx98_main}
3874  return ok;
3875}
3876"
3877
3878
3879# Auxiliary files required by this configure script.
3880ac_aux_files="config.guess config.sub"
3881
3882# Locations in which to look for auxiliary files.
3883ac_aux_dir_candidates="${srcdir}/build"
3884
3885# Search for a directory containing all of the required auxiliary files,
3886# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates.
3887# If we don't find one directory that contains all the files we need,
3888# we report the set of missing files from the *first* directory in
3889# $ac_aux_dir_candidates and give up.
3890ac_missing_aux_files=""
3891ac_first_candidate=:
3892printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5
3893as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3894as_found=false
3895for as_dir in $ac_aux_dir_candidates
3896do
3897  IFS=$as_save_IFS
3898  case $as_dir in #(((
3899    '') as_dir=./ ;;
3900    */) ;;
3901    *) as_dir=$as_dir/ ;;
3902  esac
3903  as_found=:
3904
3905  printf "%s\n" "$as_me:${as_lineno-$LINENO}:  trying $as_dir" >&5
3906  ac_aux_dir_found=yes
3907  ac_install_sh=
3908  for ac_aux in $ac_aux_files
3909  do
3910    # As a special case, if "install-sh" is required, that requirement
3911    # can be satisfied by any of "install-sh", "install.sh", or "shtool",
3912    # and $ac_install_sh is set appropriately for whichever one is found.
3913    if test x"$ac_aux" = x"install-sh"
3914    then
3915      if test -f "${as_dir}install-sh"; then
3916        printf "%s\n" "$as_me:${as_lineno-$LINENO}:   ${as_dir}install-sh found" >&5
3917        ac_install_sh="${as_dir}install-sh -c"
3918      elif test -f "${as_dir}install.sh"; then
3919        printf "%s\n" "$as_me:${as_lineno-$LINENO}:   ${as_dir}install.sh found" >&5
3920        ac_install_sh="${as_dir}install.sh -c"
3921      elif test -f "${as_dir}shtool"; then
3922        printf "%s\n" "$as_me:${as_lineno-$LINENO}:   ${as_dir}shtool found" >&5
3923        ac_install_sh="${as_dir}shtool install -c"
3924      else
3925        ac_aux_dir_found=no
3926        if $ac_first_candidate; then
3927          ac_missing_aux_files="${ac_missing_aux_files} install-sh"
3928        else
3929          break
3930        fi
3931      fi
3932    else
3933      if test -f "${as_dir}${ac_aux}"; then
3934        printf "%s\n" "$as_me:${as_lineno-$LINENO}:   ${as_dir}${ac_aux} found" >&5
3935      else
3936        ac_aux_dir_found=no
3937        if $ac_first_candidate; then
3938          ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}"
3939        else
3940          break
3941        fi
3942      fi
3943    fi
3944  done
3945  if test "$ac_aux_dir_found" = yes; then
3946    ac_aux_dir="$as_dir"
3947    break
3948  fi
3949  ac_first_candidate=false
3950
3951  as_found=false
3952done
3953IFS=$as_save_IFS
3954if $as_found
3955then :
3956
3957else $as_nop
3958  as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5
3959fi
3960
3961
3962# These three variables are undocumented and unsupported,
3963# and are intended to be withdrawn in a future Autoconf release.
3964# They can cause serious problems if a builder's source tree is in a directory
3965# whose full name contains unusual characters.
3966if test -f "${ac_aux_dir}config.guess"; then
3967  ac_config_guess="$SHELL ${ac_aux_dir}config.guess"
3968fi
3969if test -f "${ac_aux_dir}config.sub"; then
3970  ac_config_sub="$SHELL ${ac_aux_dir}config.sub"
3971fi
3972if test -f "$ac_aux_dir/configure"; then
3973  ac_configure="$SHELL ${ac_aux_dir}configure"
3974fi
3975
3976# Check that the precious variables saved in the cache have kept the same
3977# value.
3978ac_cache_corrupted=false
3979for ac_var in $ac_precious_vars; do
3980  eval ac_old_set=\$ac_cv_env_${ac_var}_set
3981  eval ac_new_set=\$ac_env_${ac_var}_set
3982  eval ac_old_val=\$ac_cv_env_${ac_var}_value
3983  eval ac_new_val=\$ac_env_${ac_var}_value
3984  case $ac_old_set,$ac_new_set in
3985    set,)
3986      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3987printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3988      ac_cache_corrupted=: ;;
3989    ,set)
3990      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3991printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3992      ac_cache_corrupted=: ;;
3993    ,);;
3994    *)
3995      if test "x$ac_old_val" != "x$ac_new_val"; then
3996	# differences in whitespace do not lead to failure.
3997	ac_old_val_w=`echo x $ac_old_val`
3998	ac_new_val_w=`echo x $ac_new_val`
3999	if test "$ac_old_val_w" != "$ac_new_val_w"; then
4000	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
4001printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
4002	  ac_cache_corrupted=:
4003	else
4004	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
4005printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
4006	  eval $ac_var=\$ac_old_val
4007	fi
4008	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
4009printf "%s\n" "$as_me:   former value:  \`$ac_old_val'" >&2;}
4010	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
4011printf "%s\n" "$as_me:   current value: \`$ac_new_val'" >&2;}
4012      fi;;
4013  esac
4014  # Pass precious variables to config.status.
4015  if test "$ac_new_set" = set; then
4016    case $ac_new_val in
4017    *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
4018    *) ac_arg=$ac_var=$ac_new_val ;;
4019    esac
4020    case " $ac_configure_args " in
4021      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
4022      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
4023    esac
4024  fi
4025done
4026if $ac_cache_corrupted; then
4027  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4028printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4029  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
4030printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
4031  as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
4032	    and start over" "$LINENO" 5
4033fi
4034## -------------------- ##
4035## Main body of script. ##
4036## -------------------- ##
4037
4038ac_ext=c
4039ac_cpp='$CPP $CPPFLAGS'
4040ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4041ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4042ac_compiler_gnu=$ac_cv_c_compiler_gnu
4043
4044
4045
4046
4047
4048
4049
4050
4051{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4052printf %s "checking for grep that handles long lines and -e... " >&6; }
4053if test ${ac_cv_path_GREP+y}
4054then :
4055  printf %s "(cached) " >&6
4056else $as_nop
4057  if test -z "$GREP"; then
4058  ac_path_GREP_found=false
4059  # Loop through the user's path and test for each of PROGNAME-LIST
4060  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4061for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4062do
4063  IFS=$as_save_IFS
4064  case $as_dir in #(((
4065    '') as_dir=./ ;;
4066    */) ;;
4067    *) as_dir=$as_dir/ ;;
4068  esac
4069    for ac_prog in grep ggrep
4070   do
4071    for ac_exec_ext in '' $ac_executable_extensions; do
4072      ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
4073      as_fn_executable_p "$ac_path_GREP" || continue
4074# Check for GNU ac_path_GREP and select it if it is found.
4075  # Check for GNU $ac_path_GREP
4076case `"$ac_path_GREP" --version 2>&1` in
4077*GNU*)
4078  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4079*)
4080  ac_count=0
4081  printf %s 0123456789 >"conftest.in"
4082  while :
4083  do
4084    cat "conftest.in" "conftest.in" >"conftest.tmp"
4085    mv "conftest.tmp" "conftest.in"
4086    cp "conftest.in" "conftest.nl"
4087    printf "%s\n" 'GREP' >> "conftest.nl"
4088    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4089    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4090    as_fn_arith $ac_count + 1 && ac_count=$as_val
4091    if test $ac_count -gt ${ac_path_GREP_max-0}; then
4092      # Best one so far, save it but keep looking for a better one
4093      ac_cv_path_GREP="$ac_path_GREP"
4094      ac_path_GREP_max=$ac_count
4095    fi
4096    # 10*(2^10) chars as input seems more than enough
4097    test $ac_count -gt 10 && break
4098  done
4099  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4100esac
4101
4102      $ac_path_GREP_found && break 3
4103    done
4104  done
4105  done
4106IFS=$as_save_IFS
4107  if test -z "$ac_cv_path_GREP"; then
4108    as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4109  fi
4110else
4111  ac_cv_path_GREP=$GREP
4112fi
4113
4114fi
4115{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4116printf "%s\n" "$ac_cv_path_GREP" >&6; }
4117 GREP="$ac_cv_path_GREP"
4118
4119
4120{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4121printf %s "checking for egrep... " >&6; }
4122if test ${ac_cv_path_EGREP+y}
4123then :
4124  printf %s "(cached) " >&6
4125else $as_nop
4126  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4127   then ac_cv_path_EGREP="$GREP -E"
4128   else
4129     if test -z "$EGREP"; then
4130  ac_path_EGREP_found=false
4131  # Loop through the user's path and test for each of PROGNAME-LIST
4132  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4133for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4134do
4135  IFS=$as_save_IFS
4136  case $as_dir in #(((
4137    '') as_dir=./ ;;
4138    */) ;;
4139    *) as_dir=$as_dir/ ;;
4140  esac
4141    for ac_prog in egrep
4142   do
4143    for ac_exec_ext in '' $ac_executable_extensions; do
4144      ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
4145      as_fn_executable_p "$ac_path_EGREP" || continue
4146# Check for GNU ac_path_EGREP and select it if it is found.
4147  # Check for GNU $ac_path_EGREP
4148case `"$ac_path_EGREP" --version 2>&1` in
4149*GNU*)
4150  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4151*)
4152  ac_count=0
4153  printf %s 0123456789 >"conftest.in"
4154  while :
4155  do
4156    cat "conftest.in" "conftest.in" >"conftest.tmp"
4157    mv "conftest.tmp" "conftest.in"
4158    cp "conftest.in" "conftest.nl"
4159    printf "%s\n" 'EGREP' >> "conftest.nl"
4160    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4161    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4162    as_fn_arith $ac_count + 1 && ac_count=$as_val
4163    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4164      # Best one so far, save it but keep looking for a better one
4165      ac_cv_path_EGREP="$ac_path_EGREP"
4166      ac_path_EGREP_max=$ac_count
4167    fi
4168    # 10*(2^10) chars as input seems more than enough
4169    test $ac_count -gt 10 && break
4170  done
4171  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4172esac
4173
4174      $ac_path_EGREP_found && break 3
4175    done
4176  done
4177  done
4178IFS=$as_save_IFS
4179  if test -z "$ac_cv_path_EGREP"; then
4180    as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4181  fi
4182else
4183  ac_cv_path_EGREP=$EGREP
4184fi
4185
4186   fi
4187fi
4188{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4189printf "%s\n" "$ac_cv_path_EGREP" >&6; }
4190 EGREP="$ac_cv_path_EGREP"
4191
4192
4193{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
4194printf %s "checking for a sed that does not truncate output... " >&6; }
4195if test ${ac_cv_path_SED+y}
4196then :
4197  printf %s "(cached) " >&6
4198else $as_nop
4199            ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4200     for ac_i in 1 2 3 4 5 6 7; do
4201       ac_script="$ac_script$as_nl$ac_script"
4202     done
4203     echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4204     { ac_script=; unset ac_script;}
4205     if test -z "$SED"; then
4206  ac_path_SED_found=false
4207  # Loop through the user's path and test for each of PROGNAME-LIST
4208  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4209for as_dir in $PATH
4210do
4211  IFS=$as_save_IFS
4212  case $as_dir in #(((
4213    '') as_dir=./ ;;
4214    */) ;;
4215    *) as_dir=$as_dir/ ;;
4216  esac
4217    for ac_prog in sed gsed
4218   do
4219    for ac_exec_ext in '' $ac_executable_extensions; do
4220      ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
4221      as_fn_executable_p "$ac_path_SED" || continue
4222# Check for GNU ac_path_SED and select it if it is found.
4223  # Check for GNU $ac_path_SED
4224case `"$ac_path_SED" --version 2>&1` in
4225*GNU*)
4226  ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4227*)
4228  ac_count=0
4229  printf %s 0123456789 >"conftest.in"
4230  while :
4231  do
4232    cat "conftest.in" "conftest.in" >"conftest.tmp"
4233    mv "conftest.tmp" "conftest.in"
4234    cp "conftest.in" "conftest.nl"
4235    printf "%s\n" '' >> "conftest.nl"
4236    "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4237    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4238    as_fn_arith $ac_count + 1 && ac_count=$as_val
4239    if test $ac_count -gt ${ac_path_SED_max-0}; then
4240      # Best one so far, save it but keep looking for a better one
4241      ac_cv_path_SED="$ac_path_SED"
4242      ac_path_SED_max=$ac_count
4243    fi
4244    # 10*(2^10) chars as input seems more than enough
4245    test $ac_count -gt 10 && break
4246  done
4247  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4248esac
4249
4250      $ac_path_SED_found && break 3
4251    done
4252  done
4253  done
4254IFS=$as_save_IFS
4255  if test -z "$ac_cv_path_SED"; then
4256    as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
4257  fi
4258else
4259  ac_cv_path_SED=$SED
4260fi
4261
4262fi
4263{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
4264printf "%s\n" "$ac_cv_path_SED" >&6; }
4265 SED="$ac_cv_path_SED"
4266  rm -f conftest.sed
4267
4268
4269
4270
4271
4272
4273
4274  PHP_VAR_SUBST="$PHP_VAR_SUBST EGREP"
4275
4276
4277
4278
4279
4280  PHP_VAR_SUBST="$PHP_VAR_SUBST SED"
4281
4282
4283  test -f config.nice && mv config.nice config.nice.old
4284  rm -f config.nice.old
4285  cat >config.nice<<EOF
4286#! /bin/sh
4287#
4288# Created by configure
4289
4290EOF
4291
4292  clean_configure_args=$ac_configure_args
4293  for var in CFLAGS CXXFLAGS CPPFLAGS LDFLAGS EXTRA_LDFLAGS_PROGRAM LIBS CC CXX; do
4294    eval val=\$$var
4295    if test -n "$val"; then
4296      echo "$var='$val' \\" >> config.nice
4297      if test `expr "X$ac_configure_args" : ".*${var}.*"` != 0; then
4298        clean_configure_args=$(echo $clean_configure_args | sed -e "s#'$var=$val'##")
4299      fi
4300    fi
4301  done
4302
4303  echo "'$0' \\" >> config.nice
4304  if test `expr " $0" : " '.*"` = 0; then
4305    CONFIGURE_COMMAND="$CONFIGURE_COMMAND '$0'"
4306  else
4307    CONFIGURE_COMMAND="$CONFIGURE_COMMAND $0"
4308  fi
4309  CONFIGURE_ARGS="$clean_configure_args"
4310  while test "X$CONFIGURE_ARGS" != "X";
4311  do
4312   if CURRENT_ARG=`expr "X$CONFIGURE_ARGS" : "X *\('[^']*'\)"`
4313   then
4314     CONFIGURE_ARGS=`expr "X$CONFIGURE_ARGS" : "X *'[^']*' \(.*\)"`
4315   elif CURRENT_ARG=`expr "X$CONFIGURE_ARGS" : "X *\([^ ]*\)"`
4316   then
4317     CONFIGURE_ARGS=`expr "X$CONFIGURE_ARGS" : "X *[^ ]* \(.*\)"`
4318     CURRENT_ARG="'$CURRENT_ARG'"
4319   else
4320    break
4321   fi
4322   $as_echo "$CURRENT_ARG \\" >>config.nice
4323   CONFIGURE_OPTIONS="$CONFIGURE_OPTIONS $CURRENT_ARG"
4324  done
4325  echo '"$@"' >> config.nice
4326  chmod +x config.nice
4327  CONFIGURE_COMMAND="$CONFIGURE_COMMAND $CONFIGURE_OPTIONS"
4328
4329
4330
4331  PHP_VAR_SUBST="$PHP_VAR_SUBST CONFIGURE_COMMAND"
4332
4333
4334
4335
4336
4337  PHP_VAR_SUBST="$PHP_VAR_SUBST CONFIGURE_OPTIONS"
4338
4339
4340
4341
4342
4343
4344
4345  # Make sure we can run config.sub.
4346$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 ||
4347  as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5
4348
4349{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4350printf %s "checking build system type... " >&6; }
4351if test ${ac_cv_build+y}
4352then :
4353  printf %s "(cached) " >&6
4354else $as_nop
4355  ac_build_alias=$build_alias
4356test "x$ac_build_alias" = x &&
4357  ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
4358test "x$ac_build_alias" = x &&
4359  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4360ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
4361  as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
4362
4363fi
4364{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4365printf "%s\n" "$ac_cv_build" >&6; }
4366case $ac_cv_build in
4367*-*-*) ;;
4368*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4369esac
4370build=$ac_cv_build
4371ac_save_IFS=$IFS; IFS='-'
4372set x $ac_cv_build
4373shift
4374build_cpu=$1
4375build_vendor=$2
4376shift; shift
4377# Remember, the first character of IFS is used to create $*,
4378# except with old shells:
4379build_os=$*
4380IFS=$ac_save_IFS
4381case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4382
4383
4384{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4385printf %s "checking host system type... " >&6; }
4386if test ${ac_cv_host+y}
4387then :
4388  printf %s "(cached) " >&6
4389else $as_nop
4390  if test "x$host_alias" = x; then
4391  ac_cv_host=$ac_cv_build
4392else
4393  ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
4394    as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
4395fi
4396
4397fi
4398{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4399printf "%s\n" "$ac_cv_host" >&6; }
4400case $ac_cv_host in
4401*-*-*) ;;
4402*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4403esac
4404host=$ac_cv_host
4405ac_save_IFS=$IFS; IFS='-'
4406set x $ac_cv_host
4407shift
4408host_cpu=$1
4409host_vendor=$2
4410shift; shift
4411# Remember, the first character of IFS is used to create $*,
4412# except with old shells:
4413host_os=$*
4414IFS=$ac_save_IFS
4415case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4416
4417
4418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
4419printf %s "checking target system type... " >&6; }
4420if test ${ac_cv_target+y}
4421then :
4422  printf %s "(cached) " >&6
4423else $as_nop
4424  if test "x$target_alias" = x; then
4425  ac_cv_target=$ac_cv_host
4426else
4427  ac_cv_target=`$SHELL "${ac_aux_dir}config.sub" $target_alias` ||
4428    as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $target_alias failed" "$LINENO" 5
4429fi
4430
4431fi
4432{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
4433printf "%s\n" "$ac_cv_target" >&6; }
4434case $ac_cv_target in
4435*-*-*) ;;
4436*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
4437esac
4438target=$ac_cv_target
4439ac_save_IFS=$IFS; IFS='-'
4440set x $ac_cv_target
4441shift
4442target_cpu=$1
4443target_vendor=$2
4444shift; shift
4445# Remember, the first character of IFS is used to create $*,
4446# except with old shells:
4447target_os=$*
4448IFS=$ac_save_IFS
4449case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
4450
4451
4452# The aliases save the names the user supplied, while $host etc.
4453# will get canonicalized.
4454test -n "$target_alias" &&
4455  test "$program_prefix$program_suffix$program_transform_name" = \
4456    NONENONEs,x,x, &&
4457  program_prefix=${target_alias}-
4458
4459        if test -z "$host_alias" && test -n "$host"; then
4460    host_alias=$host
4461  fi
4462  if test -z "$host_alias"; then
4463    as_fn_error $? "host_alias is not set!" "$LINENO" 5
4464  fi
4465
4466
4467ac_config_headers="$ac_config_headers main/php_config.h"
4468
4469
4470
4471
4472
4473ac_IFS=$IFS; IFS="."
4474set $(echo 8.1.1 | "${SED}" 's/\([0-9\.]*\)\(.*\)/\1\.\2/')
4475IFS=$ac_IFS
4476PHP_MAJOR_VERSION=$1
4477PHP_MINOR_VERSION=$2
4478PHP_RELEASE_VERSION=$3
4479PHP_EXTRA_VERSION=$4
4480PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
4481PHP_VERSION_ID=`expr $PHP_MAJOR_VERSION \* 10000 + $PHP_MINOR_VERSION \* 100 + $PHP_RELEASE_VERSION`
4482
4483
4484  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_MAJOR_VERSION"
4485
4486
4487  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_MINOR_VERSION"
4488
4489
4490  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_RELEASE_VERSION"
4491
4492
4493  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_EXTRA_VERSION"
4494
4495
4496
4497
4498echo "/* automatically generated by configure */" > php_version.h.new
4499echo "/* edit configure.ac to change version number */" >> php_version.h.new
4500echo "#define PHP_MAJOR_VERSION $PHP_MAJOR_VERSION" >> php_version.h.new
4501echo "#define PHP_MINOR_VERSION $PHP_MINOR_VERSION" >> php_version.h.new
4502echo "#define PHP_RELEASE_VERSION $PHP_RELEASE_VERSION" >> php_version.h.new
4503echo "#define PHP_EXTRA_VERSION \"$PHP_EXTRA_VERSION\"" >> php_version.h.new
4504echo "#define PHP_VERSION \"$PHP_VERSION\"" >> php_version.h.new
4505echo "#define PHP_VERSION_ID $PHP_VERSION_ID" >> php_version.h.new
4506cmp php_version.h.new $srcdir/main/php_version.h >/dev/null 2>&1
4507if test $? -ne 0 ; then
4508  rm -f $srcdir/main/php_version.h && mv php_version.h.new $srcdir/main/php_version.h && \
4509  echo 'Updated main/php_version.h'
4510else
4511  rm -f php_version.h.new
4512fi
4513
4514
4515php_shtool=$srcdir/build/shtool
4516T_MD=`$php_shtool echo -n -e %B`
4517T_ME=`$php_shtool echo -n -e %b`
4518
4519
4520test -d include || $php_shtool mkdir include
4521> Makefile.objects
4522> Makefile.fragments
4523pattern=define
4524$EGREP $pattern'.*include/php' $srcdir/configure|$SED 's/.*>//'|xargs touch 2>/dev/null
4525
4526
4527test -z "$CFLAGS" && auto_cflags=1
4528
4529abs_srcdir=`(cd $srcdir; pwd)`
4530abs_builddir=`pwd`
4531
4532
4533$php_shtool mkdir -p libs
4534rm -f libs/*
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
4545	if test -n "$ac_tool_prefix"; then
4546  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
4547set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
4548{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4549printf %s "checking for $ac_word... " >&6; }
4550if test ${ac_cv_path_PKG_CONFIG+y}
4551then :
4552  printf %s "(cached) " >&6
4553else $as_nop
4554  case $PKG_CONFIG in
4555  [\\/]* | ?:[\\/]*)
4556  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
4557  ;;
4558  *)
4559  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4560for as_dir in $PATH
4561do
4562  IFS=$as_save_IFS
4563  case $as_dir in #(((
4564    '') as_dir=./ ;;
4565    */) ;;
4566    *) as_dir=$as_dir/ ;;
4567  esac
4568    for ac_exec_ext in '' $ac_executable_extensions; do
4569  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4570    ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
4571    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4572    break 2
4573  fi
4574done
4575  done
4576IFS=$as_save_IFS
4577
4578  ;;
4579esac
4580fi
4581PKG_CONFIG=$ac_cv_path_PKG_CONFIG
4582if test -n "$PKG_CONFIG"; then
4583  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
4584printf "%s\n" "$PKG_CONFIG" >&6; }
4585else
4586  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4587printf "%s\n" "no" >&6; }
4588fi
4589
4590
4591fi
4592if test -z "$ac_cv_path_PKG_CONFIG"; then
4593  ac_pt_PKG_CONFIG=$PKG_CONFIG
4594  # Extract the first word of "pkg-config", so it can be a program name with args.
4595set dummy pkg-config; ac_word=$2
4596{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4597printf %s "checking for $ac_word... " >&6; }
4598if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
4599then :
4600  printf %s "(cached) " >&6
4601else $as_nop
4602  case $ac_pt_PKG_CONFIG in
4603  [\\/]* | ?:[\\/]*)
4604  ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
4605  ;;
4606  *)
4607  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4608for as_dir in $PATH
4609do
4610  IFS=$as_save_IFS
4611  case $as_dir in #(((
4612    '') as_dir=./ ;;
4613    */) ;;
4614    *) as_dir=$as_dir/ ;;
4615  esac
4616    for ac_exec_ext in '' $ac_executable_extensions; do
4617  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4618    ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
4619    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4620    break 2
4621  fi
4622done
4623  done
4624IFS=$as_save_IFS
4625
4626  ;;
4627esac
4628fi
4629ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
4630if test -n "$ac_pt_PKG_CONFIG"; then
4631  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
4632printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
4633else
4634  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4635printf "%s\n" "no" >&6; }
4636fi
4637
4638  if test "x$ac_pt_PKG_CONFIG" = x; then
4639    PKG_CONFIG=""
4640  else
4641    case $cross_compiling:$ac_tool_warned in
4642yes:)
4643{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4644printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4645ac_tool_warned=yes ;;
4646esac
4647    PKG_CONFIG=$ac_pt_PKG_CONFIG
4648  fi
4649else
4650  PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
4651fi
4652
4653fi
4654if test -n "$PKG_CONFIG"; then
4655	_pkg_min_version=0.9.0
4656	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
4657printf %s "checking pkg-config is at least version $_pkg_min_version... " >&6; }
4658	if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
4659		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4660printf "%s\n" "yes" >&6; }
4661	else
4662		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4663printf "%s\n" "no" >&6; }
4664		PKG_CONFIG=""
4665	fi
4666fi
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676ac_ext=c
4677ac_cpp='$CPP $CPPFLAGS'
4678ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4679ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4680ac_compiler_gnu=$ac_cv_c_compiler_gnu
4681if test -n "$ac_tool_prefix"; then
4682  for ac_prog in cc gcc
4683  do
4684    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4685set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4686{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4687printf %s "checking for $ac_word... " >&6; }
4688if test ${ac_cv_prog_CC+y}
4689then :
4690  printf %s "(cached) " >&6
4691else $as_nop
4692  if test -n "$CC"; then
4693  ac_cv_prog_CC="$CC" # Let the user override the test.
4694else
4695as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4696for as_dir in $PATH
4697do
4698  IFS=$as_save_IFS
4699  case $as_dir in #(((
4700    '') as_dir=./ ;;
4701    */) ;;
4702    *) as_dir=$as_dir/ ;;
4703  esac
4704    for ac_exec_ext in '' $ac_executable_extensions; do
4705  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4706    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4707    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4708    break 2
4709  fi
4710done
4711  done
4712IFS=$as_save_IFS
4713
4714fi
4715fi
4716CC=$ac_cv_prog_CC
4717if test -n "$CC"; then
4718  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4719printf "%s\n" "$CC" >&6; }
4720else
4721  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4722printf "%s\n" "no" >&6; }
4723fi
4724
4725
4726    test -n "$CC" && break
4727  done
4728fi
4729if test -z "$CC"; then
4730  ac_ct_CC=$CC
4731  for ac_prog in cc gcc
4732do
4733  # Extract the first word of "$ac_prog", so it can be a program name with args.
4734set dummy $ac_prog; ac_word=$2
4735{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4736printf %s "checking for $ac_word... " >&6; }
4737if test ${ac_cv_prog_ac_ct_CC+y}
4738then :
4739  printf %s "(cached) " >&6
4740else $as_nop
4741  if test -n "$ac_ct_CC"; then
4742  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4743else
4744as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4745for as_dir in $PATH
4746do
4747  IFS=$as_save_IFS
4748  case $as_dir in #(((
4749    '') as_dir=./ ;;
4750    */) ;;
4751    *) as_dir=$as_dir/ ;;
4752  esac
4753    for ac_exec_ext in '' $ac_executable_extensions; do
4754  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4755    ac_cv_prog_ac_ct_CC="$ac_prog"
4756    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4757    break 2
4758  fi
4759done
4760  done
4761IFS=$as_save_IFS
4762
4763fi
4764fi
4765ac_ct_CC=$ac_cv_prog_ac_ct_CC
4766if test -n "$ac_ct_CC"; then
4767  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4768printf "%s\n" "$ac_ct_CC" >&6; }
4769else
4770  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4771printf "%s\n" "no" >&6; }
4772fi
4773
4774
4775  test -n "$ac_ct_CC" && break
4776done
4777
4778  if test "x$ac_ct_CC" = x; then
4779    CC=""
4780  else
4781    case $cross_compiling:$ac_tool_warned in
4782yes:)
4783{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4784printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4785ac_tool_warned=yes ;;
4786esac
4787    CC=$ac_ct_CC
4788  fi
4789fi
4790
4791
4792test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4793printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4794as_fn_error $? "no acceptable C compiler found in \$PATH
4795See \`config.log' for more details" "$LINENO" 5; }
4796
4797# Provide some information about the compiler.
4798printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4799set X $ac_compile
4800ac_compiler=$2
4801for ac_option in --version -v -V -qversion -version; do
4802  { { ac_try="$ac_compiler $ac_option >&5"
4803case "(($ac_try" in
4804  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4805  *) ac_try_echo=$ac_try;;
4806esac
4807eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4808printf "%s\n" "$ac_try_echo"; } >&5
4809  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4810  ac_status=$?
4811  if test -s conftest.err; then
4812    sed '10a\
4813... rest of stderr output deleted ...
4814         10q' conftest.err >conftest.er1
4815    cat conftest.er1 >&5
4816  fi
4817  rm -f conftest.er1 conftest.err
4818  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4819  test $ac_status = 0; }
4820done
4821
4822cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4823/* end confdefs.h.  */
4824
4825int
4826main (void)
4827{
4828
4829  ;
4830  return 0;
4831}
4832_ACEOF
4833ac_clean_files_save=$ac_clean_files
4834ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4835# Try to create an executable without -o first, disregard a.out.
4836# It will help us diagnose broken compilers, and finding out an intuition
4837# of exeext.
4838{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4839printf %s "checking whether the C compiler works... " >&6; }
4840ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4841
4842# The possible output files:
4843ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4844
4845ac_rmfiles=
4846for ac_file in $ac_files
4847do
4848  case $ac_file in
4849    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4850    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4851  esac
4852done
4853rm -f $ac_rmfiles
4854
4855if { { ac_try="$ac_link_default"
4856case "(($ac_try" in
4857  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4858  *) ac_try_echo=$ac_try;;
4859esac
4860eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4861printf "%s\n" "$ac_try_echo"; } >&5
4862  (eval "$ac_link_default") 2>&5
4863  ac_status=$?
4864  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4865  test $ac_status = 0; }
4866then :
4867  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4868# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4869# in a Makefile.  We should not override ac_cv_exeext if it was cached,
4870# so that the user can short-circuit this test for compilers unknown to
4871# Autoconf.
4872for ac_file in $ac_files ''
4873do
4874  test -f "$ac_file" || continue
4875  case $ac_file in
4876    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4877	;;
4878    [ab].out )
4879	# We found the default executable, but exeext='' is most
4880	# certainly right.
4881	break;;
4882    *.* )
4883	if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
4884	then :; else
4885	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4886	fi
4887	# We set ac_cv_exeext here because the later test for it is not
4888	# safe: cross compilers may not add the suffix if given an `-o'
4889	# argument, so we may need to know it at that point already.
4890	# Even if this section looks crufty: it has the advantage of
4891	# actually working.
4892	break;;
4893    * )
4894	break;;
4895  esac
4896done
4897test "$ac_cv_exeext" = no && ac_cv_exeext=
4898
4899else $as_nop
4900  ac_file=''
4901fi
4902if test -z "$ac_file"
4903then :
4904  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4905printf "%s\n" "no" >&6; }
4906printf "%s\n" "$as_me: failed program was:" >&5
4907sed 's/^/| /' conftest.$ac_ext >&5
4908
4909{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4910printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4911as_fn_error 77 "C compiler cannot create executables
4912See \`config.log' for more details" "$LINENO" 5; }
4913else $as_nop
4914  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4915printf "%s\n" "yes" >&6; }
4916fi
4917{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4918printf %s "checking for C compiler default output file name... " >&6; }
4919{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4920printf "%s\n" "$ac_file" >&6; }
4921ac_exeext=$ac_cv_exeext
4922
4923rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4924ac_clean_files=$ac_clean_files_save
4925{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4926printf %s "checking for suffix of executables... " >&6; }
4927if { { ac_try="$ac_link"
4928case "(($ac_try" in
4929  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4930  *) ac_try_echo=$ac_try;;
4931esac
4932eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4933printf "%s\n" "$ac_try_echo"; } >&5
4934  (eval "$ac_link") 2>&5
4935  ac_status=$?
4936  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4937  test $ac_status = 0; }
4938then :
4939  # If both `conftest.exe' and `conftest' are `present' (well, observable)
4940# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4941# work properly (i.e., refer to `conftest.exe'), while it won't with
4942# `rm'.
4943for ac_file in conftest.exe conftest conftest.*; do
4944  test -f "$ac_file" || continue
4945  case $ac_file in
4946    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4947    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4948	  break;;
4949    * ) break;;
4950  esac
4951done
4952else $as_nop
4953  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4954printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4955as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4956See \`config.log' for more details" "$LINENO" 5; }
4957fi
4958rm -f conftest conftest$ac_cv_exeext
4959{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4960printf "%s\n" "$ac_cv_exeext" >&6; }
4961
4962rm -f conftest.$ac_ext
4963EXEEXT=$ac_cv_exeext
4964ac_exeext=$EXEEXT
4965cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4966/* end confdefs.h.  */
4967#include <stdio.h>
4968int
4969main (void)
4970{
4971FILE *f = fopen ("conftest.out", "w");
4972 return ferror (f) || fclose (f) != 0;
4973
4974  ;
4975  return 0;
4976}
4977_ACEOF
4978ac_clean_files="$ac_clean_files conftest.out"
4979# Check that the compiler produces executables we can run.  If not, either
4980# the compiler is broken, or we cross compile.
4981{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4982printf %s "checking whether we are cross compiling... " >&6; }
4983if test "$cross_compiling" != yes; then
4984  { { ac_try="$ac_link"
4985case "(($ac_try" in
4986  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4987  *) ac_try_echo=$ac_try;;
4988esac
4989eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4990printf "%s\n" "$ac_try_echo"; } >&5
4991  (eval "$ac_link") 2>&5
4992  ac_status=$?
4993  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4994  test $ac_status = 0; }
4995  if { ac_try='./conftest$ac_cv_exeext'
4996  { { case "(($ac_try" in
4997  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4998  *) ac_try_echo=$ac_try;;
4999esac
5000eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5001printf "%s\n" "$ac_try_echo"; } >&5
5002  (eval "$ac_try") 2>&5
5003  ac_status=$?
5004  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5005  test $ac_status = 0; }; }; then
5006    cross_compiling=no
5007  else
5008    if test "$cross_compiling" = maybe; then
5009	cross_compiling=yes
5010    else
5011	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5012printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5013as_fn_error 77 "cannot run C compiled programs.
5014If you meant to cross compile, use \`--host'.
5015See \`config.log' for more details" "$LINENO" 5; }
5016    fi
5017  fi
5018fi
5019{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5020printf "%s\n" "$cross_compiling" >&6; }
5021
5022rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5023ac_clean_files=$ac_clean_files_save
5024{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5025printf %s "checking for suffix of object files... " >&6; }
5026if test ${ac_cv_objext+y}
5027then :
5028  printf %s "(cached) " >&6
5029else $as_nop
5030  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5031/* end confdefs.h.  */
5032
5033int
5034main (void)
5035{
5036
5037  ;
5038  return 0;
5039}
5040_ACEOF
5041rm -f conftest.o conftest.obj
5042if { { ac_try="$ac_compile"
5043case "(($ac_try" in
5044  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5045  *) ac_try_echo=$ac_try;;
5046esac
5047eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5048printf "%s\n" "$ac_try_echo"; } >&5
5049  (eval "$ac_compile") 2>&5
5050  ac_status=$?
5051  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5052  test $ac_status = 0; }
5053then :
5054  for ac_file in conftest.o conftest.obj conftest.*; do
5055  test -f "$ac_file" || continue;
5056  case $ac_file in
5057    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5058    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5059       break;;
5060  esac
5061done
5062else $as_nop
5063  printf "%s\n" "$as_me: failed program was:" >&5
5064sed 's/^/| /' conftest.$ac_ext >&5
5065
5066{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5067printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5068as_fn_error $? "cannot compute suffix of object files: cannot compile
5069See \`config.log' for more details" "$LINENO" 5; }
5070fi
5071rm -f conftest.$ac_cv_objext conftest.$ac_ext
5072fi
5073{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5074printf "%s\n" "$ac_cv_objext" >&6; }
5075OBJEXT=$ac_cv_objext
5076ac_objext=$OBJEXT
5077{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
5078printf %s "checking whether the compiler supports GNU C... " >&6; }
5079if test ${ac_cv_c_compiler_gnu+y}
5080then :
5081  printf %s "(cached) " >&6
5082else $as_nop
5083  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5084/* end confdefs.h.  */
5085
5086int
5087main (void)
5088{
5089#ifndef __GNUC__
5090       choke me
5091#endif
5092
5093  ;
5094  return 0;
5095}
5096_ACEOF
5097if ac_fn_c_try_compile "$LINENO"
5098then :
5099  ac_compiler_gnu=yes
5100else $as_nop
5101  ac_compiler_gnu=no
5102fi
5103rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5104ac_cv_c_compiler_gnu=$ac_compiler_gnu
5105
5106fi
5107{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5108printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
5109ac_compiler_gnu=$ac_cv_c_compiler_gnu
5110
5111if test $ac_compiler_gnu = yes; then
5112  GCC=yes
5113else
5114  GCC=
5115fi
5116ac_test_CFLAGS=${CFLAGS+y}
5117ac_save_CFLAGS=$CFLAGS
5118{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5119printf %s "checking whether $CC accepts -g... " >&6; }
5120if test ${ac_cv_prog_cc_g+y}
5121then :
5122  printf %s "(cached) " >&6
5123else $as_nop
5124  ac_save_c_werror_flag=$ac_c_werror_flag
5125   ac_c_werror_flag=yes
5126   ac_cv_prog_cc_g=no
5127   CFLAGS="-g"
5128   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5129/* end confdefs.h.  */
5130
5131int
5132main (void)
5133{
5134
5135  ;
5136  return 0;
5137}
5138_ACEOF
5139if ac_fn_c_try_compile "$LINENO"
5140then :
5141  ac_cv_prog_cc_g=yes
5142else $as_nop
5143  CFLAGS=""
5144      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5145/* end confdefs.h.  */
5146
5147int
5148main (void)
5149{
5150
5151  ;
5152  return 0;
5153}
5154_ACEOF
5155if ac_fn_c_try_compile "$LINENO"
5156then :
5157
5158else $as_nop
5159  ac_c_werror_flag=$ac_save_c_werror_flag
5160	 CFLAGS="-g"
5161	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5162/* end confdefs.h.  */
5163
5164int
5165main (void)
5166{
5167
5168  ;
5169  return 0;
5170}
5171_ACEOF
5172if ac_fn_c_try_compile "$LINENO"
5173then :
5174  ac_cv_prog_cc_g=yes
5175fi
5176rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5177fi
5178rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5179fi
5180rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5181   ac_c_werror_flag=$ac_save_c_werror_flag
5182fi
5183{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5184printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
5185if test $ac_test_CFLAGS; then
5186  CFLAGS=$ac_save_CFLAGS
5187elif test $ac_cv_prog_cc_g = yes; then
5188  if test "$GCC" = yes; then
5189    CFLAGS="-g -O2"
5190  else
5191    CFLAGS="-g"
5192  fi
5193else
5194  if test "$GCC" = yes; then
5195    CFLAGS="-O2"
5196  else
5197    CFLAGS=
5198  fi
5199fi
5200ac_prog_cc_stdc=no
5201if test x$ac_prog_cc_stdc = xno
5202then :
5203  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
5204printf %s "checking for $CC option to enable C11 features... " >&6; }
5205if test ${ac_cv_prog_cc_c11+y}
5206then :
5207  printf %s "(cached) " >&6
5208else $as_nop
5209  ac_cv_prog_cc_c11=no
5210ac_save_CC=$CC
5211cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5212/* end confdefs.h.  */
5213$ac_c_conftest_c11_program
5214_ACEOF
5215for ac_arg in '' -std=gnu11
5216do
5217  CC="$ac_save_CC $ac_arg"
5218  if ac_fn_c_try_compile "$LINENO"
5219then :
5220  ac_cv_prog_cc_c11=$ac_arg
5221fi
5222rm -f core conftest.err conftest.$ac_objext conftest.beam
5223  test "x$ac_cv_prog_cc_c11" != "xno" && break
5224done
5225rm -f conftest.$ac_ext
5226CC=$ac_save_CC
5227fi
5228
5229if test "x$ac_cv_prog_cc_c11" = xno
5230then :
5231  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5232printf "%s\n" "unsupported" >&6; }
5233else $as_nop
5234  if test "x$ac_cv_prog_cc_c11" = x
5235then :
5236  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5237printf "%s\n" "none needed" >&6; }
5238else $as_nop
5239  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
5240printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
5241     CC="$CC $ac_cv_prog_cc_c11"
5242fi
5243  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
5244  ac_prog_cc_stdc=c11
5245fi
5246fi
5247if test x$ac_prog_cc_stdc = xno
5248then :
5249  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
5250printf %s "checking for $CC option to enable C99 features... " >&6; }
5251if test ${ac_cv_prog_cc_c99+y}
5252then :
5253  printf %s "(cached) " >&6
5254else $as_nop
5255  ac_cv_prog_cc_c99=no
5256ac_save_CC=$CC
5257cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5258/* end confdefs.h.  */
5259$ac_c_conftest_c99_program
5260_ACEOF
5261for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
5262do
5263  CC="$ac_save_CC $ac_arg"
5264  if ac_fn_c_try_compile "$LINENO"
5265then :
5266  ac_cv_prog_cc_c99=$ac_arg
5267fi
5268rm -f core conftest.err conftest.$ac_objext conftest.beam
5269  test "x$ac_cv_prog_cc_c99" != "xno" && break
5270done
5271rm -f conftest.$ac_ext
5272CC=$ac_save_CC
5273fi
5274
5275if test "x$ac_cv_prog_cc_c99" = xno
5276then :
5277  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5278printf "%s\n" "unsupported" >&6; }
5279else $as_nop
5280  if test "x$ac_cv_prog_cc_c99" = x
5281then :
5282  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5283printf "%s\n" "none needed" >&6; }
5284else $as_nop
5285  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5286printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
5287     CC="$CC $ac_cv_prog_cc_c99"
5288fi
5289  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5290  ac_prog_cc_stdc=c99
5291fi
5292fi
5293if test x$ac_prog_cc_stdc = xno
5294then :
5295  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
5296printf %s "checking for $CC option to enable C89 features... " >&6; }
5297if test ${ac_cv_prog_cc_c89+y}
5298then :
5299  printf %s "(cached) " >&6
5300else $as_nop
5301  ac_cv_prog_cc_c89=no
5302ac_save_CC=$CC
5303cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5304/* end confdefs.h.  */
5305$ac_c_conftest_c89_program
5306_ACEOF
5307for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5308do
5309  CC="$ac_save_CC $ac_arg"
5310  if ac_fn_c_try_compile "$LINENO"
5311then :
5312  ac_cv_prog_cc_c89=$ac_arg
5313fi
5314rm -f core conftest.err conftest.$ac_objext conftest.beam
5315  test "x$ac_cv_prog_cc_c89" != "xno" && break
5316done
5317rm -f conftest.$ac_ext
5318CC=$ac_save_CC
5319fi
5320
5321if test "x$ac_cv_prog_cc_c89" = xno
5322then :
5323  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5324printf "%s\n" "unsupported" >&6; }
5325else $as_nop
5326  if test "x$ac_cv_prog_cc_c89" = x
5327then :
5328  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5329printf "%s\n" "none needed" >&6; }
5330else $as_nop
5331  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5332printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
5333     CC="$CC $ac_cv_prog_cc_c89"
5334fi
5335  ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5336  ac_prog_cc_stdc=c89
5337fi
5338fi
5339
5340ac_ext=c
5341ac_cpp='$CPP $CPPFLAGS'
5342ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5343ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5344ac_compiler_gnu=$ac_cv_c_compiler_gnu
5345
5346
5347ac_ext=c
5348ac_cpp='$CPP $CPPFLAGS'
5349ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5350ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5351ac_compiler_gnu=$ac_cv_c_compiler_gnu
5352{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5353printf %s "checking how to run the C preprocessor... " >&6; }
5354# On Suns, sometimes $CPP names a directory.
5355if test -n "$CPP" && test -d "$CPP"; then
5356  CPP=
5357fi
5358if test -z "$CPP"; then
5359  if test ${ac_cv_prog_CPP+y}
5360then :
5361  printf %s "(cached) " >&6
5362else $as_nop
5363      # Double quotes because $CC needs to be expanded
5364    for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
5365    do
5366      ac_preproc_ok=false
5367for ac_c_preproc_warn_flag in '' yes
5368do
5369  # Use a header file that comes with gcc, so configuring glibc
5370  # with a fresh cross-compiler works.
5371  # On the NeXT, cc -E runs the code through the compiler's parser,
5372  # not just through cpp. "Syntax error" is here to catch this case.
5373  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5374/* end confdefs.h.  */
5375#include <limits.h>
5376		     Syntax error
5377_ACEOF
5378if ac_fn_c_try_cpp "$LINENO"
5379then :
5380
5381else $as_nop
5382  # Broken: fails on valid input.
5383continue
5384fi
5385rm -f conftest.err conftest.i conftest.$ac_ext
5386
5387  # OK, works on sane cases.  Now check whether nonexistent headers
5388  # can be detected and how.
5389  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5390/* end confdefs.h.  */
5391#include <ac_nonexistent.h>
5392_ACEOF
5393if ac_fn_c_try_cpp "$LINENO"
5394then :
5395  # Broken: success on invalid input.
5396continue
5397else $as_nop
5398  # Passes both tests.
5399ac_preproc_ok=:
5400break
5401fi
5402rm -f conftest.err conftest.i conftest.$ac_ext
5403
5404done
5405# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5406rm -f conftest.i conftest.err conftest.$ac_ext
5407if $ac_preproc_ok
5408then :
5409  break
5410fi
5411
5412    done
5413    ac_cv_prog_CPP=$CPP
5414
5415fi
5416  CPP=$ac_cv_prog_CPP
5417else
5418  ac_cv_prog_CPP=$CPP
5419fi
5420{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5421printf "%s\n" "$CPP" >&6; }
5422ac_preproc_ok=false
5423for ac_c_preproc_warn_flag in '' yes
5424do
5425  # Use a header file that comes with gcc, so configuring glibc
5426  # with a fresh cross-compiler works.
5427  # On the NeXT, cc -E runs the code through the compiler's parser,
5428  # not just through cpp. "Syntax error" is here to catch this case.
5429  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5430/* end confdefs.h.  */
5431#include <limits.h>
5432		     Syntax error
5433_ACEOF
5434if ac_fn_c_try_cpp "$LINENO"
5435then :
5436
5437else $as_nop
5438  # Broken: fails on valid input.
5439continue
5440fi
5441rm -f conftest.err conftest.i conftest.$ac_ext
5442
5443  # OK, works on sane cases.  Now check whether nonexistent headers
5444  # can be detected and how.
5445  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5446/* end confdefs.h.  */
5447#include <ac_nonexistent.h>
5448_ACEOF
5449if ac_fn_c_try_cpp "$LINENO"
5450then :
5451  # Broken: success on invalid input.
5452continue
5453else $as_nop
5454  # Passes both tests.
5455ac_preproc_ok=:
5456break
5457fi
5458rm -f conftest.err conftest.i conftest.$ac_ext
5459
5460done
5461# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5462rm -f conftest.i conftest.err conftest.$ac_ext
5463if $ac_preproc_ok
5464then :
5465
5466else $as_nop
5467  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5468printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5469as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5470See \`config.log' for more details" "$LINENO" 5; }
5471fi
5472
5473ac_ext=c
5474ac_cpp='$CPP $CPPFLAGS'
5475ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5476ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5477ac_compiler_gnu=$ac_cv_c_compiler_gnu
5478
5479
5480
5481  ICC="no"
5482  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for icc" >&5
5483printf %s "checking for icc... " >&6; }
5484  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5485/* end confdefs.h.  */
5486__INTEL_COMPILER
5487_ACEOF
5488if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5489  $EGREP "^__INTEL_COMPILER" >/dev/null 2>&1
5490then :
5491  ICC="no"
5492    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5493printf "%s\n" "no" >&6; }
5494else $as_nop
5495  ICC="yes"
5496    GCC="no"
5497    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5498printf "%s\n" "yes" >&6; }
5499
5500fi
5501rm -rf conftest*
5502
5503
5504
5505  SUNCC="no"
5506  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suncc" >&5
5507printf %s "checking for suncc... " >&6; }
5508  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5509/* end confdefs.h.  */
5510__SUNPRO_C
5511_ACEOF
5512if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5513  $EGREP "^__SUNPRO_C" >/dev/null 2>&1
5514then :
5515  SUNCC="no"
5516    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5517printf "%s\n" "no" >&6; }
5518else $as_nop
5519  SUNCC="yes"
5520    GCC="no"
5521    test -n "$auto_cflags" && CFLAGS="-O -xs -xstrconst -zlazyload"
5522    GCC=""
5523    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5524printf "%s\n" "yes" >&6; }
5525
5526fi
5527rm -rf conftest*
5528
5529
5530
5531ac_ext=c
5532ac_cpp='$CPP $CPPFLAGS'
5533ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5534ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5535ac_compiler_gnu=$ac_cv_c_compiler_gnu
5536{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5537printf %s "checking how to run the C preprocessor... " >&6; }
5538# On Suns, sometimes $CPP names a directory.
5539if test -n "$CPP" && test -d "$CPP"; then
5540  CPP=
5541fi
5542if test -z "$CPP"; then
5543  if test ${ac_cv_prog_CPP+y}
5544then :
5545  printf %s "(cached) " >&6
5546else $as_nop
5547      # Double quotes because $CC needs to be expanded
5548    for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
5549    do
5550      ac_preproc_ok=false
5551for ac_c_preproc_warn_flag in '' yes
5552do
5553  # Use a header file that comes with gcc, so configuring glibc
5554  # with a fresh cross-compiler works.
5555  # On the NeXT, cc -E runs the code through the compiler's parser,
5556  # not just through cpp. "Syntax error" is here to catch this case.
5557  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5558/* end confdefs.h.  */
5559#include <limits.h>
5560		     Syntax error
5561_ACEOF
5562if ac_fn_c_try_cpp "$LINENO"
5563then :
5564
5565else $as_nop
5566  # Broken: fails on valid input.
5567continue
5568fi
5569rm -f conftest.err conftest.i conftest.$ac_ext
5570
5571  # OK, works on sane cases.  Now check whether nonexistent headers
5572  # can be detected and how.
5573  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5574/* end confdefs.h.  */
5575#include <ac_nonexistent.h>
5576_ACEOF
5577if ac_fn_c_try_cpp "$LINENO"
5578then :
5579  # Broken: success on invalid input.
5580continue
5581else $as_nop
5582  # Passes both tests.
5583ac_preproc_ok=:
5584break
5585fi
5586rm -f conftest.err conftest.i conftest.$ac_ext
5587
5588done
5589# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5590rm -f conftest.i conftest.err conftest.$ac_ext
5591if $ac_preproc_ok
5592then :
5593  break
5594fi
5595
5596    done
5597    ac_cv_prog_CPP=$CPP
5598
5599fi
5600  CPP=$ac_cv_prog_CPP
5601else
5602  ac_cv_prog_CPP=$CPP
5603fi
5604{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5605printf "%s\n" "$CPP" >&6; }
5606ac_preproc_ok=false
5607for ac_c_preproc_warn_flag in '' yes
5608do
5609  # Use a header file that comes with gcc, so configuring glibc
5610  # with a fresh cross-compiler works.
5611  # On the NeXT, cc -E runs the code through the compiler's parser,
5612  # not just through cpp. "Syntax error" is here to catch this case.
5613  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5614/* end confdefs.h.  */
5615#include <limits.h>
5616		     Syntax error
5617_ACEOF
5618if ac_fn_c_try_cpp "$LINENO"
5619then :
5620
5621else $as_nop
5622  # Broken: fails on valid input.
5623continue
5624fi
5625rm -f conftest.err conftest.i conftest.$ac_ext
5626
5627  # OK, works on sane cases.  Now check whether nonexistent headers
5628  # can be detected and how.
5629  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5630/* end confdefs.h.  */
5631#include <ac_nonexistent.h>
5632_ACEOF
5633if ac_fn_c_try_cpp "$LINENO"
5634then :
5635  # Broken: success on invalid input.
5636continue
5637else $as_nop
5638  # Passes both tests.
5639ac_preproc_ok=:
5640break
5641fi
5642rm -f conftest.err conftest.i conftest.$ac_ext
5643
5644done
5645# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5646rm -f conftest.i conftest.err conftest.$ac_ext
5647if $ac_preproc_ok
5648then :
5649
5650else $as_nop
5651  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5652printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5653as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5654See \`config.log' for more details" "$LINENO" 5; }
5655fi
5656
5657ac_ext=c
5658ac_cpp='$CPP $CPPFLAGS'
5659ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5660ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5661ac_compiler_gnu=$ac_cv_c_compiler_gnu
5662
5663ac_header= ac_cache=
5664for ac_item in $ac_header_c_list
5665do
5666  if test $ac_cache; then
5667    ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
5668    if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
5669      printf "%s\n" "#define $ac_item 1" >> confdefs.h
5670    fi
5671    ac_header= ac_cache=
5672  elif test $ac_header; then
5673    ac_cache=$ac_item
5674  else
5675    ac_header=$ac_item
5676  fi
5677done
5678
5679
5680
5681
5682
5683
5684
5685
5686if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
5687then :
5688
5689printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
5690
5691fi
5692
5693
5694
5695
5696
5697
5698  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5699printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5700if test ${ac_cv_safe_to_define___extensions__+y}
5701then :
5702  printf %s "(cached) " >&6
5703else $as_nop
5704  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5705/* end confdefs.h.  */
5706
5707#         define __EXTENSIONS__ 1
5708          $ac_includes_default
5709int
5710main (void)
5711{
5712
5713  ;
5714  return 0;
5715}
5716_ACEOF
5717if ac_fn_c_try_compile "$LINENO"
5718then :
5719  ac_cv_safe_to_define___extensions__=yes
5720else $as_nop
5721  ac_cv_safe_to_define___extensions__=no
5722fi
5723rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5724fi
5725{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5726printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; }
5727
5728  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
5729printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; }
5730if test ${ac_cv_should_define__xopen_source+y}
5731then :
5732  printf %s "(cached) " >&6
5733else $as_nop
5734  ac_cv_should_define__xopen_source=no
5735    if test $ac_cv_header_wchar_h = yes
5736then :
5737  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5738/* end confdefs.h.  */
5739
5740          #include <wchar.h>
5741          mbstate_t x;
5742int
5743main (void)
5744{
5745
5746  ;
5747  return 0;
5748}
5749_ACEOF
5750if ac_fn_c_try_compile "$LINENO"
5751then :
5752
5753else $as_nop
5754  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5755/* end confdefs.h.  */
5756
5757            #define _XOPEN_SOURCE 500
5758            #include <wchar.h>
5759            mbstate_t x;
5760int
5761main (void)
5762{
5763
5764  ;
5765  return 0;
5766}
5767_ACEOF
5768if ac_fn_c_try_compile "$LINENO"
5769then :
5770  ac_cv_should_define__xopen_source=yes
5771fi
5772rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5773fi
5774rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5775fi
5776fi
5777{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
5778printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; }
5779
5780  printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h
5781
5782  printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
5783
5784  printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
5785
5786  printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h
5787
5788  printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
5789
5790  printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h
5791
5792  printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5793
5794  printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
5795
5796  printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
5797
5798  printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
5799
5800  printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
5801
5802  printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
5803
5804  printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
5805
5806  printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
5807
5808  printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h
5809
5810  if test $ac_cv_header_minix_config_h = yes
5811then :
5812  MINIX=yes
5813    printf "%s\n" "#define _MINIX 1" >>confdefs.h
5814
5815    printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h
5816
5817    printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h
5818
5819else $as_nop
5820  MINIX=
5821fi
5822  if test $ac_cv_safe_to_define___extensions__ = yes
5823then :
5824  printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h
5825
5826fi
5827  if test $ac_cv_should_define__xopen_source = yes
5828then :
5829  printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h
5830
5831fi
5832
5833{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5834printf %s "checking whether ln -s works... " >&6; }
5835LN_S=$as_ln_s
5836if test "$LN_S" = "ln -s"; then
5837  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5838printf "%s\n" "yes" >&6; }
5839else
5840  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5841printf "%s\n" "no, using $LN_S" >&6; }
5842fi
5843
5844
5845if test "$cross_compiling" = yes ; then
5846  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for native build C compiler" >&5
5847printf %s "checking for native build C compiler... " >&6; }
5848  for ac_prog in gcc clang c99 c89 cc cl
5849do
5850  # Extract the first word of "$ac_prog", so it can be a program name with args.
5851set dummy $ac_prog; ac_word=$2
5852{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5853printf %s "checking for $ac_word... " >&6; }
5854if test ${ac_cv_prog_BUILD_CC+y}
5855then :
5856  printf %s "(cached) " >&6
5857else $as_nop
5858  if test -n "$BUILD_CC"; then
5859  ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
5860else
5861as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5862for as_dir in $PATH
5863do
5864  IFS=$as_save_IFS
5865  case $as_dir in #(((
5866    '') as_dir=./ ;;
5867    */) ;;
5868    *) as_dir=$as_dir/ ;;
5869  esac
5870    for ac_exec_ext in '' $ac_executable_extensions; do
5871  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5872    ac_cv_prog_BUILD_CC="$ac_prog"
5873    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5874    break 2
5875  fi
5876done
5877  done
5878IFS=$as_save_IFS
5879
5880fi
5881fi
5882BUILD_CC=$ac_cv_prog_BUILD_CC
5883if test -n "$BUILD_CC"; then
5884  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
5885printf "%s\n" "$BUILD_CC" >&6; }
5886else
5887  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5888printf "%s\n" "no" >&6; }
5889fi
5890
5891
5892  test -n "$BUILD_CC" && break
5893done
5894test -n "$BUILD_CC" || BUILD_CC="none"
5895
5896  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
5897printf "%s\n" "$BUILD_CC" >&6; }
5898else
5899  BUILD_CC=$CC
5900fi
5901
5902
5903php_with_libdir=lib
5904
5905{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for system library directory" >&5
5906printf %s "checking for system library directory... " >&6; }
5907
5908# Check whether --with-libdir was given.
5909if test ${with_libdir+y}
5910then :
5911  withval=$with_libdir; PHP_LIBDIR=$withval
5912else $as_nop
5913
5914  PHP_LIBDIR=lib
5915
5916
5917fi
5918
5919
5920ext_output=$PHP_LIBDIR
5921{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
5922printf "%s\n" "$ext_output" >&6; }
5923
5924
5925
5926
5927
5928php_enable_rpath=yes
5929
5930{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable runpaths" >&5
5931printf %s "checking whether to enable runpaths... " >&6; }
5932# Check whether --enable-rpath was given.
5933if test ${enable_rpath+y}
5934then :
5935  enableval=$enable_rpath; PHP_RPATH=$enableval
5936else $as_nop
5937
5938  PHP_RPATH=yes
5939
5940
5941fi
5942
5943
5944ext_output=$PHP_RPATH
5945{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
5946printf "%s\n" "$ext_output" >&6; }
5947
5948
5949
5950
5951
5952{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler supports -R" >&5
5953printf %s "checking if compiler supports -R... " >&6; }
5954if test ${php_cv_cc_dashr+y}
5955then :
5956  printf %s "(cached) " >&6
5957else $as_nop
5958
5959  SAVE_LIBS=$LIBS
5960  LIBS="-R /usr/$PHP_LIBDIR $LIBS"
5961  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5962/* end confdefs.h.  */
5963
5964int
5965main (void)
5966{
5967
5968  ;
5969  return 0;
5970}
5971_ACEOF
5972if ac_fn_c_try_link "$LINENO"
5973then :
5974  php_cv_cc_dashr=yes
5975else $as_nop
5976  php_cv_cc_dashr=no
5977fi
5978rm -f core conftest.err conftest.$ac_objext conftest.beam \
5979    conftest$ac_exeext conftest.$ac_ext
5980  LIBS=$SAVE_LIBS
5981fi
5982
5983{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_cc_dashr" >&5
5984printf "%s\n" "$php_cv_cc_dashr" >&6; }
5985if test $php_cv_cc_dashr = "yes"; then
5986  ld_runpath_switch=-R
5987else
5988  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler supports -Wl,-rpath," >&5
5989printf %s "checking if compiler supports -Wl,-rpath,... " >&6; }
5990  if test ${php_cv_cc_rpath+y}
5991then :
5992  printf %s "(cached) " >&6
5993else $as_nop
5994
5995    SAVE_LIBS=$LIBS
5996    LIBS="-Wl,-rpath,/usr/$PHP_LIBDIR $LIBS"
5997    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5998/* end confdefs.h.  */
5999
6000int
6001main (void)
6002{
6003
6004  ;
6005  return 0;
6006}
6007_ACEOF
6008if ac_fn_c_try_link "$LINENO"
6009then :
6010  php_cv_cc_rpath=yes
6011else $as_nop
6012  php_cv_cc_rpath=no
6013fi
6014rm -f core conftest.err conftest.$ac_objext conftest.beam \
6015    conftest$ac_exeext conftest.$ac_ext
6016    LIBS=$SAVE_LIBS
6017fi
6018
6019  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_cc_rpath" >&5
6020printf "%s\n" "$php_cv_cc_rpath" >&6; }
6021  if test $php_cv_cc_rpath = "yes"; then
6022    ld_runpath_switch=-Wl,-rpath,
6023  else
6024        ld_runpath_switch=-L
6025  fi
6026fi
6027if test "$PHP_RPATH" = "no"; then
6028  ld_runpath_switch=
6029fi
6030
6031
6032
6033  for ac_prog in gawk nawk awk mawk
6034do
6035  # Extract the first word of "$ac_prog", so it can be a program name with args.
6036set dummy $ac_prog; ac_word=$2
6037{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6038printf %s "checking for $ac_word... " >&6; }
6039if test ${ac_cv_prog_AWK+y}
6040then :
6041  printf %s "(cached) " >&6
6042else $as_nop
6043  if test -n "$AWK"; then
6044  ac_cv_prog_AWK="$AWK" # Let the user override the test.
6045else
6046as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6047as_dummy="/usr/xpg4/bin/:$PATH"
6048for as_dir in $as_dummy
6049do
6050  IFS=$as_save_IFS
6051  case $as_dir in #(((
6052    '') as_dir=./ ;;
6053    */) ;;
6054    *) as_dir=$as_dir/ ;;
6055  esac
6056    for ac_exec_ext in '' $ac_executable_extensions; do
6057  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6058    ac_cv_prog_AWK="$ac_prog"
6059    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6060    break 2
6061  fi
6062done
6063  done
6064IFS=$as_save_IFS
6065
6066fi
6067fi
6068AWK=$ac_cv_prog_AWK
6069if test -n "$AWK"; then
6070  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
6071printf "%s\n" "$AWK" >&6; }
6072else
6073  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6074printf "%s\n" "no" >&6; }
6075fi
6076
6077
6078  test -n "$AWK" && break
6079done
6080test -n "$AWK" || AWK="bork"
6081
6082  case "$AWK" in
6083    *mawk)
6084      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: mawk is known to have problems on some systems. You should install GNU awk" >&5
6085printf "%s\n" "$as_me: WARNING: mawk is known to have problems on some systems. You should install GNU awk" >&2;}
6086      ;;
6087    *gawk)
6088      ;;
6089    bork)
6090      as_fn_error $? "Could not find awk; Install GNU awk" "$LINENO" 5
6091      ;;
6092    *)
6093      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $AWK is broken" >&5
6094printf %s "checking if $AWK is broken... " >&6; }
6095      if ! $AWK 'function foo() {}' >/dev/null 2>&1 ; then
6096        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6097printf "%s\n" "yes" >&6; }
6098        as_fn_error $? "You should install GNU awk" "$LINENO" 5
6099      else
6100        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6101printf "%s\n" "no" >&6; }
6102      fi
6103      ;;
6104  esac
6105
6106  PHP_VAR_SUBST="$PHP_VAR_SUBST AWK"
6107
6108
6109
6110  # Extract the first word of "bison", so it can be a program name with args.
6111set dummy bison; ac_word=$2
6112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6113printf %s "checking for $ac_word... " >&6; }
6114if test ${ac_cv_prog_YACC+y}
6115then :
6116  printf %s "(cached) " >&6
6117else $as_nop
6118  if test -n "$YACC"; then
6119  ac_cv_prog_YACC="$YACC" # Let the user override the test.
6120else
6121as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6122for as_dir in $PATH
6123do
6124  IFS=$as_save_IFS
6125  case $as_dir in #(((
6126    '') as_dir=./ ;;
6127    */) ;;
6128    *) as_dir=$as_dir/ ;;
6129  esac
6130    for ac_exec_ext in '' $ac_executable_extensions; do
6131  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6132    ac_cv_prog_YACC="bison"
6133    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6134    break 2
6135  fi
6136done
6137  done
6138IFS=$as_save_IFS
6139
6140fi
6141fi
6142YACC=$ac_cv_prog_YACC
6143if test -n "$YACC"; then
6144  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6145printf "%s\n" "$YACC" >&6; }
6146else
6147  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6148printf "%s\n" "no" >&6; }
6149fi
6150
6151
6152
6153  php_bison_required_version="3.0.0"
6154  php_bison_excluded_versions='none'
6155
6156  if test -n "$YACC"; then
6157    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bison version" >&5
6158printf %s "checking for bison version... " >&6; }
6159
6160    php_bison_version=$($YACC --version 2> /dev/null | grep 'GNU Bison' | cut -d ' ' -f 4 | tr -d a-z)
6161    if test -z "$php_bison_version"; then
6162      php_bison_version=0.0.0
6163    fi
6164    ac_IFS=$IFS; IFS="."
6165    set $php_bison_version
6166    IFS=$ac_IFS
6167    php_bison_num=`expr ${1:-0} \* 10000 + ${2:-0} \* 100 + ${3:-0}`
6168    php_bison_branch="$1.$2"
6169    php_bison_check=ok
6170
6171    if test -z "$php_bison_required_version" && test -z "$php_bison_num"; then
6172      php_bison_check=invalid
6173    elif test -n "$php_bison_required_version"; then
6174      ac_IFS=$IFS; IFS="."
6175      set $php_bison_required_version
6176      IFS=$ac_IFS
6177      php_bison_required_num=`expr ${1:-0} \* 10000 + ${2:-0} \* 100 + ${3:-0}`
6178      php_bison_required_version="$php_bison_required_version or later"
6179
6180      if test -z "$php_bison_num" || test "$php_bison_num" -lt "$php_bison_required_num"; then
6181        php_bison_check=invalid
6182      fi
6183    fi
6184
6185    for php_bison_check_version in $php_bison_excluded_versions; do
6186      if test "$php_bison_version" = "$php_bison_check_version" || test "$php_bison_branch" = "$php_bison_check_version"; then
6187        php_bison_check=invalid
6188        break
6189      fi
6190    done
6191
6192    if test "$php_bison_check" != "invalid"; then
6193
6194  YFLAGS=-Wall
6195
6196
6197  PHP_VAR_SUBST="$PHP_VAR_SUBST YFLAGS"
6198
6199
6200      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_bison_version (ok)" >&5
6201printf "%s\n" "$php_bison_version (ok)" >&6; }
6202    else
6203      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_bison_version" >&5
6204printf "%s\n" "$php_bison_version" >&6; }
6205    fi
6206  fi
6207
6208  case $php_bison_check in
6209    ""|invalid)
6210      if test ! -f "$abs_srcdir/Zend/zend_language_parser.h" || test ! -f "$abs_srcdir/Zend/zend_language_parser.c"; then
6211        as_fn_error $? "bison $php_bison_required_version is required to generate PHP parsers (excluded versions: $php_bison_excluded_versions)." "$LINENO" 5
6212      fi
6213
6214      YACC="exit 0;"
6215      ;;
6216  esac
6217
6218
6219  PHP_VAR_SUBST="$PHP_VAR_SUBST YACC"
6220
6221
6222
6223  # Extract the first word of "re2c", so it can be a program name with args.
6224set dummy re2c; ac_word=$2
6225{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6226printf %s "checking for $ac_word... " >&6; }
6227if test ${ac_cv_prog_RE2C+y}
6228then :
6229  printf %s "(cached) " >&6
6230else $as_nop
6231  if test -n "$RE2C"; then
6232  ac_cv_prog_RE2C="$RE2C" # Let the user override the test.
6233else
6234as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6235for as_dir in $PATH
6236do
6237  IFS=$as_save_IFS
6238  case $as_dir in #(((
6239    '') as_dir=./ ;;
6240    */) ;;
6241    *) as_dir=$as_dir/ ;;
6242  esac
6243    for ac_exec_ext in '' $ac_executable_extensions; do
6244  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6245    ac_cv_prog_RE2C="re2c"
6246    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6247    break 2
6248  fi
6249done
6250  done
6251IFS=$as_save_IFS
6252
6253fi
6254fi
6255RE2C=$ac_cv_prog_RE2C
6256if test -n "$RE2C"; then
6257  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RE2C" >&5
6258printf "%s\n" "$RE2C" >&6; }
6259else
6260  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6261printf "%s\n" "no" >&6; }
6262fi
6263
6264
6265
6266  php_re2c_required_version="0.13.4"
6267
6268  if test -n "$RE2C"; then
6269    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for re2c version" >&5
6270printf %s "checking for re2c version... " >&6; }
6271
6272    php_re2c_version=$($RE2C --version | cut -d ' ' -f 2 2>/dev/null)
6273    if test -z "$php_re2c_version"; then
6274      php_re2c_version=0.0.0
6275    fi
6276    ac_IFS=$IFS; IFS="."
6277    set $php_re2c_version
6278    IFS=$ac_IFS
6279    php_re2c_num=`expr ${1:-0} \* 10000 + ${2:-0} \* 100 + ${3:-0}`
6280    php_re2c_check=ok
6281
6282    if test -z "$php_re2c_required_version" && test -z "$php_re2c_num"; then
6283      php_re2c_check=invalid
6284    elif test -n "$php_re2c_required_version"; then
6285      ac_IFS=$IFS; IFS="."
6286      set $php_re2c_required_version
6287      IFS=$ac_IFS
6288      php_re2c_required_num=`expr ${1:-0} \* 10000 + ${2:-0} \* 100 + ${3:-0}`
6289      php_re2c_required_version="$php_re2c_required_version or later"
6290
6291      if test -z "$php_re2c_num" || test "$php_re2c_num" -lt "$php_re2c_required_num"; then
6292        php_re2c_check=invalid
6293      fi
6294    fi
6295
6296    if test "$php_re2c_check" != "invalid"; then
6297      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_re2c_version (ok)" >&5
6298printf "%s\n" "$php_re2c_version (ok)" >&6; }
6299    else
6300      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_re2c_version" >&5
6301printf "%s\n" "$php_re2c_version" >&6; }
6302    fi
6303  fi
6304
6305  case $php_re2c_check in
6306    ""|invalid)
6307      if test ! -f "$abs_srcdir/Zend/zend_language_scanner.c"; then
6308        as_fn_error $? "re2c $php_re2c_required_version is required to generate PHP lexers." "$LINENO" 5
6309      fi
6310
6311      RE2C="exit 0;"
6312      ;;
6313  esac
6314
6315
6316  PHP_VAR_SUBST="$PHP_VAR_SUBST RE2C"
6317
6318
6319
6320  # Extract the first word of "php", so it can be a program name with args.
6321set dummy php; ac_word=$2
6322{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6323printf %s "checking for $ac_word... " >&6; }
6324if test ${ac_cv_prog_PHP+y}
6325then :
6326  printf %s "(cached) " >&6
6327else $as_nop
6328  if test -n "$PHP"; then
6329  ac_cv_prog_PHP="$PHP" # Let the user override the test.
6330else
6331as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6332for as_dir in $PATH
6333do
6334  IFS=$as_save_IFS
6335  case $as_dir in #(((
6336    '') as_dir=./ ;;
6337    */) ;;
6338    *) as_dir=$as_dir/ ;;
6339  esac
6340    for ac_exec_ext in '' $ac_executable_extensions; do
6341  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6342    ac_cv_prog_PHP="php"
6343    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6344    break 2
6345  fi
6346done
6347  done
6348IFS=$as_save_IFS
6349
6350fi
6351fi
6352PHP=$ac_cv_prog_PHP
6353if test -n "$PHP"; then
6354  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP" >&5
6355printf "%s\n" "$PHP" >&6; }
6356else
6357  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6358printf "%s\n" "no" >&6; }
6359fi
6360
6361
6362
6363  if test -n "$PHP"; then
6364    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for php version" >&5
6365printf %s "checking for php version... " >&6; }
6366    php_version=$($PHP -v | head -n1 | cut -d ' ' -f 2)
6367    if test -z "$php_version"; then
6368      php_version=0.0.0
6369    fi
6370    ac_IFS=$IFS; IFS="."
6371    set $php_version
6372    IFS=$ac_IFS
6373    php_version_num=`expr ${1:-0} \* 10000 + ${2:-0} \* 100 + ${3:-0}`
6374        if test "$php_version_num" -lt 70100; then
6375      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_version (too old)" >&5
6376printf "%s\n" "$php_version (too old)" >&6; }
6377      unset PHP
6378    else
6379      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_version (ok)" >&5
6380printf "%s\n" "$php_version (ok)" >&6; }
6381    fi
6382  fi
6383
6384  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP"
6385
6386
6387
6388
6389php_enable_re2c_cgoto=no
6390
6391{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable computed goto gcc extension with re2c" >&5
6392printf %s "checking whether to enable computed goto gcc extension with re2c... " >&6; }
6393# Check whether --enable-re2c-cgoto was given.
6394if test ${enable_re2c_cgoto+y}
6395then :
6396  enableval=$enable_re2c_cgoto; PHP_RE2C_CGOTO=$enableval
6397else $as_nop
6398
6399  PHP_RE2C_CGOTO=no
6400
6401
6402fi
6403
6404
6405ext_output=$PHP_RE2C_CGOTO
6406{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
6407printf "%s\n" "$ext_output" >&6; }
6408
6409
6410
6411
6412if test "$PHP_RE2C_CGOTO" = "no"; then
6413  RE2C_FLAGS=""
6414else
6415  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether re2c -g works" >&5
6416printf %s "checking whether re2c -g works... " >&6; }
6417  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6418/* end confdefs.h.  */
6419
6420int
6421main (void)
6422{
6423
6424int main(int argc, const char **argv)
6425{
6426  argc = argc;
6427  argv = argv;
6428label1:
6429label2:
6430  static void *adr[] = { &&label1, &&label2};
6431  goto *adr[0];
6432  return 0;
6433}
6434
6435  ;
6436  return 0;
6437}
6438_ACEOF
6439if ac_fn_c_try_compile "$LINENO"
6440then :
6441
6442    RE2C_FLAGS=""
6443    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6444printf "%s\n" "no" >&6; }
6445
6446else $as_nop
6447
6448    RE2C_FLAGS="-g"
6449    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6450printf "%s\n" "yes" >&6; }
6451
6452fi
6453rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6454fi
6455
6456  PHP_VAR_SUBST="$PHP_VAR_SUBST RE2C_FLAGS"
6457
6458
6459
6460case $host_cpu in
6461  alpha*)
6462    if test "$GCC" = "yes"; then
6463      CFLAGS="$CFLAGS -mieee"
6464    else
6465      CFLAGS="$CFLAGS -ieee"
6466    fi
6467    ;;
6468  sparc*)
6469    if test "$SUNCC" = "yes"; then
6470      CFLAGS="$CFLAGS -xmemalign=8s"
6471    fi
6472    ;;
6473esac
6474
6475{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fvisibility=hidden" >&5
6476printf %s "checking whether C compiler accepts -fvisibility=hidden... " >&6; }
6477if test ${ax_cv_check_cflags___fvisibility_hidden+y}
6478then :
6479  printf %s "(cached) " >&6
6480else $as_nop
6481
6482  ax_check_save_flags=$CFLAGS
6483  CFLAGS="$CFLAGS  -fvisibility=hidden"
6484  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6485/* end confdefs.h.  */
6486
6487int
6488main (void)
6489{
6490
6491  ;
6492  return 0;
6493}
6494_ACEOF
6495if ac_fn_c_try_compile "$LINENO"
6496then :
6497  ax_cv_check_cflags___fvisibility_hidden=yes
6498else $as_nop
6499  ax_cv_check_cflags___fvisibility_hidden=no
6500fi
6501rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6502  CFLAGS=$ax_check_save_flags
6503fi
6504{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fvisibility_hidden" >&5
6505printf "%s\n" "$ax_cv_check_cflags___fvisibility_hidden" >&6; }
6506if test "x$ax_cv_check_cflags___fvisibility_hidden" = xyes
6507then :
6508  CFLAGS="$CFLAGS -fvisibility=hidden"
6509else $as_nop
6510  :
6511fi
6512
6513
6514case $host_alias in
6515  *solaris*)
6516    CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS"
6517    ;;
6518  *dgux*)
6519    CPPFLAGS="$CPPFLAGS -D_BSD_TIMEOFDAY_FLAVOR"
6520    ;;
6521  *mips*)
6522    CPPFLAGS="$CPPFLAGS -D_XPG_IV"
6523    ;;
6524  *hpux*)
6525    if test "$GCC" = "yes"; then
6526      CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
6527    fi
6528    ;;
6529esac
6530
6531{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to force non-PIC code in shared modules" >&5
6532printf %s "checking whether to force non-PIC code in shared modules... " >&6; }
6533case $host_alias in
6534  i?86-*-linux*|i?86-*-freebsd*)
6535    if test "${with_pic+set}" != "set" || test "$with_pic" = "no"; then
6536      with_pic=no
6537      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6538printf "%s\n" "yes" >&6; }
6539    else
6540      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6541printf "%s\n" "no" >&6; }
6542    fi
6543    ;;
6544  *)
6545    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6546printf "%s\n" "no" >&6; }
6547    ;;
6548esac
6549
6550{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using musl libc" >&5
6551printf %s "checking whether we are using musl libc... " >&6; }
6552if command -v ldd >/dev/null && ldd --version 2>&1 | grep -q ^musl
6553then
6554  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6555printf "%s\n" "yes" >&6; }
6556  CPPFLAGS="$CPPFLAGS -D__MUSL__"
6557else
6558  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6559printf "%s\n" "no" >&6; }
6560fi
6561
6562
6563
6564
6565
6566
6567
6568
6569
6570
6571{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether /dev/urandom exists" >&5
6572printf %s "checking whether /dev/urandom exists... " >&6; }
6573if test -r "/dev/urandom" && test -c "/dev/urandom"; then
6574
6575printf "%s\n" "#define HAVE_DEV_URANDOM 1" >>confdefs.h
6576
6577  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6578printf "%s\n" "yes" >&6; }
6579else
6580  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6581printf "%s\n" "no" >&6; }
6582fi
6583
6584# Check whether --enable-gcc-global-regs was given.
6585if test ${enable_gcc_global_regs+y}
6586then :
6587  enableval=$enable_gcc_global_regs; ZEND_GCC_GLOBAL_REGS=$enableval
6588else $as_nop
6589  ZEND_GCC_GLOBAL_REGS=yes
6590fi
6591
6592
6593{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for global register variables support" >&5
6594printf %s "checking for global register variables support... " >&6; }
6595if test "$ZEND_GCC_GLOBAL_REGS" != "no"; then
6596  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6597/* end confdefs.h.  */
6598
6599#if defined(__GNUC__)
6600# define ZEND_GCC_VERSION (__GNUC__ * 1000 + __GNUC_MINOR__)
6601#else
6602# define ZEND_GCC_VERSION 0
6603#endif
6604#if defined(__GNUC__) && ZEND_GCC_VERSION >= 4008 && defined(i386)
6605# define ZEND_VM_FP_GLOBAL_REG "%esi"
6606# define ZEND_VM_IP_GLOBAL_REG "%edi"
6607#elif defined(__GNUC__) && ZEND_GCC_VERSION >= 4008 && defined(__x86_64__)
6608# define ZEND_VM_FP_GLOBAL_REG "%r14"
6609# define ZEND_VM_IP_GLOBAL_REG "%r15"
6610#elif defined(__GNUC__) && ZEND_GCC_VERSION >= 4008 && defined(__powerpc64__)
6611# define ZEND_VM_FP_GLOBAL_REG "r28"
6612# define ZEND_VM_IP_GLOBAL_REG "r29"
6613#elif defined(__IBMC__) && ZEND_GCC_VERSION >= 4002 && defined(__powerpc64__)
6614# define ZEND_VM_FP_GLOBAL_REG "r28"
6615# define ZEND_VM_IP_GLOBAL_REG "r29"
6616#elif defined(__GNUC__) && ZEND_GCC_VERSION >= 4008 && defined(__aarch64__)
6617# define ZEND_VM_FP_GLOBAL_REG "x27"
6618# define ZEND_VM_IP_GLOBAL_REG "x28"
6619#else
6620# error "global register variables are not supported"
6621#endif
6622typedef int (*opcode_handler_t)(void);
6623register void *FP  __asm__(ZEND_VM_FP_GLOBAL_REG);
6624register const opcode_handler_t *IP __asm__(ZEND_VM_IP_GLOBAL_REG);
6625int emu(const opcode_handler_t *ip, void *fp) {
6626	const opcode_handler_t *orig_ip = IP;
6627	void *orig_fp = FP;
6628	IP = ip;
6629	FP = fp;
6630	while ((*ip)());
6631	FP = orig_fp;
6632	IP = orig_ip;
6633}
6634
6635int
6636main (void)
6637{
6638
6639
6640  ;
6641  return 0;
6642}
6643_ACEOF
6644if ac_fn_c_try_compile "$LINENO"
6645then :
6646
6647    ZEND_GCC_GLOBAL_REGS=yes
6648
6649else $as_nop
6650
6651    ZEND_GCC_GLOBAL_REGS=no
6652
6653fi
6654rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
6655fi
6656if test "$ZEND_GCC_GLOBAL_REGS" = "yes"; then
6657
6658printf "%s\n" "#define HAVE_GCC_GLOBAL_REGS 1" >>confdefs.h
6659
6660else
6661  HAVE_GCC_GLOBAL_REGS=no
6662fi
6663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ZEND_GCC_GLOBAL_REGS" >&5
6664printf "%s\n" "$ZEND_GCC_GLOBAL_REGS" >&6; }
6665
6666{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether __cpuid_count is available" >&5
6667printf %s "checking whether __cpuid_count is available... " >&6; }
6668if test ${ac_cv_cpuid_count_available+y}
6669then :
6670  printf %s "(cached) " >&6
6671else $as_nop
6672
6673cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6674/* end confdefs.h.  */
6675
6676  #include <cpuid.h>
6677
6678int
6679main (void)
6680{
6681
6682  unsigned eax, ebx, ecx, edx;
6683  __cpuid_count(0, 0, eax, ebx, ecx, edx);
6684
6685  ;
6686  return 0;
6687}
6688_ACEOF
6689if ac_fn_c_try_link "$LINENO"
6690then :
6691
6692  ac_cv_cpuid_count_available=yes
6693
6694else $as_nop
6695
6696  ac_cv_cpuid_count_available=no
6697
6698fi
6699rm -f core conftest.err conftest.$ac_objext conftest.beam \
6700    conftest$ac_exeext conftest.$ac_ext
6701fi
6702{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cpuid_count_available" >&5
6703printf "%s\n" "$ac_cv_cpuid_count_available" >&6; }
6704if test "$ac_cv_cpuid_count_available" = "yes"; then
6705
6706printf "%s\n" "#define HAVE_CPUID_COUNT 1" >>confdefs.h
6707
6708fi
6709
6710
6711
6712
6713{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthreads_cflags" >&5
6714printf %s "checking for pthreads_cflags... " >&6; }
6715if test ${ac_cv_pthreads_cflags+y}
6716then :
6717  printf %s "(cached) " >&6
6718else $as_nop
6719
6720ac_cv_pthreads_cflags=
6721if test "$pthreads_working" != "yes"; then
6722  for flag in -kthread -pthread -pthreads -mthreads -Kthread -threads -mt -qthreaded; do
6723    ac_save=$CFLAGS
6724    CFLAGS="$CFLAGS $flag"
6725
6726cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6727/* end confdefs.h.  */
6728
6729#include <pthread.h>
6730#include <stddef.h>
6731
6732void *thread_routine(void *data) {
6733    return data;
6734}
6735
6736int main() {
6737    pthread_t thd;
6738    pthread_mutexattr_t mattr;
6739    int data = 1;
6740    pthread_mutexattr_init(&mattr);
6741    return pthread_create(&thd, NULL, thread_routine, &data);
6742}
6743_ACEOF
6744if ac_fn_c_try_link "$LINENO"
6745then :
6746
6747  pthreads_checked=yes
6748
6749else $as_nop
6750
6751  pthreads_checked=no
6752
6753
6754fi
6755rm -f core conftest.err conftest.$ac_objext conftest.beam \
6756    conftest$ac_exeext conftest.$ac_ext
6757    CFLAGS=$ac_save
6758    if test "$pthreads_checked" = "yes"; then
6759      ac_cv_pthreads_cflags=$flag
6760      break
6761    fi
6762  done
6763fi
6764
6765fi
6766{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthreads_cflags" >&5
6767printf "%s\n" "$ac_cv_pthreads_cflags" >&6; }
6768
6769{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthreads_lib" >&5
6770printf %s "checking for pthreads_lib... " >&6; }
6771if test ${ac_cv_pthreads_lib+y}
6772then :
6773  printf %s "(cached) " >&6
6774else $as_nop
6775
6776ac_cv_pthreads_lib=
6777if test "$pthreads_working" != "yes"; then
6778 for lib in pthread pthreads c_r; do
6779    ac_save=$LIBS
6780    LIBS="$LIBS -l$lib"
6781
6782cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6783/* end confdefs.h.  */
6784
6785#include <pthread.h>
6786#include <stddef.h>
6787
6788void *thread_routine(void *data) {
6789    return data;
6790}
6791
6792int main() {
6793    pthread_t thd;
6794    pthread_mutexattr_t mattr;
6795    int data = 1;
6796    pthread_mutexattr_init(&mattr);
6797    return pthread_create(&thd, NULL, thread_routine, &data);
6798}
6799_ACEOF
6800if ac_fn_c_try_link "$LINENO"
6801then :
6802
6803  pthreads_checked=yes
6804
6805else $as_nop
6806
6807  pthreads_checked=no
6808
6809
6810fi
6811rm -f core conftest.err conftest.$ac_objext conftest.beam \
6812    conftest$ac_exeext conftest.$ac_ext
6813    LIBS=$ac_save
6814    if test "$pthreads_checked" = "yes"; then
6815      ac_cv_pthreads_lib=$lib
6816      break
6817    fi
6818  done
6819fi
6820
6821fi
6822{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthreads_lib" >&5
6823printf "%s\n" "$ac_cv_pthreads_lib" >&6; }
6824
6825if test "x$ac_cv_pthreads_cflags" != "x" -o "x$ac_cv_pthreads_lib" != "x"; then
6826  pthreads_working="yes"
6827fi
6828
6829
6830# Check whether --enable- was given.
6831if test ${enable_+y}
6832then :
6833  enableval=$enable_;
6834fi
6835
6836
6837
6838
6839
6840
6841  PHP_VAR_SUBST="$PHP_VAR_SUBST SHLIB_SUFFIX_NAME"
6842
6843
6844
6845
6846
6847  PHP_VAR_SUBST="$PHP_VAR_SUBST SHLIB_DL_SUFFIX_NAME"
6848
6849
6850 SHLIB_SUFFIX_NAME=so
6851 SHLIB_DL_SUFFIX_NAME=$SHLIB_SUFFIX_NAME
6852 case $host_alias in
6853 *hpux*)
6854   SHLIB_SUFFIX_NAME=sl
6855   SHLIB_DL_SUFFIX_NAME=sl
6856   ;;
6857 *darwin*)
6858   SHLIB_SUFFIX_NAME=dylib
6859   SHLIB_DL_SUFFIX_NAME=so
6860   ;;
6861 esac
6862
6863
6864  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
6865  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
6866  php_c_post=
6867  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
6868  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
6869  php_cxx_post=
6870  php_lo=lo
6871
6872  case $with_pic in
6873    yes) pic_setting='-prefer-pic';;
6874    no)  pic_setting='-prefer-non-pic';;
6875  esac
6876
6877  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
6878  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
6879  shared_c_post=
6880  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
6881  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
6882  shared_cxx_post=
6883  shared_lo=lo
6884
6885PHP_SAPI=none
6886
6887
6888SAPI_SHARED=libs/libphp.$SHLIB_DL_SUFFIX_NAME
6889SAPI_STATIC=libs/libphp.a
6890SAPI_LIBTOOL=libphp.la
6891
6892
6893  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
6894printf "%s\n" "" >&6; }
6895  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring SAPI modules${T_ME}" >&5
6896printf "%s\n" "${T_MD}Configuring SAPI modules${T_ME}" >&6; }
6897
6898
6899
6900
6901
6902
6903
6904
6905
6906
6907php_with_apxs2=no
6908
6909
6910
6911# Check whether --with-apxs2 was given.
6912if test ${with_apxs2+y}
6913then :
6914  withval=$with_apxs2; PHP_APXS2=$withval
6915else $as_nop
6916
6917  PHP_APXS2=no
6918
6919
6920fi
6921
6922
6923ext_output=$PHP_APXS2
6924
6925
6926
6927
6928
6929{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Apache 2 handler module support via DSO through APXS" >&5
6930printf %s "checking for Apache 2 handler module support via DSO through APXS... " >&6; }
6931
6932if test "$PHP_APXS2" != "no"; then
6933  if test "$PHP_APXS2" = "yes"; then
6934    APXS=apxs
6935    $APXS -q CFLAGS >/dev/null 2>&1
6936    if test "$?" != "0" && test -x /usr/sbin/apxs; then
6937      APXS=/usr/sbin/apxs
6938    fi
6939  else
6940
6941  if test -z "$PHP_APXS2" || echo "$PHP_APXS2" | grep '^/' >/dev/null ; then
6942    APXS=$PHP_APXS2
6943  else
6944
6945    ep_dir=`echo $PHP_APXS2|$SED 's%/*[^/][^/]*/*$%%'`
6946
6947    ep_realdir=`(cd "$ep_dir" && pwd)`
6948    APXS="$ep_realdir"/`basename "$PHP_APXS2"`
6949  fi
6950
6951  fi
6952
6953  $APXS -q CFLAGS >/dev/null 2>&1
6954  if test "$?" != "0"; then
6955    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
6956printf "%s\n" "" >&6; }
6957    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
6958printf "%s\n" "" >&6; }
6959    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Sorry, I cannot run apxs.  Possible reasons follow:" >&5
6960printf "%s\n" "Sorry, I cannot run apxs.  Possible reasons follow:" >&6; }
6961    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
6962printf "%s\n" "" >&6; }
6963    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 1. Perl is not installed" >&5
6964printf "%s\n" "1. Perl is not installed" >&6; }
6965    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 2. apxs was not found. Try to pass the path using --with-apxs2=/path/to/apxs" >&5
6966printf "%s\n" "2. apxs was not found. Try to pass the path using --with-apxs2=/path/to/apxs" >&6; }
6967    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: 3. Apache was not built using --enable-so (the apxs usage page is displayed)" >&5
6968printf "%s\n" "3. Apache was not built using --enable-so (the apxs usage page is displayed)" >&6; }
6969    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
6970printf "%s\n" "" >&6; }
6971    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: The output of $APXS follows:" >&5
6972printf "%s\n" "The output of $APXS follows:" >&6; }
6973    $APXS -q CFLAGS
6974    as_fn_error $? "Aborting" "$LINENO" 5
6975  fi
6976
6977  APXS_INCLUDEDIR=`$APXS -q INCLUDEDIR`
6978  APXS_BINDIR=`$APXS -q BINDIR`
6979  APXS_HTTPD=`$APXS -q SBINDIR`/`$APXS -q TARGET`
6980  APXS_CFLAGS=`$APXS -q CFLAGS`
6981  APU_BINDIR=`$APXS -q APU_BINDIR`
6982  APR_BINDIR=`$APXS -q APR_BINDIR`
6983
6984    APR_CONFIG=`$APXS -q APR_CONFIG 2>/dev/null ||
6985    echo $APR_BINDIR/apr-config`
6986  APU_CONFIG=`$APXS -q APU_CONFIG 2>/dev/null ||
6987    echo $APU_BINDIR/apu-config`
6988
6989  APR_CFLAGS="`$APR_CONFIG --cppflags --includes`"
6990  APU_CFLAGS="`$APU_CONFIG --includes`"
6991
6992  for flag in $APXS_CFLAGS; do
6993    case $flag in
6994    -D*) APACHE_CPPFLAGS="$APACHE_CPPFLAGS $flag";;
6995    esac
6996  done
6997
6998  APACHE_CFLAGS="$APACHE_CPPFLAGS -I$APXS_INCLUDEDIR $APR_CFLAGS $APU_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
6999
7000
7001  ac_output=`$APXS_HTTPD -v 2>&1 | grep version | $SED -e 's/Oracle-HTTP-//'`
7002  ac_IFS=$IFS
7003IFS="- /.
7004"
7005  set $ac_output
7006  IFS=$ac_IFS
7007
7008  APACHE_VERSION=`expr $4 \* 1000000 + $5 \* 1000 + $6`
7009
7010  if test "$APACHE_VERSION" -lt 2000044; then
7011    as_fn_error $? "Please note that Apache version >= 2.0.44 is required" "$LINENO" 5
7012  fi
7013
7014  APXS_LIBEXECDIR='$(INSTALL_ROOT)'`$APXS -q LIBEXECDIR`
7015  if test -z `$APXS -q SYSCONFDIR`; then
7016    INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
7017                 $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
7018                       -i -n php"
7019  else
7020    APXS_SYSCONFDIR='$(INSTALL_ROOT)'`$APXS -q SYSCONFDIR`
7021    INSTALL_IT="\$(mkinstalldirs) '$APXS_LIBEXECDIR' && \
7022                \$(mkinstalldirs) '$APXS_SYSCONFDIR' && \
7023                 $APXS -S LIBEXECDIR='$APXS_LIBEXECDIR' \
7024                       -S SYSCONFDIR='$APXS_SYSCONFDIR' \
7025                       -i -a -n php"
7026  fi
7027
7028  LIBPHP_CFLAGS="-shared"
7029
7030  PHP_VAR_SUBST="$PHP_VAR_SUBST LIBPHP_CFLAGS"
7031
7032
7033  case $host_alias in
7034  *aix*)
7035    EXTRA_LDFLAGS="$EXTRA_LDFLAGS -Wl,-brtl -Wl,-bI:$APXS_LIBEXECDIR/httpd.exp"
7036
7037  if test "shared" = "program"; then
7038    PHP_BINARIES="$PHP_BINARIES apache2handler"
7039  elif test "$PHP_SAPI" != "none"; then
7040    as_fn_error $? "
7041+--------------------------------------------------------------------+
7042|                        *** ATTENTION ***                           |
7043|                                                                    |
7044| You've configured multiple SAPIs to be built. You can build only   |
7045| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
7046+--------------------------------------------------------------------+
7047" "$LINENO" 5
7048  else
7049    PHP_SAPI=apache2handler
7050  fi
7051
7052
7053
7054    BUILD_DIR="$BUILD_DIR sapi/apache2handler"
7055
7056
7057
7058  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS apache2handler"
7059
7060
7061    case "shared" in
7062    static)
7063
7064  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7065  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7066  php_c_post=
7067  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7068  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7069  php_cxx_post=
7070  php_lo=lo
7071
7072  case $with_pic in
7073    yes) pic_setting='-prefer-pic';;
7074    no)  pic_setting='-prefer-non-pic';;
7075  esac
7076
7077  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7078  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7079  shared_c_post=
7080  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7081  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7082  shared_cxx_post=
7083  shared_lo=lo
7084
7085  OVERALL_TARGET=libphp.la
7086  php_sapi_module=static
7087;;
7088    shared)
7089
7090  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7091  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7092  php_c_post=
7093  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7094  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7095  php_cxx_post=
7096  php_lo=lo
7097
7098  case $with_pic in
7099    yes) pic_setting='-prefer-pic';;
7100    no)  pic_setting='-prefer-non-pic';;
7101  esac
7102
7103  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7104  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7105  shared_c_post=
7106  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7107  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7108  shared_cxx_post=
7109  shared_lo=lo
7110
7111  OVERALL_TARGET=libphp.la
7112  php_sapi_module=shared
7113
7114  php_c_pre=$shared_c_pre
7115  php_c_meta=$shared_c_meta
7116  php_c_post=$shared_c_post
7117  php_cxx_pre=$shared_cxx_pre
7118  php_cxx_meta=$shared_cxx_meta
7119  php_cxx_post=$shared_cxx_post
7120  php_lo=$shared_lo
7121;;
7122    bundle)
7123
7124  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7125  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7126  php_c_post=
7127  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7128  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7129  php_cxx_post=
7130  php_lo=lo
7131
7132  case $with_pic in
7133    yes) pic_setting='-prefer-pic';;
7134    no)  pic_setting='-prefer-non-pic';;
7135  esac
7136
7137  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7138  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7139  shared_c_post=
7140  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7141  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7142  shared_cxx_post=
7143  shared_lo=lo
7144
7145  OVERALL_TARGET=libs/libphp.bundle
7146  php_sapi_module=static
7147;;
7148    esac
7149    install_sapi="install-sapi"
7150
7151
7152  case sapi/apache2handler in
7153  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
7154  /*) ac_srcdir=`echo "sapi/apache2handler"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
7155  *) ac_srcdir="$abs_srcdir/sapi/apache2handler/"; ac_bdir="sapi/apache2handler/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
7156  esac
7157
7158
7159
7160  b_c_pre=$php_c_pre
7161  b_cxx_pre=$php_cxx_pre
7162  b_c_meta=$php_c_meta
7163  b_cxx_meta=$php_cxx_meta
7164  b_c_post=$php_c_post
7165  b_cxx_post=$php_cxx_post
7166  b_lo=$php_lo
7167
7168
7169  old_IFS=$IFS
7170  for ac_src in mod_php.c sapi_apache2.c apache_config.c php_functions.c; do
7171
7172      IFS=.
7173      set $ac_src
7174      ac_obj=$1
7175      IFS=$old_IFS
7176
7177      PHP_SAPI_OBJS="$PHP_SAPI_OBJS $ac_bdir$ac_obj.lo"
7178
7179      case $ac_src in
7180        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7181        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7182        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7183        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
7184      esac
7185
7186      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
7187
7188    cat >>Makefile.objects<<EOF
7189-include $ac_bdir$ac_obj.dep
7190$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
7191	$ac_comp
7192EOF
7193  done
7194
7195
7196
7197
7198    INSTALL_IT="$INSTALL_IT $SAPI_LIBTOOL"
7199    ;;
7200  *darwin*)
7201                if test -x "$APR_CONFIG"; then
7202        MH_BUNDLE_FLAGS="`$APR_CONFIG --ldflags --link-ld --libs`"
7203    fi
7204    if test -x "$APU_CONFIG"; then
7205        MH_BUNDLE_FLAGS="`$APU_CONFIG --ldflags --link-ld --libs` $MH_BUNDLE_FLAGS"
7206    fi
7207    MH_BUNDLE_FLAGS="-bundle -bundle_loader $APXS_HTTPD $MH_BUNDLE_FLAGS"
7208
7209  PHP_VAR_SUBST="$PHP_VAR_SUBST MH_BUNDLE_FLAGS"
7210
7211
7212  if test "bundle" = "program"; then
7213    PHP_BINARIES="$PHP_BINARIES apache2handler"
7214  elif test "$PHP_SAPI" != "none"; then
7215    as_fn_error $? "
7216+--------------------------------------------------------------------+
7217|                        *** ATTENTION ***                           |
7218|                                                                    |
7219| You've configured multiple SAPIs to be built. You can build only   |
7220| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
7221+--------------------------------------------------------------------+
7222" "$LINENO" 5
7223  else
7224    PHP_SAPI=apache2handler
7225  fi
7226
7227
7228
7229    BUILD_DIR="$BUILD_DIR sapi/apache2handler"
7230
7231
7232
7233  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS apache2handler"
7234
7235
7236    case "bundle" in
7237    static)
7238
7239  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7240  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7241  php_c_post=
7242  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7243  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7244  php_cxx_post=
7245  php_lo=lo
7246
7247  case $with_pic in
7248    yes) pic_setting='-prefer-pic';;
7249    no)  pic_setting='-prefer-non-pic';;
7250  esac
7251
7252  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7253  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7254  shared_c_post=
7255  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7256  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7257  shared_cxx_post=
7258  shared_lo=lo
7259
7260  OVERALL_TARGET=libphp.la
7261  php_sapi_module=static
7262;;
7263    shared)
7264
7265  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7266  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7267  php_c_post=
7268  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7269  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7270  php_cxx_post=
7271  php_lo=lo
7272
7273  case $with_pic in
7274    yes) pic_setting='-prefer-pic';;
7275    no)  pic_setting='-prefer-non-pic';;
7276  esac
7277
7278  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7279  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7280  shared_c_post=
7281  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7282  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7283  shared_cxx_post=
7284  shared_lo=lo
7285
7286  OVERALL_TARGET=libphp.la
7287  php_sapi_module=shared
7288
7289  php_c_pre=$shared_c_pre
7290  php_c_meta=$shared_c_meta
7291  php_c_post=$shared_c_post
7292  php_cxx_pre=$shared_cxx_pre
7293  php_cxx_meta=$shared_cxx_meta
7294  php_cxx_post=$shared_cxx_post
7295  php_lo=$shared_lo
7296;;
7297    bundle)
7298
7299  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7300  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7301  php_c_post=
7302  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7303  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7304  php_cxx_post=
7305  php_lo=lo
7306
7307  case $with_pic in
7308    yes) pic_setting='-prefer-pic';;
7309    no)  pic_setting='-prefer-non-pic';;
7310  esac
7311
7312  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7313  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7314  shared_c_post=
7315  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7316  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7317  shared_cxx_post=
7318  shared_lo=lo
7319
7320  OVERALL_TARGET=libs/libphp.bundle
7321  php_sapi_module=static
7322;;
7323    esac
7324    install_sapi="install-sapi"
7325
7326
7327  case sapi/apache2handler in
7328  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
7329  /*) ac_srcdir=`echo "sapi/apache2handler"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
7330  *) ac_srcdir="$abs_srcdir/sapi/apache2handler/"; ac_bdir="sapi/apache2handler/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
7331  esac
7332
7333
7334
7335  b_c_pre=$php_c_pre
7336  b_cxx_pre=$php_cxx_pre
7337  b_c_meta=$php_c_meta
7338  b_cxx_meta=$php_cxx_meta
7339  b_c_post=$php_c_post
7340  b_cxx_post=$php_cxx_post
7341  b_lo=$php_lo
7342
7343
7344  old_IFS=$IFS
7345  for ac_src in mod_php.c sapi_apache2.c apache_config.c php_functions.c; do
7346
7347      IFS=.
7348      set $ac_src
7349      ac_obj=$1
7350      IFS=$old_IFS
7351
7352      PHP_SAPI_OBJS="$PHP_SAPI_OBJS $ac_bdir$ac_obj.lo"
7353
7354      case $ac_src in
7355        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7356        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7357        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7358        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
7359      esac
7360
7361      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
7362
7363    cat >>Makefile.objects<<EOF
7364-include $ac_bdir$ac_obj.dep
7365$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
7366	$ac_comp
7367EOF
7368  done
7369
7370
7371
7372
7373    SAPI_SHARED=libs/libphp.so
7374    INSTALL_IT="$INSTALL_IT $SAPI_SHARED"
7375    ;;
7376  *)
7377
7378  if test "shared" = "program"; then
7379    PHP_BINARIES="$PHP_BINARIES apache2handler"
7380  elif test "$PHP_SAPI" != "none"; then
7381    as_fn_error $? "
7382+--------------------------------------------------------------------+
7383|                        *** ATTENTION ***                           |
7384|                                                                    |
7385| You've configured multiple SAPIs to be built. You can build only   |
7386| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
7387+--------------------------------------------------------------------+
7388" "$LINENO" 5
7389  else
7390    PHP_SAPI=apache2handler
7391  fi
7392
7393
7394
7395    BUILD_DIR="$BUILD_DIR sapi/apache2handler"
7396
7397
7398
7399  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS apache2handler"
7400
7401
7402    case "shared" in
7403    static)
7404
7405  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7406  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7407  php_c_post=
7408  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7409  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7410  php_cxx_post=
7411  php_lo=lo
7412
7413  case $with_pic in
7414    yes) pic_setting='-prefer-pic';;
7415    no)  pic_setting='-prefer-non-pic';;
7416  esac
7417
7418  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7419  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7420  shared_c_post=
7421  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7422  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7423  shared_cxx_post=
7424  shared_lo=lo
7425
7426  OVERALL_TARGET=libphp.la
7427  php_sapi_module=static
7428;;
7429    shared)
7430
7431  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7432  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7433  php_c_post=
7434  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7435  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7436  php_cxx_post=
7437  php_lo=lo
7438
7439  case $with_pic in
7440    yes) pic_setting='-prefer-pic';;
7441    no)  pic_setting='-prefer-non-pic';;
7442  esac
7443
7444  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7445  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7446  shared_c_post=
7447  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7448  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7449  shared_cxx_post=
7450  shared_lo=lo
7451
7452  OVERALL_TARGET=libphp.la
7453  php_sapi_module=shared
7454
7455  php_c_pre=$shared_c_pre
7456  php_c_meta=$shared_c_meta
7457  php_c_post=$shared_c_post
7458  php_cxx_pre=$shared_cxx_pre
7459  php_cxx_meta=$shared_cxx_meta
7460  php_cxx_post=$shared_cxx_post
7461  php_lo=$shared_lo
7462;;
7463    bundle)
7464
7465  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7466  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7467  php_c_post=
7468  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7469  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7470  php_cxx_post=
7471  php_lo=lo
7472
7473  case $with_pic in
7474    yes) pic_setting='-prefer-pic';;
7475    no)  pic_setting='-prefer-non-pic';;
7476  esac
7477
7478  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7479  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7480  shared_c_post=
7481  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7482  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7483  shared_cxx_post=
7484  shared_lo=lo
7485
7486  OVERALL_TARGET=libs/libphp.bundle
7487  php_sapi_module=static
7488;;
7489    esac
7490    install_sapi="install-sapi"
7491
7492
7493  case sapi/apache2handler in
7494  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
7495  /*) ac_srcdir=`echo "sapi/apache2handler"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
7496  *) ac_srcdir="$abs_srcdir/sapi/apache2handler/"; ac_bdir="sapi/apache2handler/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
7497  esac
7498
7499
7500
7501  b_c_pre=$php_c_pre
7502  b_cxx_pre=$php_cxx_pre
7503  b_c_meta=$php_c_meta
7504  b_cxx_meta=$php_cxx_meta
7505  b_c_post=$php_c_post
7506  b_cxx_post=$php_cxx_post
7507  b_lo=$php_lo
7508
7509
7510  old_IFS=$IFS
7511  for ac_src in mod_php.c sapi_apache2.c apache_config.c php_functions.c; do
7512
7513      IFS=.
7514      set $ac_src
7515      ac_obj=$1
7516      IFS=$old_IFS
7517
7518      PHP_SAPI_OBJS="$PHP_SAPI_OBJS $ac_bdir$ac_obj.lo"
7519
7520      case $ac_src in
7521        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7522        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7523        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7524        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $APACHE_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
7525      esac
7526
7527      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
7528
7529    cat >>Makefile.objects<<EOF
7530-include $ac_bdir$ac_obj.dep
7531$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
7532	$ac_comp
7533EOF
7534  done
7535
7536
7537
7538
7539    INSTALL_IT="$INSTALL_IT $SAPI_LIBTOOL"
7540    ;;
7541  esac
7542
7543  if test "$APACHE_VERSION" -lt 2004001; then
7544    APXS_MPM=`$APXS -q MPM_NAME`
7545    if test "$APXS_MPM" != "prefork" && test "$APXS_MPM" != "peruser" && test "$APXS_MPM" != "itk"; then
7546
7547  enable_zts=yes
7548  if test "$pthreads_working" != "yes"; then
7549    as_fn_error $? "ZTS currently requires working POSIX threads. We were unable to verify that your system supports Pthreads." "$LINENO" 5
7550  fi
7551
7552    fi
7553  else
7554    APACHE_THREADED_MPM=`$APXS_HTTPD -V 2>/dev/null | grep 'threaded:.*yes'`
7555    if test -n "$APACHE_THREADED_MPM"; then
7556
7557  enable_zts=yes
7558  if test "$pthreads_working" != "yes"; then
7559    as_fn_error $? "ZTS currently requires working POSIX threads. We were unable to verify that your system supports Pthreads." "$LINENO" 5
7560  fi
7561
7562    fi
7563  fi
7564  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7565printf "%s\n" "yes" >&6; }
7566
7567  PHP_VAR_SUBST="$PHP_VAR_SUBST APXS"
7568
7569else
7570  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7571printf "%s\n" "no" >&6; }
7572fi
7573
7574
7575
7576
7577
7578php_enable_cli=yes
7579
7580
7581# Check whether --enable-cli was given.
7582if test ${enable_cli+y}
7583then :
7584  enableval=$enable_cli; PHP_CLI=$enableval
7585else $as_nop
7586
7587  PHP_CLI=yes
7588
7589
7590fi
7591
7592
7593ext_output=$PHP_CLI
7594
7595
7596
7597
7598
7599ac_fn_c_check_func "$LINENO" "setproctitle" "ac_cv_func_setproctitle"
7600if test "x$ac_cv_func_setproctitle" = xyes
7601then :
7602  printf "%s\n" "#define HAVE_SETPROCTITLE 1" >>confdefs.h
7603
7604fi
7605
7606
7607ac_fn_c_check_header_compile "$LINENO" "sys/pstat.h" "ac_cv_header_sys_pstat_h" "$ac_includes_default"
7608if test "x$ac_cv_header_sys_pstat_h" = xyes
7609then :
7610  printf "%s\n" "#define HAVE_SYS_PSTAT_H 1" >>confdefs.h
7611
7612fi
7613
7614
7615{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PS_STRINGS" >&5
7616printf %s "checking for PS_STRINGS... " >&6; }
7617if test ${cli_cv_var_PS_STRINGS+y}
7618then :
7619  printf %s "(cached) " >&6
7620else $as_nop
7621  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7622/* end confdefs.h.  */
7623#include <machine/vmparam.h>
7624#include <sys/exec.h>
7625
7626int
7627main (void)
7628{
7629PS_STRINGS->ps_nargvstr = 1;
7630PS_STRINGS->ps_argvstr = "foo";
7631  ;
7632  return 0;
7633}
7634_ACEOF
7635if ac_fn_c_try_link "$LINENO"
7636then :
7637  cli_cv_var_PS_STRINGS=yes
7638else $as_nop
7639  cli_cv_var_PS_STRINGS=no
7640fi
7641rm -f core conftest.err conftest.$ac_objext conftest.beam \
7642    conftest$ac_exeext conftest.$ac_ext
7643fi
7644{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cli_cv_var_PS_STRINGS" >&5
7645printf "%s\n" "$cli_cv_var_PS_STRINGS" >&6; }
7646if test "$cli_cv_var_PS_STRINGS" = yes ; then
7647
7648printf "%s\n" "#define HAVE_PS_STRINGS /**/" >>confdefs.h
7649
7650fi
7651
7652{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CLI build" >&5
7653printf %s "checking for CLI build... " >&6; }
7654if test "$PHP_CLI" != "no"; then
7655
7656  src=$abs_srcdir/sapi/cli/Makefile.frag
7657  ac_srcdir=$ext_srcdir
7658  ac_builddir=$ext_builddir
7659  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
7660
7661
7662    SAPI_CLI_PATH=sapi/cli/php
7663
7664
7665  if test "program" = "program"; then
7666    PHP_BINARIES="$PHP_BINARIES cli"
7667  elif test "$PHP_SAPI" != "none"; then
7668    as_fn_error $? "
7669+--------------------------------------------------------------------+
7670|                        *** ATTENTION ***                           |
7671|                                                                    |
7672| You've configured multiple SAPIs to be built. You can build only   |
7673| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
7674+--------------------------------------------------------------------+
7675" "$LINENO" 5
7676  else
7677    PHP_SAPI=cli
7678  fi
7679
7680
7681
7682    BUILD_DIR="$BUILD_DIR sapi/cli"
7683
7684
7685
7686  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS cli"
7687
7688
7689
7690  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7691  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7692  php_c_post=
7693  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7694  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7695  php_cxx_post=
7696  php_lo=lo
7697
7698  case $with_pic in
7699    yes) pic_setting='-prefer-pic';;
7700    no)  pic_setting='-prefer-non-pic';;
7701  esac
7702
7703  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7704  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7705  shared_c_post=
7706  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7707  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7708  shared_cxx_post=
7709  shared_lo=lo
7710
7711    install_binaries="install-binaries"
7712    install_binary_targets="$install_binary_targets install-cli"
7713
7714  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_CLI_OBJS"
7715
7716
7717  case sapi/cli in
7718  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
7719  /*) ac_srcdir=`echo "sapi/cli"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
7720  *) ac_srcdir="$abs_srcdir/sapi/cli/"; ac_bdir="sapi/cli/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
7721  esac
7722
7723
7724
7725  b_c_pre=$php_c_pre
7726  b_cxx_pre=$php_cxx_pre
7727  b_c_meta=$php_c_meta
7728  b_cxx_meta=$php_cxx_meta
7729  b_c_post=$php_c_post
7730  b_cxx_post=$php_cxx_post
7731  b_lo=$php_lo
7732
7733
7734  old_IFS=$IFS
7735  for ac_src in php_cli.c php_http_parser.c php_cli_server.c ps_title.c php_cli_process_title.c; do
7736
7737      IFS=.
7738      set $ac_src
7739      ac_obj=$1
7740      IFS=$old_IFS
7741
7742      PHP_CLI_OBJS="$PHP_CLI_OBJS $ac_bdir$ac_obj.lo"
7743
7744      case $ac_src in
7745        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7746        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7747        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
7748        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
7749      esac
7750
7751      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
7752
7753    cat >>Makefile.objects<<EOF
7754-include $ac_bdir$ac_obj.dep
7755$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
7756	$ac_comp
7757EOF
7758  done
7759
7760
7761
7762
7763  case $host_alias in
7764  *aix*)
7765    if test "$php_sapi_module" = "shared"; then
7766      BUILD_CLI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CLI_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/.libs\/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
7767    else
7768      BUILD_CLI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CLI_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CLI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
7769    fi
7770    ;;
7771  *darwin*)
7772    BUILD_CLI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
7773    ;;
7774  *)
7775    BUILD_CLI="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_CLI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CLI_PATH)"
7776    ;;
7777  esac
7778
7779    PHP_EXECUTABLE="\$(top_builddir)/\$(SAPI_CLI_PATH)"
7780
7781  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_EXECUTABLE"
7782
7783
7784
7785  PHP_VAR_SUBST="$PHP_VAR_SUBST SAPI_CLI_PATH"
7786
7787
7788  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_CLI"
7789
7790
7791
7792  PHP_OUTPUT_FILES="$PHP_OUTPUT_FILES sapi/cli/php.1"
7793
7794
7795
7796
7797    for header_file in sapi/cli/cli.h; do
7798
7799
7800  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
7801
7802  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
7803  if test -n "$unique" && test "`eval $cmd`" = "" ; then
7804    eval "INSTALLHEADERS$unique=set"
7805
7806        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
7807
7808  fi
7809
7810    done
7811
7812
7813fi
7814{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_CLI" >&5
7815printf "%s\n" "$PHP_CLI" >&6; }
7816
7817
7818
7819
7820
7821php_enable_embed=no
7822
7823
7824# Check whether --enable-embed was given.
7825if test ${enable_embed+y}
7826then :
7827  enableval=$enable_embed; PHP_EMBED=$enableval
7828else $as_nop
7829
7830  PHP_EMBED=no
7831
7832
7833fi
7834
7835
7836ext_output=$PHP_EMBED
7837
7838
7839
7840
7841
7842{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for embedded SAPI library support" >&5
7843printf %s "checking for embedded SAPI library support... " >&6; }
7844
7845if test "$PHP_EMBED" != "no"; then
7846  case "$PHP_EMBED" in
7847    yes|shared)
7848      LIBPHP_CFLAGS="-shared"
7849      PHP_EMBED_TYPE=shared
7850      INSTALL_IT="\$(mkinstalldirs) \$(INSTALL_ROOT)\$(prefix)/lib; \$(INSTALL) -m 0755 $SAPI_SHARED \$(INSTALL_ROOT)\$(prefix)/lib"
7851      ;;
7852    static)
7853      LIBPHP_CFLAGS="-static"
7854      PHP_EMBED_TYPE=static
7855      INSTALL_IT="\$(mkinstalldirs) \$(INSTALL_ROOT)\$(prefix)/lib; \$(INSTALL) -m 0644 $SAPI_STATIC \$(INSTALL_ROOT)\$(prefix)/lib"
7856      ;;
7857    *)
7858      PHP_EMBED_TYPE=no
7859      ;;
7860  esac
7861  if test "$PHP_EMBED_TYPE" != "no"; then
7862
7863  PHP_VAR_SUBST="$PHP_VAR_SUBST LIBPHP_CFLAGS"
7864
7865
7866  if test "$PHP_EMBED_TYPE" = "program"; then
7867    PHP_BINARIES="$PHP_BINARIES embed"
7868  elif test "$PHP_SAPI" != "none"; then
7869    as_fn_error $? "
7870+--------------------------------------------------------------------+
7871|                        *** ATTENTION ***                           |
7872|                                                                    |
7873| You've configured multiple SAPIs to be built. You can build only   |
7874| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
7875+--------------------------------------------------------------------+
7876" "$LINENO" 5
7877  else
7878    PHP_SAPI=embed
7879  fi
7880
7881
7882
7883    BUILD_DIR="$BUILD_DIR sapi/embed"
7884
7885
7886
7887  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS embed"
7888
7889
7890    case "$PHP_EMBED_TYPE" in
7891    static)
7892
7893  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7894  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7895  php_c_post=
7896  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7897  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7898  php_cxx_post=
7899  php_lo=lo
7900
7901  case $with_pic in
7902    yes) pic_setting='-prefer-pic';;
7903    no)  pic_setting='-prefer-non-pic';;
7904  esac
7905
7906  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7907  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7908  shared_c_post=
7909  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7910  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7911  shared_cxx_post=
7912  shared_lo=lo
7913
7914  OVERALL_TARGET=libphp.la
7915  php_sapi_module=static
7916;;
7917    shared)
7918
7919  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7920  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7921  php_c_post=
7922  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7923  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7924  php_cxx_post=
7925  php_lo=lo
7926
7927  case $with_pic in
7928    yes) pic_setting='-prefer-pic';;
7929    no)  pic_setting='-prefer-non-pic';;
7930  esac
7931
7932  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7933  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7934  shared_c_post=
7935  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7936  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7937  shared_cxx_post=
7938  shared_lo=lo
7939
7940  OVERALL_TARGET=libphp.la
7941  php_sapi_module=shared
7942
7943  php_c_pre=$shared_c_pre
7944  php_c_meta=$shared_c_meta
7945  php_c_post=$shared_c_post
7946  php_cxx_pre=$shared_cxx_pre
7947  php_cxx_meta=$shared_cxx_meta
7948  php_cxx_post=$shared_cxx_post
7949  php_lo=$shared_lo
7950;;
7951    bundle)
7952
7953  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7954  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
7955  php_c_post=
7956  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7957  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
7958  php_cxx_post=
7959  php_lo=lo
7960
7961  case $with_pic in
7962    yes) pic_setting='-prefer-pic';;
7963    no)  pic_setting='-prefer-non-pic';;
7964  esac
7965
7966  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
7967  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
7968  shared_c_post=
7969  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
7970  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
7971  shared_cxx_post=
7972  shared_lo=lo
7973
7974  OVERALL_TARGET=libs/libphp.bundle
7975  php_sapi_module=static
7976;;
7977    esac
7978    install_sapi="install-sapi"
7979
7980
7981  case sapi/embed in
7982  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
7983  /*) ac_srcdir=`echo "sapi/embed"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
7984  *) ac_srcdir="$abs_srcdir/sapi/embed/"; ac_bdir="sapi/embed/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
7985  esac
7986
7987
7988
7989  b_c_pre=$php_c_pre
7990  b_cxx_pre=$php_cxx_pre
7991  b_c_meta=$php_c_meta
7992  b_cxx_meta=$php_cxx_meta
7993  b_c_post=$php_c_post
7994  b_cxx_post=$php_cxx_post
7995  b_lo=$php_lo
7996
7997
7998  old_IFS=$IFS
7999  for ac_src in php_embed.c; do
8000
8001      IFS=.
8002      set $ac_src
8003      ac_obj=$1
8004      IFS=$old_IFS
8005
8006      PHP_SAPI_OBJS="$PHP_SAPI_OBJS $ac_bdir$ac_obj.lo"
8007
8008      case $ac_src in
8009        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
8010        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
8011        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
8012        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
8013      esac
8014
8015      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
8016
8017    cat >>Makefile.objects<<EOF
8018-include $ac_bdir$ac_obj.dep
8019$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
8020	$ac_comp
8021EOF
8022  done
8023
8024
8025
8026
8027
8028
8029    for header_file in sapi/embed/php_embed.h; do
8030
8031
8032  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
8033
8034  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
8035  if test -n "$unique" && test "`eval $cmd`" = "" ; then
8036    eval "INSTALLHEADERS$unique=set"
8037
8038        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
8039
8040  fi
8041
8042    done
8043
8044
8045  fi
8046  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_EMBED_TYPE" >&5
8047printf "%s\n" "$PHP_EMBED_TYPE" >&6; }
8048else
8049  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8050printf "%s\n" "no" >&6; }
8051fi
8052
8053
8054
8055
8056
8057php_enable_fpm=no
8058
8059
8060# Check whether --enable-fpm was given.
8061if test ${enable_fpm+y}
8062then :
8063  enableval=$enable_fpm; PHP_FPM=$enableval
8064else $as_nop
8065
8066  PHP_FPM=no
8067
8068
8069fi
8070
8071
8072ext_output=$PHP_FPM
8073
8074
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085
8086
8087
8088
8089
8090
8091
8092
8093
8094
8095
8096
8097
8098
8099
8100
8101
8102
8103
8104{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FPM build" >&5
8105printf %s "checking for FPM build... " >&6; }
8106if test "$PHP_FPM" != "no"; then
8107  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_FPM" >&5
8108printf "%s\n" "$PHP_FPM" >&6; }
8109
8110
8111  ac_fn_c_check_func "$LINENO" "clearenv" "ac_cv_func_clearenv"
8112if test "x$ac_cv_func_clearenv" = xyes
8113then :
8114  printf "%s\n" "#define HAVE_CLEARENV 1" >>confdefs.h
8115
8116fi
8117ac_fn_c_check_func "$LINENO" "setproctitle" "ac_cv_func_setproctitle"
8118if test "x$ac_cv_func_setproctitle" = xyes
8119then :
8120  printf "%s\n" "#define HAVE_SETPROCTITLE 1" >>confdefs.h
8121
8122fi
8123ac_fn_c_check_func "$LINENO" "setproctitle_fast" "ac_cv_func_setproctitle_fast"
8124if test "x$ac_cv_func_setproctitle_fast" = xyes
8125then :
8126  printf "%s\n" "#define HAVE_SETPROCTITLE_FAST 1" >>confdefs.h
8127
8128fi
8129
8130
8131  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
8132printf %s "checking for library containing socket... " >&6; }
8133if test ${ac_cv_search_socket+y}
8134then :
8135  printf %s "(cached) " >&6
8136else $as_nop
8137  ac_func_search_save_LIBS=$LIBS
8138cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8139/* end confdefs.h.  */
8140
8141/* Override any GCC internal prototype to avoid an error.
8142   Use char because int might match the return type of a GCC
8143   builtin and then its argument prototype would still apply.  */
8144char socket ();
8145int
8146main (void)
8147{
8148return socket ();
8149  ;
8150  return 0;
8151}
8152_ACEOF
8153for ac_lib in '' socket
8154do
8155  if test -z "$ac_lib"; then
8156    ac_res="none required"
8157  else
8158    ac_res=-l$ac_lib
8159    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8160  fi
8161  if ac_fn_c_try_link "$LINENO"
8162then :
8163  ac_cv_search_socket=$ac_res
8164fi
8165rm -f core conftest.err conftest.$ac_objext conftest.beam \
8166    conftest$ac_exeext
8167  if test ${ac_cv_search_socket+y}
8168then :
8169  break
8170fi
8171done
8172if test ${ac_cv_search_socket+y}
8173then :
8174
8175else $as_nop
8176  ac_cv_search_socket=no
8177fi
8178rm conftest.$ac_ext
8179LIBS=$ac_func_search_save_LIBS
8180fi
8181{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
8182printf "%s\n" "$ac_cv_search_socket" >&6; }
8183ac_res=$ac_cv_search_socket
8184if test "$ac_res" != no
8185then :
8186  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8187
8188fi
8189
8190  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing inet_addr" >&5
8191printf %s "checking for library containing inet_addr... " >&6; }
8192if test ${ac_cv_search_inet_addr+y}
8193then :
8194  printf %s "(cached) " >&6
8195else $as_nop
8196  ac_func_search_save_LIBS=$LIBS
8197cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8198/* end confdefs.h.  */
8199
8200/* Override any GCC internal prototype to avoid an error.
8201   Use char because int might match the return type of a GCC
8202   builtin and then its argument prototype would still apply.  */
8203char inet_addr ();
8204int
8205main (void)
8206{
8207return inet_addr ();
8208  ;
8209  return 0;
8210}
8211_ACEOF
8212for ac_lib in '' nsl
8213do
8214  if test -z "$ac_lib"; then
8215    ac_res="none required"
8216  else
8217    ac_res=-l$ac_lib
8218    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8219  fi
8220  if ac_fn_c_try_link "$LINENO"
8221then :
8222  ac_cv_search_inet_addr=$ac_res
8223fi
8224rm -f core conftest.err conftest.$ac_objext conftest.beam \
8225    conftest$ac_exeext
8226  if test ${ac_cv_search_inet_addr+y}
8227then :
8228  break
8229fi
8230done
8231if test ${ac_cv_search_inet_addr+y}
8232then :
8233
8234else $as_nop
8235  ac_cv_search_inet_addr=no
8236fi
8237rm conftest.$ac_ext
8238LIBS=$ac_func_search_save_LIBS
8239fi
8240{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_addr" >&5
8241printf "%s\n" "$ac_cv_search_inet_addr" >&6; }
8242ac_res=$ac_cv_search_inet_addr
8243if test "$ac_res" != no
8244then :
8245  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8246
8247fi
8248
8249
8250
8251  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for prctl" >&5
8252printf %s "checking for prctl... " >&6; }
8253
8254  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8255/* end confdefs.h.  */
8256#include <sys/prctl.h>
8257int
8258main (void)
8259{
8260prctl(0, 0, 0, 0, 0);
8261  ;
8262  return 0;
8263}
8264_ACEOF
8265if ac_fn_c_try_compile "$LINENO"
8266then :
8267
8268
8269printf "%s\n" "#define HAVE_PRCTL 1" >>confdefs.h
8270
8271    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8272printf "%s\n" "yes" >&6; }
8273
8274else $as_nop
8275
8276    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8277printf "%s\n" "no" >&6; }
8278
8279fi
8280rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8281
8282
8283  have_clock_gettime=no
8284
8285  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_gettime" >&5
8286printf %s "checking for clock_gettime... " >&6; }
8287
8288  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8289/* end confdefs.h.  */
8290#include <time.h>
8291int
8292main (void)
8293{
8294struct timespec ts; clock_gettime(CLOCK_MONOTONIC, &ts);
8295  ;
8296  return 0;
8297}
8298_ACEOF
8299if ac_fn_c_try_link "$LINENO"
8300then :
8301
8302    have_clock_gettime=yes
8303    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8304printf "%s\n" "yes" >&6; }
8305
8306else $as_nop
8307
8308    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8309printf "%s\n" "no" >&6; }
8310
8311fi
8312rm -f core conftest.err conftest.$ac_objext conftest.beam \
8313    conftest$ac_exeext conftest.$ac_ext
8314
8315  if test "$have_clock_gettime" = "no"; then
8316    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5
8317printf %s "checking for clock_gettime in -lrt... " >&6; }
8318
8319    SAVED_LIBS="$LIBS"
8320    LIBS="$LIBS -lrt"
8321
8322    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8323/* end confdefs.h.  */
8324#include <time.h>
8325int
8326main (void)
8327{
8328struct timespec ts; clock_gettime(CLOCK_MONOTONIC, &ts);
8329  ;
8330  return 0;
8331}
8332_ACEOF
8333if ac_fn_c_try_link "$LINENO"
8334then :
8335
8336      have_clock_gettime=yes
8337      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8338printf "%s\n" "yes" >&6; }
8339
8340else $as_nop
8341
8342      LIBS="$SAVED_LIBS"
8343      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8344printf "%s\n" "no" >&6; }
8345
8346fi
8347rm -f core conftest.err conftest.$ac_objext conftest.beam \
8348    conftest$ac_exeext conftest.$ac_ext
8349  fi
8350
8351  if test "$have_clock_gettime" = "yes"; then
8352
8353printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
8354
8355  fi
8356
8357  have_clock_get_time=no
8358
8359  if test "$have_clock_gettime" = "no"; then
8360    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_get_time" >&5
8361printf %s "checking for clock_get_time... " >&6; }
8362
8363    if test "$cross_compiling" = yes
8364then :
8365  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no (cross-compiling)" >&5
8366printf "%s\n" "no (cross-compiling)" >&6; }
8367else $as_nop
8368  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8369/* end confdefs.h.  */
8370#include <mach/mach.h>
8371      #include <mach/clock.h>
8372      #include <mach/mach_error.h>
8373
8374      int main()
8375      {
8376        kern_return_t ret; clock_serv_t aClock; mach_timespec_t aTime;
8377        ret = host_get_clock_service(mach_host_self(), REALTIME_CLOCK, &aClock);
8378
8379        if (ret != KERN_SUCCESS) {
8380          return 1;
8381        }
8382
8383        ret = clock_get_time(aClock, &aTime);
8384        if (ret != KERN_SUCCESS) {
8385          return 2;
8386        }
8387
8388        return 0;
8389      }
8390
8391_ACEOF
8392if ac_fn_c_try_run "$LINENO"
8393then :
8394
8395      have_clock_get_time=yes
8396      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8397printf "%s\n" "yes" >&6; }
8398
8399else $as_nop
8400
8401      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8402printf "%s\n" "no" >&6; }
8403
8404fi
8405rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8406  conftest.$ac_objext conftest.beam conftest.$ac_ext
8407fi
8408
8409  fi
8410
8411  if test "$have_clock_get_time" = "yes"; then
8412
8413printf "%s\n" "#define HAVE_CLOCK_GET_TIME 1" >>confdefs.h
8414
8415  fi
8416
8417
8418  have_ptrace=no
8419  have_broken_ptrace=no
8420
8421  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ptrace" >&5
8422printf %s "checking for ptrace... " >&6; }
8423
8424  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8425/* end confdefs.h.  */
8426
8427    #include <sys/types.h>
8428    #include <sys/ptrace.h>
8429int
8430main (void)
8431{
8432ptrace(0, 0, (void *) 0, 0);
8433  ;
8434  return 0;
8435}
8436_ACEOF
8437if ac_fn_c_try_compile "$LINENO"
8438then :
8439
8440    have_ptrace=yes
8441    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8442printf "%s\n" "yes" >&6; }
8443
8444else $as_nop
8445
8446    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8447printf "%s\n" "no" >&6; }
8448
8449fi
8450rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8451
8452  if test "$have_ptrace" = "yes"; then
8453    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ptrace works" >&5
8454printf %s "checking whether ptrace works... " >&6; }
8455
8456    if test "$cross_compiling" = yes
8457then :
8458
8459      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: skipped (cross-compiling)" >&5
8460printf "%s\n" "skipped (cross-compiling)" >&6; }
8461
8462else $as_nop
8463  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8464/* end confdefs.h.  */
8465
8466      #include <unistd.h>
8467      #include <signal.h>
8468      #include <sys/wait.h>
8469      #include <sys/types.h>
8470      #include <sys/ptrace.h>
8471      #include <errno.h>
8472
8473      #if !defined(PTRACE_ATTACH) && defined(PT_ATTACH)
8474      #define PTRACE_ATTACH PT_ATTACH
8475      #endif
8476
8477      #if !defined(PTRACE_DETACH) && defined(PT_DETACH)
8478      #define PTRACE_DETACH PT_DETACH
8479      #endif
8480
8481      #if !defined(PTRACE_PEEKDATA) && defined(PT_READ_D)
8482      #define PTRACE_PEEKDATA PT_READ_D
8483      #endif
8484
8485      int main()
8486      {
8487        long v1 = (unsigned int) -1; /* copy will fail if sizeof(long) == 8 and we've got "int ptrace()" */
8488        long v2;
8489        pid_t child;
8490        int status;
8491
8492        if ( (child = fork()) ) { /* parent */
8493          int ret = 0;
8494
8495          if (0 > ptrace(PTRACE_ATTACH, child, 0, 0)) {
8496            return 2;
8497          }
8498
8499          waitpid(child, &status, 0);
8500
8501      #ifdef PT_IO
8502          struct ptrace_io_desc ptio = {
8503            .piod_op = PIOD_READ_D,
8504            .piod_offs = &v1,
8505            .piod_addr = &v2,
8506            .piod_len = sizeof(v1)
8507          };
8508
8509          if (0 > ptrace(PT_IO, child, (void *) &ptio, 0)) {
8510            ret = 3;
8511          }
8512      #else
8513          errno = 0;
8514
8515          v2 = ptrace(PTRACE_PEEKDATA, child, (void *) &v1, 0);
8516
8517          if (errno) {
8518            ret = 4;
8519          }
8520      #endif
8521          ptrace(PTRACE_DETACH, child, (void *) 1, 0);
8522
8523          kill(child, SIGKILL);
8524
8525          return ret ? ret : (v1 != v2);
8526        }
8527        else { /* child */
8528          sleep(10);
8529          return 0;
8530        }
8531      }
8532
8533_ACEOF
8534if ac_fn_c_try_run "$LINENO"
8535then :
8536
8537      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8538printf "%s\n" "yes" >&6; }
8539
8540else $as_nop
8541
8542      have_ptrace=no
8543      have_broken_ptrace=yes
8544      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8545printf "%s\n" "no" >&6; }
8546
8547fi
8548rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8549  conftest.$ac_objext conftest.beam conftest.$ac_ext
8550fi
8551
8552  fi
8553
8554  if test "$have_ptrace" = "yes"; then
8555
8556printf "%s\n" "#define HAVE_PTRACE 1" >>confdefs.h
8557
8558  fi
8559
8560  have_mach_vm_read=no
8561
8562  if test "$have_broken_ptrace" = "yes"; then
8563    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mach_vm_read" >&5
8564printf %s "checking for mach_vm_read... " >&6; }
8565
8566    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8567/* end confdefs.h.  */
8568#include <mach/mach.h>
8569      #include <mach/mach_vm.h>
8570
8571int
8572main (void)
8573{
8574
8575      mach_vm_read((vm_map_t)0, (mach_vm_address_t)0, (mach_vm_size_t)0, (vm_offset_t *)0, (mach_msg_type_number_t*)0);
8576
8577  ;
8578  return 0;
8579}
8580_ACEOF
8581if ac_fn_c_try_compile "$LINENO"
8582then :
8583
8584      have_mach_vm_read=yes
8585      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8586printf "%s\n" "yes" >&6; }
8587
8588else $as_nop
8589
8590      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8591printf "%s\n" "no" >&6; }
8592
8593fi
8594rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8595  fi
8596
8597  if test "$have_mach_vm_read" = "yes"; then
8598
8599printf "%s\n" "#define HAVE_MACH_VM_READ 1" >>confdefs.h
8600
8601  fi
8602
8603  proc_mem_file=""
8604
8605  if test -r /proc/$$/mem ; then
8606    proc_mem_file="mem"
8607  else
8608    if test -r /proc/$$/as ; then
8609      proc_mem_file="as"
8610    fi
8611  fi
8612
8613  if test -n "$proc_mem_file" ; then
8614    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for proc mem file" >&5
8615printf %s "checking for proc mem file... " >&6; }
8616
8617    if test "$cross_compiling" = yes
8618then :
8619
8620      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: skipped (cross-compiling)" >&5
8621printf "%s\n" "skipped (cross-compiling)" >&6; }
8622
8623else $as_nop
8624  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8625/* end confdefs.h.  */
8626
8627      #define _GNU_SOURCE
8628      #define _FILE_OFFSET_BITS 64
8629      #include <stdint.h>
8630      #include <unistd.h>
8631      #include <sys/types.h>
8632      #include <sys/stat.h>
8633      #include <fcntl.h>
8634      #include <stdio.h>
8635      int main()
8636      {
8637        long v1 = (unsigned int) -1, v2 = 0;
8638        char buf[128];
8639        int fd;
8640        sprintf(buf, "/proc/%d/$proc_mem_file", getpid());
8641        fd = open(buf, O_RDONLY);
8642        if (0 > fd) {
8643          return 1;
8644        }
8645        if (sizeof(long) != pread(fd, &v2, sizeof(long), (uintptr_t) &v1)) {
8646          close(fd);
8647          return 1;
8648        }
8649        close(fd);
8650        return v1 != v2;
8651      }
8652
8653_ACEOF
8654if ac_fn_c_try_run "$LINENO"
8655then :
8656
8657      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $proc_mem_file" >&5
8658printf "%s\n" "$proc_mem_file" >&6; }
8659
8660else $as_nop
8661
8662      proc_mem_file=""
8663      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8664printf "%s\n" "no" >&6; }
8665
8666fi
8667rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8668  conftest.$ac_objext conftest.beam conftest.$ac_ext
8669fi
8670
8671  fi
8672
8673  if test -n "$proc_mem_file"; then
8674
8675printf "%s\n" "#define PROC_MEM_FILE \"$proc_mem_file\"" >>confdefs.h
8676
8677  fi
8678
8679  fpm_trace_type=""
8680
8681  if test "$have_ptrace" = "yes"; then
8682    fpm_trace_type=ptrace
8683
8684  elif test -n "$proc_mem_file"; then
8685    fpm_trace_type=pread
8686
8687  elif test "$have_mach_vm_read" = "yes" ; then
8688    fpm_trace_type=mach
8689
8690  else
8691    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: FPM Trace - ptrace, pread, or mach: could not be found" >&5
8692printf "%s\n" "$as_me: WARNING: FPM Trace - ptrace, pread, or mach: could not be found" >&2;}
8693  fi
8694
8695
8696
8697  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if gcc supports __sync_bool_compare_and_swap" >&5
8698printf %s "checking if gcc supports __sync_bool_compare_and_swap... " >&6; }
8699  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8700/* end confdefs.h.  */
8701
8702int
8703main (void)
8704{
8705
8706    int variable = 1;
8707    return (__sync_bool_compare_and_swap(&variable, 1, 2)
8708           && __sync_add_and_fetch(&variable, 1)) ? 1 : 0;
8709
8710  ;
8711  return 0;
8712}
8713_ACEOF
8714if ac_fn_c_try_link "$LINENO"
8715then :
8716
8717    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8718printf "%s\n" "yes" >&6; }
8719
8720printf "%s\n" "#define HAVE_BUILTIN_ATOMIC 1" >>confdefs.h
8721
8722
8723else $as_nop
8724
8725    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8726printf "%s\n" "no" >&6; }
8727
8728fi
8729rm -f core conftest.err conftest.$ac_objext conftest.beam \
8730    conftest$ac_exeext conftest.$ac_ext
8731
8732
8733  have_lq=no
8734
8735  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for TCP_INFO" >&5
8736printf %s "checking for TCP_INFO... " >&6; }
8737
8738  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8739/* end confdefs.h.  */
8740#include <netinet/tcp.h>
8741int
8742main (void)
8743{
8744struct tcp_info ti; int x = TCP_INFO;
8745  ;
8746  return 0;
8747}
8748_ACEOF
8749if ac_fn_c_try_compile "$LINENO"
8750then :
8751
8752    have_lq=tcp_info
8753    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8754printf "%s\n" "yes" >&6; }
8755
8756else $as_nop
8757
8758    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8759printf "%s\n" "no" >&6; }
8760
8761fi
8762rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8763
8764  if test "$have_lq" = "tcp_info"; then
8765
8766printf "%s\n" "#define HAVE_LQ_TCP_INFO 1" >>confdefs.h
8767
8768  fi
8769
8770  if test "$have_lq" = "no" ; then
8771    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SO_LISTENQLEN" >&5
8772printf %s "checking for SO_LISTENQLEN... " >&6; }
8773
8774    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8775/* end confdefs.h.  */
8776#include <sys/socket.h>
8777int
8778main (void)
8779{
8780int x = SO_LISTENQLIMIT; int y = SO_LISTENQLEN;
8781  ;
8782  return 0;
8783}
8784_ACEOF
8785if ac_fn_c_try_compile "$LINENO"
8786then :
8787
8788      have_lq=so_listenq
8789      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8790printf "%s\n" "yes" >&6; }
8791
8792else $as_nop
8793
8794      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8795printf "%s\n" "no" >&6; }
8796
8797fi
8798rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8799
8800    if test "$have_lq" = "tcp_info"; then
8801
8802printf "%s\n" "#define HAVE_LQ_SO_LISTENQ 1" >>confdefs.h
8803
8804    fi
8805  fi
8806
8807
8808	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysconf" >&5
8809printf %s "checking for sysconf... " >&6; }
8810
8811	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8812/* end confdefs.h.  */
8813#include <unistd.h>
8814int
8815main (void)
8816{
8817sysconf(_SC_CLK_TCK);
8818  ;
8819  return 0;
8820}
8821_ACEOF
8822if ac_fn_c_try_compile "$LINENO"
8823then :
8824
8825
8826printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h
8827
8828		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8829printf "%s\n" "yes" >&6; }
8830
8831else $as_nop
8832
8833		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8834printf "%s\n" "no" >&6; }
8835
8836fi
8837rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8838
8839
8840	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for times" >&5
8841printf %s "checking for times... " >&6; }
8842
8843	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8844/* end confdefs.h.  */
8845#include <sys/times.h>
8846int
8847main (void)
8848{
8849struct tms t; times(&t);
8850  ;
8851  return 0;
8852}
8853_ACEOF
8854if ac_fn_c_try_compile "$LINENO"
8855then :
8856
8857
8858printf "%s\n" "#define HAVE_TIMES 1" >>confdefs.h
8859
8860		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8861printf "%s\n" "yes" >&6; }
8862
8863else $as_nop
8864
8865		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8866printf "%s\n" "no" >&6; }
8867
8868fi
8869rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8870
8871
8872	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for kqueue" >&5
8873printf %s "checking for kqueue... " >&6; }
8874
8875	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8876/* end confdefs.h.  */
8877
8878		#include <sys/types.h>
8879		#include <sys/event.h>
8880		#include <sys/time.h>
8881
8882int
8883main (void)
8884{
8885
8886		int kfd;
8887		struct kevent k;
8888		kfd = kqueue();
8889		/* 0 -> STDIN_FILENO */
8890		EV_SET(&k, 0, EVFILT_READ , EV_ADD | EV_CLEAR, 0, 0, NULL);
8891
8892  ;
8893  return 0;
8894}
8895_ACEOF
8896if ac_fn_c_try_compile "$LINENO"
8897then :
8898
8899
8900printf "%s\n" "#define HAVE_KQUEUE 1" >>confdefs.h
8901
8902		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8903printf "%s\n" "yes" >&6; }
8904
8905else $as_nop
8906
8907		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8908printf "%s\n" "no" >&6; }
8909
8910fi
8911rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8912
8913
8914	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for port framework" >&5
8915printf %s "checking for port framework... " >&6; }
8916
8917	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8918/* end confdefs.h.  */
8919
8920		#include <port.h>
8921
8922int
8923main (void)
8924{
8925
8926		int port;
8927
8928		port = port_create();
8929		if (port < 0) {
8930			return 1;
8931		}
8932
8933  ;
8934  return 0;
8935}
8936_ACEOF
8937if ac_fn_c_try_compile "$LINENO"
8938then :
8939
8940
8941printf "%s\n" "#define HAVE_PORT 1" >>confdefs.h
8942
8943		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8944printf "%s\n" "yes" >&6; }
8945
8946else $as_nop
8947
8948		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8949printf "%s\n" "no" >&6; }
8950
8951fi
8952rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8953
8954
8955	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /dev/poll" >&5
8956printf %s "checking for /dev/poll... " >&6; }
8957
8958	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8959/* end confdefs.h.  */
8960
8961		#include <stdio.h>
8962		#include <sys/devpoll.h>
8963
8964int
8965main (void)
8966{
8967
8968		int n, dp;
8969		struct dvpoll dvp;
8970		dp = 0;
8971		dvp.dp_fds = NULL;
8972		dvp.dp_nfds = 0;
8973		dvp.dp_timeout = 0;
8974		n = ioctl(dp, DP_POLL, &dvp)
8975
8976  ;
8977  return 0;
8978}
8979_ACEOF
8980if ac_fn_c_try_compile "$LINENO"
8981then :
8982
8983
8984printf "%s\n" "#define HAVE_DEVPOLL 1" >>confdefs.h
8985
8986		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8987printf "%s\n" "yes" >&6; }
8988
8989else $as_nop
8990
8991		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8992printf "%s\n" "no" >&6; }
8993
8994fi
8995rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8996
8997
8998	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for epoll" >&5
8999printf %s "checking for epoll... " >&6; }
9000
9001	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9002/* end confdefs.h.  */
9003
9004		#include <sys/epoll.h>
9005
9006int
9007main (void)
9008{
9009
9010		int epollfd;
9011		struct epoll_event e;
9012
9013		epollfd = epoll_create(1);
9014		if (epollfd < 0) {
9015			return 1;
9016		}
9017
9018		e.events = EPOLLIN | EPOLLET;
9019		e.data.fd = 0;
9020
9021		if (epoll_ctl(epollfd, EPOLL_CTL_ADD, 0, &e) == -1) {
9022			return 1;
9023		}
9024
9025		e.events = 0;
9026		if (epoll_wait(epollfd, &e, 1, 1) < 0) {
9027			return 1;
9028		}
9029
9030  ;
9031  return 0;
9032}
9033_ACEOF
9034if ac_fn_c_try_compile "$LINENO"
9035then :
9036
9037
9038printf "%s\n" "#define HAVE_EPOLL 1" >>confdefs.h
9039
9040		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9041printf "%s\n" "yes" >&6; }
9042
9043else $as_nop
9044
9045		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9046printf "%s\n" "no" >&6; }
9047
9048fi
9049rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9050
9051
9052	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for select" >&5
9053printf %s "checking for select... " >&6; }
9054
9055	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9056/* end confdefs.h.  */
9057
9058		/* According to POSIX.1-2001 */
9059		#include <sys/select.h>
9060
9061		/* According to earlier standards */
9062		#include <sys/time.h>
9063		#include <sys/types.h>
9064		#include <unistd.h>
9065
9066int
9067main (void)
9068{
9069
9070		fd_set fds;
9071		struct timeval t;
9072		t.tv_sec = 0;
9073		t.tv_usec = 42;
9074		FD_ZERO(&fds);
9075		/* 0 -> STDIN_FILENO */
9076		FD_SET(0, &fds);
9077		select(FD_SETSIZE, &fds, NULL, NULL, &t);
9078
9079  ;
9080  return 0;
9081}
9082_ACEOF
9083if ac_fn_c_try_compile "$LINENO"
9084then :
9085
9086
9087printf "%s\n" "#define HAVE_SELECT 1" >>confdefs.h
9088
9089		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9090printf "%s\n" "yes" >&6; }
9091
9092else $as_nop
9093
9094		{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9095printf "%s\n" "no" >&6; }
9096
9097fi
9098rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
9099
9100
9101
9102php_with_fpm_user=nobody
9103
9104
9105
9106# Check whether --with-fpm-user was given.
9107if test ${with_fpm_user+y}
9108then :
9109  withval=$with_fpm_user; PHP_FPM_USER=$withval
9110else $as_nop
9111
9112  PHP_FPM_USER=nobody
9113
9114
9115fi
9116
9117
9118ext_output=$PHP_FPM_USER
9119
9120
9121
9122
9123
9124
9125php_with_fpm_group=nobody
9126
9127
9128
9129# Check whether --with-fpm-group was given.
9130if test ${with_fpm_group+y}
9131then :
9132  withval=$with_fpm_group; PHP_FPM_GROUP=$withval
9133else $as_nop
9134
9135  PHP_FPM_GROUP=nobody
9136
9137
9138fi
9139
9140
9141ext_output=$PHP_FPM_GROUP
9142
9143
9144
9145
9146
9147
9148php_with_fpm_systemd=no
9149
9150
9151
9152# Check whether --with-fpm-systemd was given.
9153if test ${with_fpm_systemd+y}
9154then :
9155  withval=$with_fpm_systemd; PHP_FPM_SYSTEMD=$withval
9156else $as_nop
9157
9158  PHP_FPM_SYSTEMD=no
9159
9160
9161fi
9162
9163
9164ext_output=$PHP_FPM_SYSTEMD
9165
9166
9167
9168
9169
9170
9171php_with_fpm_acl=no
9172
9173
9174
9175# Check whether --with-fpm-acl was given.
9176if test ${with_fpm_acl+y}
9177then :
9178  withval=$with_fpm_acl; PHP_FPM_ACL=$withval
9179else $as_nop
9180
9181  PHP_FPM_ACL=no
9182
9183
9184fi
9185
9186
9187ext_output=$PHP_FPM_ACL
9188
9189
9190
9191
9192
9193
9194php_with_fpm_apparmor=no
9195
9196
9197
9198# Check whether --with-fpm-apparmor was given.
9199if test ${with_fpm_apparmor+y}
9200then :
9201  withval=$with_fpm_apparmor; PHP_FPM_APPARMOR=$withval
9202else $as_nop
9203
9204  PHP_FPM_APPARMOR=no
9205
9206
9207fi
9208
9209
9210ext_output=$PHP_FPM_APPARMOR
9211
9212
9213
9214
9215
9216  if test "$PHP_FPM_SYSTEMD" != "no" ; then
9217
9218pkg_failed=no
9219{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsystemd >= 209" >&5
9220printf %s "checking for libsystemd >= 209... " >&6; }
9221
9222if test -n "$SYSTEMD_CFLAGS"; then
9223    pkg_cv_SYSTEMD_CFLAGS="$SYSTEMD_CFLAGS"
9224 elif test -n "$PKG_CONFIG"; then
9225    if test -n "$PKG_CONFIG" && \
9226    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd >= 209\""; } >&5
9227  ($PKG_CONFIG --exists --print-errors "libsystemd >= 209") 2>&5
9228  ac_status=$?
9229  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9230  test $ac_status = 0; }; then
9231  pkg_cv_SYSTEMD_CFLAGS=`$PKG_CONFIG --cflags "libsystemd >= 209" 2>/dev/null`
9232		      test "x$?" != "x0" && pkg_failed=yes
9233else
9234  pkg_failed=yes
9235fi
9236 else
9237    pkg_failed=untried
9238fi
9239if test -n "$SYSTEMD_LIBS"; then
9240    pkg_cv_SYSTEMD_LIBS="$SYSTEMD_LIBS"
9241 elif test -n "$PKG_CONFIG"; then
9242    if test -n "$PKG_CONFIG" && \
9243    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd >= 209\""; } >&5
9244  ($PKG_CONFIG --exists --print-errors "libsystemd >= 209") 2>&5
9245  ac_status=$?
9246  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9247  test $ac_status = 0; }; then
9248  pkg_cv_SYSTEMD_LIBS=`$PKG_CONFIG --libs "libsystemd >= 209" 2>/dev/null`
9249		      test "x$?" != "x0" && pkg_failed=yes
9250else
9251  pkg_failed=yes
9252fi
9253 else
9254    pkg_failed=untried
9255fi
9256
9257
9258
9259if test $pkg_failed = yes; then
9260        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9261printf "%s\n" "no" >&6; }
9262
9263if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
9264        _pkg_short_errors_supported=yes
9265else
9266        _pkg_short_errors_supported=no
9267fi
9268        if test $_pkg_short_errors_supported = yes; then
9269	        SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd >= 209" 2>&1`
9270        else
9271	        SYSTEMD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd >= 209" 2>&1`
9272        fi
9273	# Put the nasty error message in config.log where it belongs
9274	echo "$SYSTEMD_PKG_ERRORS" >&5
9275
9276	as_fn_error $? "Package requirements (libsystemd >= 209) were not met:
9277
9278$SYSTEMD_PKG_ERRORS
9279
9280Consider adjusting the PKG_CONFIG_PATH environment variable if you
9281installed software in a non-standard prefix.
9282
9283Alternatively, you may set the environment variables SYSTEMD_CFLAGS
9284and SYSTEMD_LIBS to avoid the need to call pkg-config.
9285See the pkg-config man page for more details." "$LINENO" 5
9286elif test $pkg_failed = untried; then
9287        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9288printf "%s\n" "no" >&6; }
9289	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9290printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
9291as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
9292is in your PATH or set the PKG_CONFIG environment variable to the full
9293path to pkg-config.
9294
9295Alternatively, you may set the environment variables SYSTEMD_CFLAGS
9296and SYSTEMD_LIBS to avoid the need to call pkg-config.
9297See the pkg-config man page for more details.
9298
9299To get pkg-config, see <http://pkg-config.freedesktop.org/>.
9300See \`config.log' for more details" "$LINENO" 5; }
9301else
9302	SYSTEMD_CFLAGS=$pkg_cv_SYSTEMD_CFLAGS
9303	SYSTEMD_LIBS=$pkg_cv_SYSTEMD_LIBS
9304        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9305printf "%s\n" "yes" >&6; }
9306
9307fi
9308
9309           for ac_header in systemd/sd-daemon.h
9310do :
9311  ac_fn_c_check_header_compile "$LINENO" "systemd/sd-daemon.h" "ac_cv_header_systemd_sd_daemon_h" "$ac_includes_default"
9312if test "x$ac_cv_header_systemd_sd_daemon_h" = xyes
9313then :
9314  printf "%s\n" "#define HAVE_SYSTEMD_SD_DAEMON_H 1" >>confdefs.h
9315 HAVE_SD_DAEMON_H="yes"
9316else $as_nop
9317  HAVE_SD_DAEMON_H="no"
9318fi
9319
9320done
9321    if test $HAVE_SD_DAEMON_H = "no"; then
9322      as_fn_error $? "Your system does not support systemd." "$LINENO" 5
9323    else
9324
9325printf "%s\n" "#define HAVE_SYSTEMD 1" >>confdefs.h
9326
9327      PHP_FPM_SD_FILES="fpm/fpm_systemd.c"
9328
9329  for ac_i in $SYSTEMD_LIBS; do
9330    case $ac_i in
9331    -pthread)
9332      if test "$ext_shared" = "yes"; then
9333        ="$ -pthread"
9334      else
9335
9336
9337  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
9338
9339  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
9340  if test -n "$unique" && test "`eval $cmd`" = "" ; then
9341    eval "EXTRA_LDFLAGS$unique=set"
9342    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
9343  fi
9344
9345
9346
9347  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
9348
9349  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
9350  if test -n "$unique" && test "`eval $cmd`" = "" ; then
9351    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
9352    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
9353  fi
9354
9355      fi
9356    ;;
9357    -l*)
9358      ac_ii=`echo $ac_i|cut -c 3-`
9359
9360
9361  case $ac_ii in
9362  c|c_r) ;;
9363  *)
9364      LIBS="$LIBS -l$ac_ii"
9365   ;;
9366  esac
9367
9368
9369    ;;
9370    -L*)
9371      ac_ii=`echo $ac_i|cut -c 3-`
9372
9373  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
9374
9375  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
9376    ai_p=$ac_ii
9377  else
9378
9379    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
9380
9381    ep_realdir=`(cd "$ep_dir" && pwd)`
9382    ai_p="$ep_realdir"/`basename "$ac_ii"`
9383  fi
9384
9385
9386
9387
9388
9389  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
9390
9391  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
9392  if test -n "$unique" && test "`eval $cmd`" = "" ; then
9393    eval "LIBPATH$unique=set"
9394
9395    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
9396    LDFLAGS="$LDFLAGS -L$ai_p"
9397    PHP_RPATHS="$PHP_RPATHS $ai_p"
9398
9399  fi
9400
9401
9402
9403  fi
9404
9405    ;;
9406    esac
9407  done
9408
9409
9410  for ac_i in $SYSTEMD_CFLAGS; do
9411    case $ac_i in
9412    -I*)
9413      ac_ii=`echo $ac_i|cut -c 3-`
9414
9415  if test "$ac_ii" != "/usr/include"; then
9416
9417  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
9418    ai_p=$ac_ii
9419  else
9420
9421    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
9422
9423    ep_realdir=`(cd "$ep_dir" && pwd)`
9424    ai_p="$ep_realdir"/`basename "$ac_ii"`
9425  fi
9426
9427
9428
9429  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
9430
9431  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
9432  if test -n "$unique" && test "`eval $cmd`" = "" ; then
9433    eval "INCLUDEPATH$unique=set"
9434
9435      if test ""; then
9436        INCLUDES="-I$ai_p $INCLUDES"
9437      else
9438        INCLUDES="$INCLUDES -I$ai_p"
9439      fi
9440
9441  fi
9442
9443  fi
9444
9445    ;;
9446    esac
9447  done
9448
9449      php_fpm_systemd=notify
9450    fi
9451  else
9452    php_fpm_systemd=simple
9453  fi
9454
9455  if test "$PHP_FPM_ACL" != "no" ; then
9456    ac_fn_c_check_header_compile "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
9457if test "x$ac_cv_header_sys_acl_h" = xyes
9458then :
9459  printf "%s\n" "#define HAVE_SYS_ACL_H 1" >>confdefs.h
9460
9461fi
9462
9463        ac_fn_c_check_func "$LINENO" "acl_free" "ac_cv_func_acl_free"
9464if test "x$ac_cv_func_acl_free" = xyes
9465then :
9466
9467
9468printf "%s\n" "#define HAVE_FPM_ACL 1" >>confdefs.h
9469
9470
9471else $as_nop
9472
9473      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for acl_free in -lacl" >&5
9474printf %s "checking for acl_free in -lacl... " >&6; }
9475if test ${ac_cv_lib_acl_acl_free+y}
9476then :
9477  printf %s "(cached) " >&6
9478else $as_nop
9479  ac_check_lib_save_LIBS=$LIBS
9480LIBS="-lacl  $LIBS"
9481cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9482/* end confdefs.h.  */
9483
9484/* Override any GCC internal prototype to avoid an error.
9485   Use char because int might match the return type of a GCC
9486   builtin and then its argument prototype would still apply.  */
9487char acl_free ();
9488int
9489main (void)
9490{
9491return acl_free ();
9492  ;
9493  return 0;
9494}
9495_ACEOF
9496if ac_fn_c_try_link "$LINENO"
9497then :
9498  ac_cv_lib_acl_acl_free=yes
9499else $as_nop
9500  ac_cv_lib_acl_acl_free=no
9501fi
9502rm -f core conftest.err conftest.$ac_objext conftest.beam \
9503    conftest$ac_exeext conftest.$ac_ext
9504LIBS=$ac_check_lib_save_LIBS
9505fi
9506{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_acl_acl_free" >&5
9507printf "%s\n" "$ac_cv_lib_acl_acl_free" >&6; }
9508if test "x$ac_cv_lib_acl_acl_free" = xyes
9509then :
9510
9511
9512
9513  case acl in
9514  c|c_r) ;;
9515  *)
9516      LIBS="-lacl $LIBS"
9517   ;;
9518  esac
9519
9520
9521
9522printf "%s\n" "#define HAVE_FPM_ACL 1" >>confdefs.h
9523
9524
9525else $as_nop
9526
9527        as_fn_error $? "libacl required not found" "$LINENO" 5
9528
9529fi
9530
9531
9532fi
9533
9534  fi
9535
9536  if test "x$PHP_FPM_APPARMOR" != "xno" ; then
9537    ac_fn_c_check_header_compile "$LINENO" "sys/apparmor.h" "ac_cv_header_sys_apparmor_h" "$ac_includes_default"
9538if test "x$ac_cv_header_sys_apparmor_h" = xyes
9539then :
9540  printf "%s\n" "#define HAVE_SYS_APPARMOR_H 1" >>confdefs.h
9541
9542fi
9543
9544    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for aa_change_profile in -lapparmor" >&5
9545printf %s "checking for aa_change_profile in -lapparmor... " >&6; }
9546if test ${ac_cv_lib_apparmor_aa_change_profile+y}
9547then :
9548  printf %s "(cached) " >&6
9549else $as_nop
9550  ac_check_lib_save_LIBS=$LIBS
9551LIBS="-lapparmor  $LIBS"
9552cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9553/* end confdefs.h.  */
9554
9555/* Override any GCC internal prototype to avoid an error.
9556   Use char because int might match the return type of a GCC
9557   builtin and then its argument prototype would still apply.  */
9558char aa_change_profile ();
9559int
9560main (void)
9561{
9562return aa_change_profile ();
9563  ;
9564  return 0;
9565}
9566_ACEOF
9567if ac_fn_c_try_link "$LINENO"
9568then :
9569  ac_cv_lib_apparmor_aa_change_profile=yes
9570else $as_nop
9571  ac_cv_lib_apparmor_aa_change_profile=no
9572fi
9573rm -f core conftest.err conftest.$ac_objext conftest.beam \
9574    conftest$ac_exeext conftest.$ac_ext
9575LIBS=$ac_check_lib_save_LIBS
9576fi
9577{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_apparmor_aa_change_profile" >&5
9578printf "%s\n" "$ac_cv_lib_apparmor_aa_change_profile" >&6; }
9579if test "x$ac_cv_lib_apparmor_aa_change_profile" = xyes
9580then :
9581
9582
9583
9584  case apparmor in
9585  c|c_r) ;;
9586  *)
9587      LIBS="-lapparmor $LIBS"
9588   ;;
9589  esac
9590
9591
9592
9593printf "%s\n" "#define HAVE_APPARMOR 1" >>confdefs.h
9594
9595
9596else $as_nop
9597
9598      as_fn_error $? "libapparmor required but not found" "$LINENO" 5
9599
9600fi
9601
9602  fi
9603
9604
9605
9606
9607  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_systemd"
9608
9609
9610
9611printf "%s\n" "#define PHP_FPM_SYSTEMD \"$php_fpm_systemd\"" >>confdefs.h
9612
9613
9614  if test -z "$PHP_FPM_USER" -o "$PHP_FPM_USER" = "yes" -o "$PHP_FPM_USER" = "no"; then
9615    php_fpm_user="nobody"
9616  else
9617    php_fpm_user="$PHP_FPM_USER"
9618  fi
9619
9620  if test -z "$PHP_FPM_GROUP" -o "$PHP_FPM_GROUP" = "yes" -o "$PHP_FPM_GROUP" = "no"; then
9621    php_fpm_group="nobody"
9622  else
9623    php_fpm_group="$PHP_FPM_GROUP"
9624  fi
9625
9626
9627
9628
9629  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_user"
9630
9631
9632
9633
9634
9635  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_group"
9636
9637
9638  php_fpm_sysconfdir=`eval echo $sysconfdir`
9639
9640
9641
9642  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_sysconfdir"
9643
9644
9645  php_fpm_localstatedir=`eval echo $localstatedir`
9646
9647
9648
9649  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_localstatedir"
9650
9651
9652  php_fpm_prefix=`eval echo $prefix`
9653
9654
9655
9656  PHP_VAR_SUBST="$PHP_VAR_SUBST php_fpm_prefix"
9657
9658
9659
9660
9661printf "%s\n" "#define PHP_FPM_USER \"$php_fpm_user\"" >>confdefs.h
9662
9663
9664printf "%s\n" "#define PHP_FPM_GROUP \"$php_fpm_group\"" >>confdefs.h
9665
9666
9667
9668
9669    BUILD_DIR="$BUILD_DIR sapi/fpm/fpm"
9670
9671
9672
9673
9674    BUILD_DIR="$BUILD_DIR sapi/fpm/fpm/events"
9675
9676
9677
9678  PHP_OUTPUT_FILES="$PHP_OUTPUT_FILES sapi/fpm/php-fpm.conf sapi/fpm/www.conf sapi/fpm/init.d.php-fpm sapi/fpm/php-fpm.service sapi/fpm/php-fpm.8 sapi/fpm/status.html"
9679
9680
9681  src=$abs_srcdir/sapi/fpm/Makefile.frag
9682  ac_srcdir=$ext_srcdir
9683  ac_builddir=$ext_builddir
9684  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
9685
9686
9687  SAPI_FPM_PATH=sapi/fpm/php-fpm
9688
9689  if test "$fpm_trace_type" && test -f "$abs_srcdir/sapi/fpm/fpm/fpm_trace_$fpm_trace_type.c"; then
9690    PHP_FPM_TRACE_FILES="fpm/fpm_trace.c fpm/fpm_trace_$fpm_trace_type.c"
9691  fi
9692
9693  PHP_FPM_CFLAGS="-I$abs_srcdir/sapi/fpm -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
9694
9695  PHP_FPM_FILES="fpm/fpm.c \
9696    fpm/fpm_children.c \
9697    fpm/fpm_cleanup.c \
9698    fpm/fpm_clock.c \
9699    fpm/fpm_conf.c \
9700    fpm/fpm_env.c \
9701    fpm/fpm_events.c \
9702		fpm/fpm_log.c \
9703    fpm/fpm_main.c \
9704    fpm/fpm_php.c \
9705    fpm/fpm_php_trace.c \
9706    fpm/fpm_process_ctl.c \
9707    fpm/fpm_request.c \
9708    fpm/fpm_shm.c \
9709    fpm/fpm_scoreboard.c \
9710    fpm/fpm_signals.c \
9711    fpm/fpm_sockets.c \
9712    fpm/fpm_status.c \
9713    fpm/fpm_stdio.c \
9714    fpm/fpm_unix.c \
9715    fpm/fpm_worker_pool.c \
9716    fpm/zlog.c \
9717		fpm/events/select.c \
9718		fpm/events/poll.c \
9719		fpm/events/epoll.c \
9720		fpm/events/kqueue.c \
9721		fpm/events/devpoll.c \
9722		fpm/events/port.c \
9723  "
9724
9725
9726  if test "program" = "program"; then
9727    PHP_BINARIES="$PHP_BINARIES fpm"
9728  elif test "$PHP_SAPI" != "none"; then
9729    as_fn_error $? "
9730+--------------------------------------------------------------------+
9731|                        *** ATTENTION ***                           |
9732|                                                                    |
9733| You've configured multiple SAPIs to be built. You can build only   |
9734| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
9735+--------------------------------------------------------------------+
9736" "$LINENO" 5
9737  else
9738    PHP_SAPI=fpm
9739  fi
9740
9741
9742
9743    BUILD_DIR="$BUILD_DIR sapi/fpm"
9744
9745
9746
9747  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS fpm"
9748
9749
9750
9751  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
9752  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
9753  php_c_post=
9754  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
9755  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
9756  php_cxx_post=
9757  php_lo=lo
9758
9759  case $with_pic in
9760    yes) pic_setting='-prefer-pic';;
9761    no)  pic_setting='-prefer-non-pic';;
9762  esac
9763
9764  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
9765  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
9766  shared_c_post=
9767  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
9768  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
9769  shared_cxx_post=
9770  shared_lo=lo
9771
9772    install_binaries="install-binaries"
9773    install_binary_targets="$install_binary_targets install-fpm"
9774
9775  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FPM_OBJS"
9776
9777
9778  case sapi/fpm in
9779  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
9780  /*) ac_srcdir=`echo "sapi/fpm"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
9781  *) ac_srcdir="$abs_srcdir/sapi/fpm/"; ac_bdir="sapi/fpm/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
9782  esac
9783
9784
9785
9786  b_c_pre=$php_c_pre
9787  b_cxx_pre=$php_cxx_pre
9788  b_c_meta=$php_c_meta
9789  b_cxx_meta=$php_cxx_meta
9790  b_c_post=$php_c_post
9791  b_cxx_post=$php_cxx_post
9792  b_lo=$php_lo
9793
9794
9795  old_IFS=$IFS
9796  for ac_src in $PHP_FPM_FILES $PHP_FPM_TRACE_FILES $PHP_FPM_SD_FILES; do
9797
9798      IFS=.
9799      set $ac_src
9800      ac_obj=$1
9801      IFS=$old_IFS
9802
9803      PHP_FPM_OBJS="$PHP_FPM_OBJS $ac_bdir$ac_obj.lo"
9804
9805      case $ac_src in
9806        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_FPM_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
9807        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_FPM_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
9808        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_FPM_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
9809        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $PHP_FPM_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
9810      esac
9811
9812      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
9813
9814    cat >>Makefile.objects<<EOF
9815-include $ac_bdir$ac_obj.dep
9816$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
9817	$ac_comp
9818EOF
9819  done
9820
9821
9822
9823
9824  case $host_alias in
9825      *aix*)
9826        BUILD_FPM="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FPM_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FASTCGI_OBJS) \$(PHP_FPM_OBJS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)"
9827        ;;
9828      *darwin*)
9829        BUILD_FPM="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)"
9830      ;;
9831      *)
9832        BUILD_FPM="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_FPM_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(FPM_EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_FPM_PATH)"
9833      ;;
9834  esac
9835
9836
9837  PHP_VAR_SUBST="$PHP_VAR_SUBST SAPI_FPM_PATH"
9838
9839
9840  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_FPM"
9841
9842
9843else
9844  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9845printf "%s\n" "no" >&6; }
9846fi
9847
9848
9849
9850
9851{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clang fuzzer SAPI" >&5
9852printf %s "checking for clang fuzzer SAPI... " >&6; }
9853
9854
9855php_enable_fuzzer=no
9856
9857
9858# Check whether --enable-fuzzer was given.
9859if test ${enable_fuzzer+y}
9860then :
9861  enableval=$enable_fuzzer; PHP_FUZZER=$enableval
9862else $as_nop
9863
9864  PHP_FUZZER=no
9865
9866
9867fi
9868
9869
9870ext_output=$PHP_FUZZER
9871
9872
9873
9874
9875
9876
9877php_enable_fuzzer_msan=no
9878
9879
9880# Check whether --enable-fuzzer-msan was given.
9881if test ${enable_fuzzer_msan+y}
9882then :
9883  enableval=$enable_fuzzer_msan; PHP_FUZZER_MSAN=$enableval
9884else $as_nop
9885
9886  PHP_FUZZER_MSAN=no
9887
9888
9889fi
9890
9891
9892ext_output=$PHP_FUZZER_MSAN
9893
9894
9895
9896
9897
9898
9899
9900
9901if test "$PHP_FUZZER" != "no"; then
9902  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9903printf "%s\n" "yes" >&6; }
9904
9905
9906
9907
9908
9909
9910ac_ext=cpp
9911ac_cpp='$CXXCPP $CPPFLAGS'
9912ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9913ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9914ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9915if test -z "$CXX"; then
9916  if test -n "$CCC"; then
9917    CXX=$CCC
9918  else
9919    if test -n "$ac_tool_prefix"; then
9920  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
9921  do
9922    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
9923set dummy $ac_tool_prefix$ac_prog; ac_word=$2
9924{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9925printf %s "checking for $ac_word... " >&6; }
9926if test ${ac_cv_prog_CXX+y}
9927then :
9928  printf %s "(cached) " >&6
9929else $as_nop
9930  if test -n "$CXX"; then
9931  ac_cv_prog_CXX="$CXX" # Let the user override the test.
9932else
9933as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9934for as_dir in $PATH
9935do
9936  IFS=$as_save_IFS
9937  case $as_dir in #(((
9938    '') as_dir=./ ;;
9939    */) ;;
9940    *) as_dir=$as_dir/ ;;
9941  esac
9942    for ac_exec_ext in '' $ac_executable_extensions; do
9943  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
9944    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
9945    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
9946    break 2
9947  fi
9948done
9949  done
9950IFS=$as_save_IFS
9951
9952fi
9953fi
9954CXX=$ac_cv_prog_CXX
9955if test -n "$CXX"; then
9956  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
9957printf "%s\n" "$CXX" >&6; }
9958else
9959  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
9960printf "%s\n" "no" >&6; }
9961fi
9962
9963
9964    test -n "$CXX" && break
9965  done
9966fi
9967if test -z "$CXX"; then
9968  ac_ct_CXX=$CXX
9969  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
9970do
9971  # Extract the first word of "$ac_prog", so it can be a program name with args.
9972set dummy $ac_prog; ac_word=$2
9973{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9974printf %s "checking for $ac_word... " >&6; }
9975if test ${ac_cv_prog_ac_ct_CXX+y}
9976then :
9977  printf %s "(cached) " >&6
9978else $as_nop
9979  if test -n "$ac_ct_CXX"; then
9980  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
9981else
9982as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9983for as_dir in $PATH
9984do
9985  IFS=$as_save_IFS
9986  case $as_dir in #(((
9987    '') as_dir=./ ;;
9988    */) ;;
9989    *) as_dir=$as_dir/ ;;
9990  esac
9991    for ac_exec_ext in '' $ac_executable_extensions; do
9992  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
9993    ac_cv_prog_ac_ct_CXX="$ac_prog"
9994    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
9995    break 2
9996  fi
9997done
9998  done
9999IFS=$as_save_IFS
10000
10001fi
10002fi
10003ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
10004if test -n "$ac_ct_CXX"; then
10005  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
10006printf "%s\n" "$ac_ct_CXX" >&6; }
10007else
10008  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10009printf "%s\n" "no" >&6; }
10010fi
10011
10012
10013  test -n "$ac_ct_CXX" && break
10014done
10015
10016  if test "x$ac_ct_CXX" = x; then
10017    CXX="g++"
10018  else
10019    case $cross_compiling:$ac_tool_warned in
10020yes:)
10021{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10022printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10023ac_tool_warned=yes ;;
10024esac
10025    CXX=$ac_ct_CXX
10026  fi
10027fi
10028
10029  fi
10030fi
10031# Provide some information about the compiler.
10032printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
10033set X $ac_compile
10034ac_compiler=$2
10035for ac_option in --version -v -V -qversion; do
10036  { { ac_try="$ac_compiler $ac_option >&5"
10037case "(($ac_try" in
10038  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10039  *) ac_try_echo=$ac_try;;
10040esac
10041eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
10042printf "%s\n" "$ac_try_echo"; } >&5
10043  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
10044  ac_status=$?
10045  if test -s conftest.err; then
10046    sed '10a\
10047... rest of stderr output deleted ...
10048         10q' conftest.err >conftest.er1
10049    cat conftest.er1 >&5
10050  fi
10051  rm -f conftest.er1 conftest.err
10052  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10053  test $ac_status = 0; }
10054done
10055
10056{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C++" >&5
10057printf %s "checking whether the compiler supports GNU C++... " >&6; }
10058if test ${ac_cv_cxx_compiler_gnu+y}
10059then :
10060  printf %s "(cached) " >&6
10061else $as_nop
10062  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10063/* end confdefs.h.  */
10064
10065int
10066main (void)
10067{
10068#ifndef __GNUC__
10069       choke me
10070#endif
10071
10072  ;
10073  return 0;
10074}
10075_ACEOF
10076if ac_fn_cxx_try_compile "$LINENO"
10077then :
10078  ac_compiler_gnu=yes
10079else $as_nop
10080  ac_compiler_gnu=no
10081fi
10082rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10083ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
10084
10085fi
10086{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
10087printf "%s\n" "$ac_cv_cxx_compiler_gnu" >&6; }
10088ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
10089
10090if test $ac_compiler_gnu = yes; then
10091  GXX=yes
10092else
10093  GXX=
10094fi
10095ac_test_CXXFLAGS=${CXXFLAGS+y}
10096ac_save_CXXFLAGS=$CXXFLAGS
10097{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
10098printf %s "checking whether $CXX accepts -g... " >&6; }
10099if test ${ac_cv_prog_cxx_g+y}
10100then :
10101  printf %s "(cached) " >&6
10102else $as_nop
10103  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
10104   ac_cxx_werror_flag=yes
10105   ac_cv_prog_cxx_g=no
10106   CXXFLAGS="-g"
10107   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10108/* end confdefs.h.  */
10109
10110int
10111main (void)
10112{
10113
10114  ;
10115  return 0;
10116}
10117_ACEOF
10118if ac_fn_cxx_try_compile "$LINENO"
10119then :
10120  ac_cv_prog_cxx_g=yes
10121else $as_nop
10122  CXXFLAGS=""
10123      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10124/* end confdefs.h.  */
10125
10126int
10127main (void)
10128{
10129
10130  ;
10131  return 0;
10132}
10133_ACEOF
10134if ac_fn_cxx_try_compile "$LINENO"
10135then :
10136
10137else $as_nop
10138  ac_cxx_werror_flag=$ac_save_cxx_werror_flag
10139	 CXXFLAGS="-g"
10140	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10141/* end confdefs.h.  */
10142
10143int
10144main (void)
10145{
10146
10147  ;
10148  return 0;
10149}
10150_ACEOF
10151if ac_fn_cxx_try_compile "$LINENO"
10152then :
10153  ac_cv_prog_cxx_g=yes
10154fi
10155rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10156fi
10157rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10158fi
10159rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10160   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
10161fi
10162{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
10163printf "%s\n" "$ac_cv_prog_cxx_g" >&6; }
10164if test $ac_test_CXXFLAGS; then
10165  CXXFLAGS=$ac_save_CXXFLAGS
10166elif test $ac_cv_prog_cxx_g = yes; then
10167  if test "$GXX" = yes; then
10168    CXXFLAGS="-g -O2"
10169  else
10170    CXXFLAGS="-g"
10171  fi
10172else
10173  if test "$GXX" = yes; then
10174    CXXFLAGS="-O2"
10175  else
10176    CXXFLAGS=
10177  fi
10178fi
10179ac_prog_cxx_stdcxx=no
10180if test x$ac_prog_cxx_stdcxx = xno
10181then :
10182  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++11 features" >&5
10183printf %s "checking for $CXX option to enable C++11 features... " >&6; }
10184if test ${ac_cv_prog_cxx_11+y}
10185then :
10186  printf %s "(cached) " >&6
10187else $as_nop
10188  ac_cv_prog_cxx_11=no
10189ac_save_CXX=$CXX
10190cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10191/* end confdefs.h.  */
10192$ac_cxx_conftest_cxx11_program
10193_ACEOF
10194for ac_arg in '' -std=gnu++11 -std=gnu++0x -std=c++11 -std=c++0x -qlanglvl=extended0x -AA
10195do
10196  CXX="$ac_save_CXX $ac_arg"
10197  if ac_fn_cxx_try_compile "$LINENO"
10198then :
10199  ac_cv_prog_cxx_cxx11=$ac_arg
10200fi
10201rm -f core conftest.err conftest.$ac_objext conftest.beam
10202  test "x$ac_cv_prog_cxx_cxx11" != "xno" && break
10203done
10204rm -f conftest.$ac_ext
10205CXX=$ac_save_CXX
10206fi
10207
10208if test "x$ac_cv_prog_cxx_cxx11" = xno
10209then :
10210  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
10211printf "%s\n" "unsupported" >&6; }
10212else $as_nop
10213  if test "x$ac_cv_prog_cxx_cxx11" = x
10214then :
10215  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
10216printf "%s\n" "none needed" >&6; }
10217else $as_nop
10218  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx11" >&5
10219printf "%s\n" "$ac_cv_prog_cxx_cxx11" >&6; }
10220     CXX="$CXX $ac_cv_prog_cxx_cxx11"
10221fi
10222  ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx11
10223  ac_prog_cxx_stdcxx=cxx11
10224fi
10225fi
10226if test x$ac_prog_cxx_stdcxx = xno
10227then :
10228  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++98 features" >&5
10229printf %s "checking for $CXX option to enable C++98 features... " >&6; }
10230if test ${ac_cv_prog_cxx_98+y}
10231then :
10232  printf %s "(cached) " >&6
10233else $as_nop
10234  ac_cv_prog_cxx_98=no
10235ac_save_CXX=$CXX
10236cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10237/* end confdefs.h.  */
10238$ac_cxx_conftest_cxx98_program
10239_ACEOF
10240for ac_arg in '' -std=gnu++98 -std=c++98 -qlanglvl=extended -AA
10241do
10242  CXX="$ac_save_CXX $ac_arg"
10243  if ac_fn_cxx_try_compile "$LINENO"
10244then :
10245  ac_cv_prog_cxx_cxx98=$ac_arg
10246fi
10247rm -f core conftest.err conftest.$ac_objext conftest.beam
10248  test "x$ac_cv_prog_cxx_cxx98" != "xno" && break
10249done
10250rm -f conftest.$ac_ext
10251CXX=$ac_save_CXX
10252fi
10253
10254if test "x$ac_cv_prog_cxx_cxx98" = xno
10255then :
10256  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
10257printf "%s\n" "unsupported" >&6; }
10258else $as_nop
10259  if test "x$ac_cv_prog_cxx_cxx98" = x
10260then :
10261  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
10262printf "%s\n" "none needed" >&6; }
10263else $as_nop
10264  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx98" >&5
10265printf "%s\n" "$ac_cv_prog_cxx_cxx98" >&6; }
10266     CXX="$CXX $ac_cv_prog_cxx_cxx98"
10267fi
10268  ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx98
10269  ac_prog_cxx_stdcxx=cxx98
10270fi
10271fi
10272
10273ac_ext=c
10274ac_cpp='$CPP $CPPFLAGS'
10275ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10276ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10277ac_compiler_gnu=$ac_cv_c_compiler_gnu
10278
10279  ac_ext=cpp
10280ac_cpp='$CXXCPP $CPPFLAGS'
10281ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10282ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10283ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
10284{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
10285printf %s "checking how to run the C++ preprocessor... " >&6; }
10286if test -z "$CXXCPP"; then
10287  if test ${ac_cv_prog_CXXCPP+y}
10288then :
10289  printf %s "(cached) " >&6
10290else $as_nop
10291      # Double quotes because $CXX needs to be expanded
10292    for CXXCPP in "$CXX -E" cpp /lib/cpp
10293    do
10294      ac_preproc_ok=false
10295for ac_cxx_preproc_warn_flag in '' yes
10296do
10297  # Use a header file that comes with gcc, so configuring glibc
10298  # with a fresh cross-compiler works.
10299  # On the NeXT, cc -E runs the code through the compiler's parser,
10300  # not just through cpp. "Syntax error" is here to catch this case.
10301  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10302/* end confdefs.h.  */
10303#include <limits.h>
10304		     Syntax error
10305_ACEOF
10306if ac_fn_cxx_try_cpp "$LINENO"
10307then :
10308
10309else $as_nop
10310  # Broken: fails on valid input.
10311continue
10312fi
10313rm -f conftest.err conftest.i conftest.$ac_ext
10314
10315  # OK, works on sane cases.  Now check whether nonexistent headers
10316  # can be detected and how.
10317  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10318/* end confdefs.h.  */
10319#include <ac_nonexistent.h>
10320_ACEOF
10321if ac_fn_cxx_try_cpp "$LINENO"
10322then :
10323  # Broken: success on invalid input.
10324continue
10325else $as_nop
10326  # Passes both tests.
10327ac_preproc_ok=:
10328break
10329fi
10330rm -f conftest.err conftest.i conftest.$ac_ext
10331
10332done
10333# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
10334rm -f conftest.i conftest.err conftest.$ac_ext
10335if $ac_preproc_ok
10336then :
10337  break
10338fi
10339
10340    done
10341    ac_cv_prog_CXXCPP=$CXXCPP
10342
10343fi
10344  CXXCPP=$ac_cv_prog_CXXCPP
10345else
10346  ac_cv_prog_CXXCPP=$CXXCPP
10347fi
10348{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
10349printf "%s\n" "$CXXCPP" >&6; }
10350ac_preproc_ok=false
10351for ac_cxx_preproc_warn_flag in '' yes
10352do
10353  # Use a header file that comes with gcc, so configuring glibc
10354  # with a fresh cross-compiler works.
10355  # On the NeXT, cc -E runs the code through the compiler's parser,
10356  # not just through cpp. "Syntax error" is here to catch this case.
10357  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10358/* end confdefs.h.  */
10359#include <limits.h>
10360		     Syntax error
10361_ACEOF
10362if ac_fn_cxx_try_cpp "$LINENO"
10363then :
10364
10365else $as_nop
10366  # Broken: fails on valid input.
10367continue
10368fi
10369rm -f conftest.err conftest.i conftest.$ac_ext
10370
10371  # OK, works on sane cases.  Now check whether nonexistent headers
10372  # can be detected and how.
10373  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10374/* end confdefs.h.  */
10375#include <ac_nonexistent.h>
10376_ACEOF
10377if ac_fn_cxx_try_cpp "$LINENO"
10378then :
10379  # Broken: success on invalid input.
10380continue
10381else $as_nop
10382  # Passes both tests.
10383ac_preproc_ok=:
10384break
10385fi
10386rm -f conftest.err conftest.i conftest.$ac_ext
10387
10388done
10389# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
10390rm -f conftest.i conftest.err conftest.$ac_ext
10391if $ac_preproc_ok
10392then :
10393
10394else $as_nop
10395  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10396printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
10397as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
10398See \`config.log' for more details" "$LINENO" 5; }
10399fi
10400
10401ac_ext=c
10402ac_cpp='$CPP $CPPFLAGS'
10403ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10404ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10405ac_compiler_gnu=$ac_cv_c_compiler_gnu
10406
10407
10408  src=$abs_srcdir/sapi/fuzzer/Makefile.frag
10409  ac_srcdir=$ext_srcdir
10410  ac_builddir=$ext_builddir
10411  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
10412
10413  SAPI_FUZZER_PATH=sapi/fuzzer
10414
10415  PHP_VAR_SUBST="$PHP_VAR_SUBST SAPI_FUZZER_PATH"
10416
10417  if test -z "$LIB_FUZZING_ENGINE"; then
10418    FUZZING_LIB="-fsanitize=fuzzer"
10419    FUZZING_CC="$CC"
10420    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fsanitize=fuzzer-no-link" >&5
10421printf %s "checking whether C compiler accepts -fsanitize=fuzzer-no-link... " >&6; }
10422if test ${ax_cv_check_cflags___fsanitize_fuzzer_no_link+y}
10423then :
10424  printf %s "(cached) " >&6
10425else $as_nop
10426
10427  ax_check_save_flags=$CFLAGS
10428  CFLAGS="$CFLAGS  -fsanitize=fuzzer-no-link"
10429  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10430/* end confdefs.h.  */
10431
10432int
10433main (void)
10434{
10435
10436  ;
10437  return 0;
10438}
10439_ACEOF
10440if ac_fn_c_try_compile "$LINENO"
10441then :
10442  ax_cv_check_cflags___fsanitize_fuzzer_no_link=yes
10443else $as_nop
10444  ax_cv_check_cflags___fsanitize_fuzzer_no_link=no
10445fi
10446rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10447  CFLAGS=$ax_check_save_flags
10448fi
10449{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fsanitize_fuzzer_no_link" >&5
10450printf "%s\n" "$ax_cv_check_cflags___fsanitize_fuzzer_no_link" >&6; }
10451if test "x$ax_cv_check_cflags___fsanitize_fuzzer_no_link" = xyes
10452then :
10453
10454      CFLAGS="$CFLAGS -fsanitize=fuzzer-no-link"
10455      CXXFLAGS="$CXXFLAGS -fsanitize=fuzzer-no-link"
10456
10457      if test "$PHP_FUZZER_MSAN" = "yes"; then
10458        CFLAGS="$CFLAGS -fsanitize=memory -fsanitize-memory-track-origins"
10459        CXXFLAGS="$CXXFLAGS -fsanitize=memory -fsanitize-memory-track-origins"
10460      else
10461        CFLAGS="$CFLAGS -fsanitize=address"
10462        CXXFLAGS="$CXXFLAGS -fsanitize=address"
10463
10464                                                        CFLAGS="$CFLAGS -fsanitize=undefined -fno-sanitize=object-size -fno-sanitize-recover=undefined"
10465      fi
10466
10467else $as_nop
10468
10469      as_fn_error $? "Compiler doesn't support -fsanitize=fuzzer-no-link" "$LINENO" 5
10470
10471fi
10472
10473  else
10474    FUZZING_LIB="$LIB_FUZZING_ENGINE"
10475    FUZZING_CC="$CXX -stdlib=libc++"
10476  fi
10477
10478  PHP_VAR_SUBST="$PHP_VAR_SUBST FUZZING_LIB"
10479
10480
10481  PHP_VAR_SUBST="$PHP_VAR_SUBST FUZZING_CC"
10482
10483
10484
10485
10486
10487    BUILD_DIR="$BUILD_DIR sapi/fuzzer"
10488
10489
10490  PHP_FUZZER_BINARIES=""
10491  PHP_BINARIES="$PHP_BINARIES fuzzer"
10492  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS fuzzer"
10493
10494
10495  case sapi/fuzzer in
10496  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10497  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10498  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10499  esac
10500
10501
10502
10503  b_c_pre=$php_c_pre
10504  b_cxx_pre=$php_cxx_pre
10505  b_c_meta=$php_c_meta
10506  b_cxx_meta=$php_cxx_meta
10507  b_c_post=$php_c_post
10508  b_cxx_post=$php_cxx_post
10509  b_lo=$php_lo
10510
10511
10512  old_IFS=$IFS
10513  for ac_src in fuzzer-sapi.c; do
10514
10515      IFS=.
10516      set $ac_src
10517      ac_obj=$1
10518      IFS=$old_IFS
10519
10520      FUZZER_COMMON_OBJS="$FUZZER_COMMON_OBJS $ac_bdir$ac_obj.lo"
10521
10522      case $ac_src in
10523        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10524        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10525        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10526        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10527      esac
10528
10529      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10530
10531    cat >>Makefile.objects<<EOF
10532-include $ac_bdir$ac_obj.dep
10533$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10534	$ac_comp
10535EOF
10536  done
10537
10538
10539
10540  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-parser"
10541
10542  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_PARSER_OBJS"
10543
10544
10545  case sapi/fuzzer in
10546  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10547  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10548  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10549  esac
10550
10551
10552
10553  b_c_pre=$php_c_pre
10554  b_cxx_pre=$php_cxx_pre
10555  b_c_meta=$php_c_meta
10556  b_cxx_meta=$php_cxx_meta
10557  b_c_post=$php_c_post
10558  b_cxx_post=$php_cxx_post
10559  b_lo=$php_lo
10560
10561
10562  old_IFS=$IFS
10563  for ac_src in fuzzer-parser.c; do
10564
10565      IFS=.
10566      set $ac_src
10567      ac_obj=$1
10568      IFS=$old_IFS
10569
10570      PHP_FUZZER_PARSER_OBJS="$PHP_FUZZER_PARSER_OBJS $ac_bdir$ac_obj.lo"
10571
10572      case $ac_src in
10573        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10574        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10575        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10576        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10577      esac
10578
10579      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10580
10581    cat >>Makefile.objects<<EOF
10582-include $ac_bdir$ac_obj.dep
10583$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10584	$ac_comp
10585EOF
10586  done
10587
10588  PHP_FUZZER_PARSER_OBJS="$PHP_FUZZER_PARSER_OBJS $FUZZER_COMMON_OBJS"
10589
10590
10591  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-execute"
10592
10593  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_EXECUTE_OBJS"
10594
10595
10596  case sapi/fuzzer in
10597  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10598  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10599  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10600  esac
10601
10602
10603
10604  b_c_pre=$php_c_pre
10605  b_cxx_pre=$php_cxx_pre
10606  b_c_meta=$php_c_meta
10607  b_cxx_meta=$php_cxx_meta
10608  b_c_post=$php_c_post
10609  b_cxx_post=$php_cxx_post
10610  b_lo=$php_lo
10611
10612
10613  old_IFS=$IFS
10614  for ac_src in fuzzer-execute.c; do
10615
10616      IFS=.
10617      set $ac_src
10618      ac_obj=$1
10619      IFS=$old_IFS
10620
10621      PHP_FUZZER_EXECUTE_OBJS="$PHP_FUZZER_EXECUTE_OBJS $ac_bdir$ac_obj.lo"
10622
10623      case $ac_src in
10624        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10625        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10626        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10627        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10628      esac
10629
10630      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10631
10632    cat >>Makefile.objects<<EOF
10633-include $ac_bdir$ac_obj.dep
10634$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10635	$ac_comp
10636EOF
10637  done
10638
10639  PHP_FUZZER_EXECUTE_OBJS="$PHP_FUZZER_EXECUTE_OBJS $FUZZER_COMMON_OBJS"
10640
10641
10642  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-unserialize"
10643
10644  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_UNSERIALIZE_OBJS"
10645
10646
10647  case sapi/fuzzer in
10648  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10649  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10650  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10651  esac
10652
10653
10654
10655  b_c_pre=$php_c_pre
10656  b_cxx_pre=$php_cxx_pre
10657  b_c_meta=$php_c_meta
10658  b_cxx_meta=$php_cxx_meta
10659  b_c_post=$php_c_post
10660  b_cxx_post=$php_cxx_post
10661  b_lo=$php_lo
10662
10663
10664  old_IFS=$IFS
10665  for ac_src in fuzzer-unserialize.c; do
10666
10667      IFS=.
10668      set $ac_src
10669      ac_obj=$1
10670      IFS=$old_IFS
10671
10672      PHP_FUZZER_UNSERIALIZE_OBJS="$PHP_FUZZER_UNSERIALIZE_OBJS $ac_bdir$ac_obj.lo"
10673
10674      case $ac_src in
10675        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10676        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10677        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10678        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10679      esac
10680
10681      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10682
10683    cat >>Makefile.objects<<EOF
10684-include $ac_bdir$ac_obj.dep
10685$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10686	$ac_comp
10687EOF
10688  done
10689
10690  PHP_FUZZER_UNSERIALIZE_OBJS="$PHP_FUZZER_UNSERIALIZE_OBJS $FUZZER_COMMON_OBJS"
10691
10692
10693  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-unserializehash"
10694
10695  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_UNSERIALIZEHASH_OBJS"
10696
10697
10698  case sapi/fuzzer in
10699  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10700  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10701  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10702  esac
10703
10704
10705
10706  b_c_pre=$php_c_pre
10707  b_cxx_pre=$php_cxx_pre
10708  b_c_meta=$php_c_meta
10709  b_cxx_meta=$php_cxx_meta
10710  b_c_post=$php_c_post
10711  b_cxx_post=$php_cxx_post
10712  b_lo=$php_lo
10713
10714
10715  old_IFS=$IFS
10716  for ac_src in fuzzer-unserializehash.c; do
10717
10718      IFS=.
10719      set $ac_src
10720      ac_obj=$1
10721      IFS=$old_IFS
10722
10723      PHP_FUZZER_UNSERIALIZEHASH_OBJS="$PHP_FUZZER_UNSERIALIZEHASH_OBJS $ac_bdir$ac_obj.lo"
10724
10725      case $ac_src in
10726        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10727        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10728        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10729        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10730      esac
10731
10732      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10733
10734    cat >>Makefile.objects<<EOF
10735-include $ac_bdir$ac_obj.dep
10736$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10737	$ac_comp
10738EOF
10739  done
10740
10741  PHP_FUZZER_UNSERIALIZEHASH_OBJS="$PHP_FUZZER_UNSERIALIZEHASH_OBJS $FUZZER_COMMON_OBJS"
10742
10743
10744  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-json"
10745
10746  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_JSON_OBJS"
10747
10748
10749  case sapi/fuzzer in
10750  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10751  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10752  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10753  esac
10754
10755
10756
10757  b_c_pre=$php_c_pre
10758  b_cxx_pre=$php_cxx_pre
10759  b_c_meta=$php_c_meta
10760  b_cxx_meta=$php_cxx_meta
10761  b_c_post=$php_c_post
10762  b_cxx_post=$php_cxx_post
10763  b_lo=$php_lo
10764
10765
10766  old_IFS=$IFS
10767  for ac_src in fuzzer-json.c; do
10768
10769      IFS=.
10770      set $ac_src
10771      ac_obj=$1
10772      IFS=$old_IFS
10773
10774      PHP_FUZZER_JSON_OBJS="$PHP_FUZZER_JSON_OBJS $ac_bdir$ac_obj.lo"
10775
10776      case $ac_src in
10777        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10778        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10779        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10780        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10781      esac
10782
10783      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10784
10785    cat >>Makefile.objects<<EOF
10786-include $ac_bdir$ac_obj.dep
10787$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10788	$ac_comp
10789EOF
10790  done
10791
10792  PHP_FUZZER_JSON_OBJS="$PHP_FUZZER_JSON_OBJS $FUZZER_COMMON_OBJS"
10793
10794
10795  if test -n "$enable_exif" && test "$enable_exif" != "no"; then
10796
10797  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-exif"
10798
10799  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_EXIF_OBJS"
10800
10801
10802  case sapi/fuzzer in
10803  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10804  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10805  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10806  esac
10807
10808
10809
10810  b_c_pre=$php_c_pre
10811  b_cxx_pre=$php_cxx_pre
10812  b_c_meta=$php_c_meta
10813  b_cxx_meta=$php_cxx_meta
10814  b_c_post=$php_c_post
10815  b_cxx_post=$php_cxx_post
10816  b_lo=$php_lo
10817
10818
10819  old_IFS=$IFS
10820  for ac_src in fuzzer-exif.c; do
10821
10822      IFS=.
10823      set $ac_src
10824      ac_obj=$1
10825      IFS=$old_IFS
10826
10827      PHP_FUZZER_EXIF_OBJS="$PHP_FUZZER_EXIF_OBJS $ac_bdir$ac_obj.lo"
10828
10829      case $ac_src in
10830        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10831        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10832        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10833        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10834      esac
10835
10836      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10837
10838    cat >>Makefile.objects<<EOF
10839-include $ac_bdir$ac_obj.dep
10840$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10841	$ac_comp
10842EOF
10843  done
10844
10845  PHP_FUZZER_EXIF_OBJS="$PHP_FUZZER_EXIF_OBJS $FUZZER_COMMON_OBJS"
10846
10847  fi
10848  if test -n "$enable_mbstring" && test "$enable_mbstring" != "no"; then
10849
10850  PHP_FUZZER_BINARIES="$PHP_FUZZER_BINARIES $SAPI_FUZZER_PATH/php-fuzz-mbstring"
10851
10852  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_MBSTRING_OBJS"
10853
10854
10855  case sapi/fuzzer in
10856  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
10857  /*) ac_srcdir=`echo "sapi/fuzzer"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
10858  *) ac_srcdir="$abs_srcdir/sapi/fuzzer/"; ac_bdir="sapi/fuzzer/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
10859  esac
10860
10861
10862
10863  b_c_pre=$php_c_pre
10864  b_cxx_pre=$php_cxx_pre
10865  b_c_meta=$php_c_meta
10866  b_cxx_meta=$php_cxx_meta
10867  b_c_post=$php_c_post
10868  b_cxx_post=$php_cxx_post
10869  b_lo=$php_lo
10870
10871
10872  old_IFS=$IFS
10873  for ac_src in fuzzer-mbstring.c; do
10874
10875      IFS=.
10876      set $ac_src
10877      ac_obj=$1
10878      IFS=$old_IFS
10879
10880      PHP_FUZZER_MBSTRING_OBJS="$PHP_FUZZER_MBSTRING_OBJS $ac_bdir$ac_obj.lo"
10881
10882      case $ac_src in
10883        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10884        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10885        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
10886        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
10887      esac
10888
10889      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
10890
10891    cat >>Makefile.objects<<EOF
10892-include $ac_bdir$ac_obj.dep
10893$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
10894	$ac_comp
10895EOF
10896  done
10897
10898  PHP_FUZZER_MBSTRING_OBJS="$PHP_FUZZER_MBSTRING_OBJS $FUZZER_COMMON_OBJS"
10899
10900  fi
10901
10902
10903  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FUZZER_BINARIES"
10904
10905fi
10906
10907{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_FUZZER" >&5
10908printf "%s\n" "$PHP_FUZZER" >&6; }
10909
10910
10911
10912
10913{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LiteSpeed support" >&5
10914printf %s "checking for LiteSpeed support... " >&6; }
10915
10916
10917php_enable_litespeed=no
10918
10919
10920# Check whether --enable-litespeed was given.
10921if test ${enable_litespeed+y}
10922then :
10923  enableval=$enable_litespeed; PHP_LITESPEED=$enableval
10924else $as_nop
10925
10926  PHP_LITESPEED=no
10927  test "$PHP_ENABLE_ALL" && PHP_LITESPEED=$PHP_ENABLE_ALL
10928
10929fi
10930
10931
10932
10933ext_output="yes, shared"
10934ext_shared=yes
10935case $PHP_LITESPEED in
10936shared,*)
10937  PHP_LITESPEED=`echo "$PHP_LITESPEED"|$SED 's/^shared,//'`
10938  ;;
10939shared)
10940  PHP_LITESPEED=yes
10941  ;;
10942no)
10943  ext_output=no
10944  ext_shared=no
10945  ;;
10946*)
10947  ext_output=yes
10948  ext_shared=no
10949  ;;
10950esac
10951
10952
10953
10954
10955
10956
10957
10958
10959if test "$PHP_LITESPEED" != "no"; then
10960
10961  src=$abs_srcdir/sapi/litespeed/Makefile.frag
10962  ac_srcdir=$abs_srcdir/sapi/litespeed
10963  ac_builddir=sapi/litespeed
10964  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
10965
10966  SAPI_LITESPEED_PATH=sapi/litespeed/php
10967
10968  if test "program" = "program"; then
10969    PHP_BINARIES="$PHP_BINARIES litespeed"
10970  elif test "$PHP_SAPI" != "none"; then
10971    as_fn_error $? "
10972+--------------------------------------------------------------------+
10973|                        *** ATTENTION ***                           |
10974|                                                                    |
10975| You've configured multiple SAPIs to be built. You can build only   |
10976| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
10977+--------------------------------------------------------------------+
10978" "$LINENO" 5
10979  else
10980    PHP_SAPI=litespeed
10981  fi
10982
10983
10984
10985    BUILD_DIR="$BUILD_DIR sapi/litespeed"
10986
10987
10988
10989  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS litespeed"
10990
10991
10992
10993  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
10994  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
10995  php_c_post=
10996  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
10997  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
10998  php_cxx_post=
10999  php_lo=lo
11000
11001  case $with_pic in
11002    yes) pic_setting='-prefer-pic';;
11003    no)  pic_setting='-prefer-non-pic';;
11004  esac
11005
11006  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
11007  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
11008  shared_c_post=
11009  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
11010  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
11011  shared_cxx_post=
11012  shared_lo=lo
11013
11014    install_binaries="install-binaries"
11015    install_binary_targets="$install_binary_targets install-litespeed"
11016
11017  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_LITESPEED_OBJS"
11018
11019
11020  case sapi/litespeed in
11021  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
11022  /*) ac_srcdir=`echo "sapi/litespeed"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
11023  *) ac_srcdir="$abs_srcdir/sapi/litespeed/"; ac_bdir="sapi/litespeed/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
11024  esac
11025
11026
11027
11028  b_c_pre=$php_c_pre
11029  b_cxx_pre=$php_cxx_pre
11030  b_c_meta=$php_c_meta
11031  b_cxx_meta=$php_cxx_meta
11032  b_c_post=$php_c_post
11033  b_cxx_post=$php_cxx_post
11034  b_lo=$php_lo
11035
11036
11037  old_IFS=$IFS
11038  for ac_src in lsapi_main.c lsapilib.c; do
11039
11040      IFS=.
11041      set $ac_src
11042      ac_obj=$1
11043      IFS=$old_IFS
11044
11045      PHP_LITESPEED_OBJS="$PHP_LITESPEED_OBJS $ac_bdir$ac_obj.lo"
11046
11047      case $ac_src in
11048        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta "" -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11049        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta "" -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11050        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta "" -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11051        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta "" -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
11052      esac
11053
11054      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
11055
11056    cat >>Makefile.objects<<EOF
11057-include $ac_bdir$ac_obj.dep
11058$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
11059	$ac_comp
11060EOF
11061  done
11062
11063
11064
11065  case $host_alias in
11066  *darwin*)
11067    BUILD_LITESPEED="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)"
11068    ;;
11069  *cygwin*)
11070    SAPI_LITESPEED_PATH=sapi/litespeed/php.exe
11071    BUILD_LITESPEED="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_LITESPEED_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)"
11072    ;;
11073  *)
11074    BUILD_LITESPEED="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_LITESPEED_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_LITESPEED_PATH)"
11075    ;;
11076  esac
11077
11078
11079  PHP_VAR_SUBST="$PHP_VAR_SUBST SAPI_LITESPEED_PATH"
11080
11081
11082  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_LITESPEED"
11083
11084fi
11085
11086{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_LITESPEED" >&5
11087printf "%s\n" "$PHP_LITESPEED" >&6; }
11088
11089
11090
11091
11092
11093php_enable_phpdbg=yes
11094
11095{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phpdbg support" >&5
11096printf %s "checking for phpdbg support... " >&6; }
11097# Check whether --enable-phpdbg was given.
11098if test ${enable_phpdbg+y}
11099then :
11100  enableval=$enable_phpdbg; PHP_PHPDBG=$enableval
11101else $as_nop
11102
11103  PHP_PHPDBG=yes
11104  test "$PHP_ENABLE_ALL" && PHP_PHPDBG=$PHP_ENABLE_ALL
11105
11106fi
11107
11108
11109
11110ext_output="yes, shared"
11111ext_shared=yes
11112case $PHP_PHPDBG in
11113shared,*)
11114  PHP_PHPDBG=`echo "$PHP_PHPDBG"|$SED 's/^shared,//'`
11115  ;;
11116shared)
11117  PHP_PHPDBG=yes
11118  ;;
11119no)
11120  ext_output=no
11121  ext_shared=no
11122  ;;
11123*)
11124  ext_output=yes
11125  ext_shared=no
11126  ;;
11127esac
11128
11129
11130
11131{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
11132printf "%s\n" "$ext_output" >&6; }
11133
11134
11135
11136
11137
11138php_enable_phpdbg_debug=no
11139
11140{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phpdbg debug build" >&5
11141printf %s "checking for phpdbg debug build... " >&6; }
11142# Check whether --enable-phpdbg-debug was given.
11143if test ${enable_phpdbg_debug+y}
11144then :
11145  enableval=$enable_phpdbg_debug; PHP_PHPDBG_DEBUG=$enableval
11146else $as_nop
11147
11148  PHP_PHPDBG_DEBUG=no
11149
11150
11151fi
11152
11153
11154ext_output=$PHP_PHPDBG_DEBUG
11155{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
11156printf "%s\n" "$ext_output" >&6; }
11157
11158
11159
11160
11161
11162php_enable_phpdbg_readline=no
11163
11164{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phpdbg readline support" >&5
11165printf %s "checking for phpdbg readline support... " >&6; }
11166# Check whether --enable-phpdbg-readline was given.
11167if test ${enable_phpdbg_readline+y}
11168then :
11169  enableval=$enable_phpdbg_readline; PHP_PHPDBG_READLINE=$enableval
11170else $as_nop
11171
11172  PHP_PHPDBG_READLINE=no
11173
11174
11175fi
11176
11177
11178ext_output=$PHP_PHPDBG_READLINE
11179{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
11180printf "%s\n" "$ext_output" >&6; }
11181
11182
11183
11184
11185if test "$BUILD_PHPDBG" = "" && test "$PHP_PHPDBG" != "no"; then
11186  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether termios.h defines TIOCGWINSZ" >&5
11187printf %s "checking whether termios.h defines TIOCGWINSZ... " >&6; }
11188if test ${ac_cv_sys_tiocgwinsz_in_termios_h+y}
11189then :
11190  printf %s "(cached) " >&6
11191else $as_nop
11192  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11193/* end confdefs.h.  */
11194#include <sys/types.h>
11195#include <termios.h>
11196#ifdef TIOCGWINSZ
11197  yes
11198#endif
11199
11200_ACEOF
11201if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11202  $EGREP "yes" >/dev/null 2>&1
11203then :
11204  ac_cv_sys_tiocgwinsz_in_termios_h=yes
11205else $as_nop
11206  ac_cv_sys_tiocgwinsz_in_termios_h=no
11207fi
11208rm -rf conftest*
11209
11210fi
11211{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
11212printf "%s\n" "$ac_cv_sys_tiocgwinsz_in_termios_h" >&6; }
11213
11214if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
11215  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
11216printf %s "checking whether sys/ioctl.h defines TIOCGWINSZ... " >&6; }
11217if test ${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+y}
11218then :
11219  printf %s "(cached) " >&6
11220else $as_nop
11221  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11222/* end confdefs.h.  */
11223#include <sys/types.h>
11224#include <sys/ioctl.h>
11225#ifdef TIOCGWINSZ
11226  yes
11227#endif
11228
11229_ACEOF
11230if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11231  $EGREP "yes" >/dev/null 2>&1
11232then :
11233  ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
11234else $as_nop
11235  ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no
11236fi
11237rm -rf conftest*
11238
11239fi
11240{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
11241printf "%s\n" "$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6; }
11242
11243  if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
11244
11245printf "%s\n" "#define GWINSZ_IN_SYS_IOCTL 1" >>confdefs.h
11246
11247  fi
11248fi
11249
11250
11251printf "%s\n" "#define HAVE_PHPDBG 1" >>confdefs.h
11252
11253
11254  if test "$PHP_PHPDBG_DEBUG" != "no"; then
11255
11256printf "%s\n" "#define PHPDBG_DEBUG 1" >>confdefs.h
11257
11258  else
11259
11260printf "%s\n" "#define PHPDBG_DEBUG 0" >>confdefs.h
11261
11262  fi
11263
11264  PHP_PHPDBG_CFLAGS="-D_GNU_SOURCE -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
11265  PHP_PHPDBG_FILES="phpdbg.c phpdbg_parser.c phpdbg_lexer.c phpdbg_prompt.c phpdbg_help.c phpdbg_break.c phpdbg_print.c phpdbg_bp.c phpdbg_list.c phpdbg_utils.c phpdbg_info.c phpdbg_cmd.c phpdbg_set.c phpdbg_frame.c phpdbg_watch.c phpdbg_btree.c phpdbg_sigsafe.c phpdbg_io.c phpdbg_out.c"
11266
11267  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phpdbg and readline integration" >&5
11268printf %s "checking for phpdbg and readline integration... " >&6; }
11269  if test "$PHP_PHPDBG_READLINE" = "yes"; then
11270    if test "$PHP_READLINE" != "no" -o  "$PHP_LIBEDIT" != "no"; then
11271
11272printf "%s\n" "#define HAVE_PHPDBG_READLINE 1" >>confdefs.h
11273
11274  	  PHPDBG_EXTRA_LIBS="$PHP_READLINE_LIBS"
11275  	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
11276printf "%s\n" "ok" >&6; }
11277  	else
11278  	  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: readline is not available" >&5
11279printf "%s\n" "readline is not available" >&6; }
11280    fi
11281  else
11282    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: disabled" >&5
11283printf "%s\n" "disabled" >&6; }
11284  fi
11285
11286
11287  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PHPDBG_CFLAGS"
11288
11289
11290  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PHPDBG_FILES"
11291
11292
11293  PHP_VAR_SUBST="$PHP_VAR_SUBST PHPDBG_EXTRA_LIBS"
11294
11295
11296
11297  src=$abs_srcdir/sapi/phpdbg/Makefile.frag
11298  ac_srcdir=$abs_srcdir/sapi/phpdbg
11299  ac_builddir=$abs_builddir/sapi/phpdbg
11300  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
11301
11302
11303  if test "program" = "program"; then
11304    PHP_BINARIES="$PHP_BINARIES phpdbg"
11305  elif test "$PHP_SAPI" != "none"; then
11306    as_fn_error $? "
11307+--------------------------------------------------------------------+
11308|                        *** ATTENTION ***                           |
11309|                                                                    |
11310| You've configured multiple SAPIs to be built. You can build only   |
11311| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
11312+--------------------------------------------------------------------+
11313" "$LINENO" 5
11314  else
11315    PHP_SAPI=phpdbg
11316  fi
11317
11318
11319
11320    BUILD_DIR="$BUILD_DIR sapi/phpdbg"
11321
11322
11323
11324  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS phpdbg"
11325
11326
11327
11328  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
11329  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
11330  php_c_post=
11331  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
11332  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
11333  php_cxx_post=
11334  php_lo=lo
11335
11336  case $with_pic in
11337    yes) pic_setting='-prefer-pic';;
11338    no)  pic_setting='-prefer-non-pic';;
11339  esac
11340
11341  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
11342  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
11343  shared_c_post=
11344  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
11345  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
11346  shared_cxx_post=
11347  shared_lo=lo
11348
11349    install_binaries="install-binaries"
11350    install_binary_targets="$install_binary_targets install-phpdbg"
11351
11352  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PHPDBG_OBJS"
11353
11354
11355  case sapi/phpdbg in
11356  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
11357  /*) ac_srcdir=`echo "sapi/phpdbg"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
11358  *) ac_srcdir="$abs_srcdir/sapi/phpdbg/"; ac_bdir="sapi/phpdbg/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
11359  esac
11360
11361
11362
11363  b_c_pre=$php_c_pre
11364  b_cxx_pre=$php_cxx_pre
11365  b_c_meta=$php_c_meta
11366  b_cxx_meta=$php_cxx_meta
11367  b_c_post=$php_c_post
11368  b_cxx_post=$php_cxx_post
11369  b_lo=$php_lo
11370
11371
11372  old_IFS=$IFS
11373  for ac_src in $PHP_PHPDBG_FILES; do
11374
11375      IFS=.
11376      set $ac_src
11377      ac_obj=$1
11378      IFS=$old_IFS
11379
11380      PHP_PHPDBG_OBJS="$PHP_PHPDBG_OBJS $ac_bdir$ac_obj.lo"
11381
11382      case $ac_src in
11383        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_PHPDBG_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11384        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_PHPDBG_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11385        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_PHPDBG_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11386        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $PHP_PHPDBG_CFLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
11387      esac
11388
11389      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
11390
11391    cat >>Makefile.objects<<EOF
11392-include $ac_bdir$ac_obj.dep
11393$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
11394	$ac_comp
11395EOF
11396  done
11397
11398
11399
11400
11401  BUILD_BINARY="sapi/phpdbg/phpdbg"
11402  BUILD_SHARED="sapi/phpdbg/libphpdbg.la"
11403
11404  BUILD_PHPDBG="\$(LIBTOOL) --mode=link \
11405        \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \
11406                \$(PHP_GLOBAL_OBJS:.lo=.o) \
11407                \$(PHP_BINARY_OBJS:.lo=.o) \
11408                \$(PHP_PHPDBG_OBJS:.lo=.o) \
11409                \$(EXTRA_LIBS) \
11410                \$(PHPDBG_EXTRA_LIBS) \
11411                \$(ZEND_EXTRA_LIBS) \
11412                \$(PHP_FRAMEWORKS) \
11413         -o \$(BUILD_BINARY)"
11414
11415  BUILD_PHPDBG_SHARED="\$(LIBTOOL) --mode=link \
11416        \$(CC) -shared -Wl,-soname,libphpdbg.so -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \
11417                \$(PHP_GLOBAL_OBJS) \
11418                \$(PHP_BINARY_OBJS) \
11419                \$(PHP_PHPDBG_OBJS) \
11420                \$(EXTRA_LIBS) \
11421                \$(PHPDBG_EXTRA_LIBS) \
11422                \$(ZEND_EXTRA_LIBS) \
11423                \-DPHPDBG_SHARED \
11424         -o \$(BUILD_SHARED)"
11425
11426
11427  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_BINARY"
11428
11429
11430  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_SHARED"
11431
11432
11433  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_PHPDBG"
11434
11435
11436  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_PHPDBG_SHARED"
11437
11438
11439
11440  PHP_OUTPUT_FILES="$PHP_OUTPUT_FILES sapi/phpdbg/phpdbg.1"
11441
11442fi
11443
11444
11445
11446
11447
11448php_enable_cgi=yes
11449
11450
11451# Check whether --enable-cgi was given.
11452if test ${enable_cgi+y}
11453then :
11454  enableval=$enable_cgi; PHP_CGI=$enableval
11455else $as_nop
11456
11457  PHP_CGI=yes
11458
11459
11460fi
11461
11462
11463ext_output=$PHP_CGI
11464
11465
11466
11467
11468
11469{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CGI build" >&5
11470printf %s "checking for CGI build... " >&6; }
11471if test "$PHP_CGI" != "no"; then
11472    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11473printf "%s\n" "yes" >&6; }
11474
11475    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sun_len in sys/un.h" >&5
11476printf %s "checking for sun_len in sys/un.h... " >&6; }
11477    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11478/* end confdefs.h.  */
11479#include <sys/un.h>
11480
11481_ACEOF
11482if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11483  $EGREP "sun_len" >/dev/null 2>&1
11484then :
11485  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11486printf "%s\n" "yes" >&6; }
11487
11488printf "%s\n" "#define HAVE_SOCKADDR_UN_SUN_LEN 1" >>confdefs.h
11489
11490else $as_nop
11491  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11492printf "%s\n" "no" >&6; }
11493fi
11494rm -rf conftest*
11495
11496
11497    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether cross-process locking is required by accept()" >&5
11498printf %s "checking whether cross-process locking is required by accept()... " >&6; }
11499    case "`uname -sr`" in
11500      IRIX\ 5.* | SunOS\ 5.* | UNIX_System_V\ 4.0)
11501        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11502printf "%s\n" "yes" >&6; }
11503
11504printf "%s\n" "#define USE_LOCKING 1" >>confdefs.h
11505
11506      ;;
11507      *)
11508        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11509printf "%s\n" "no" >&6; }
11510      ;;
11511    esac
11512
11513
11514  src=$abs_srcdir/sapi/cgi/Makefile.frag
11515  ac_srcdir=$ext_srcdir
11516  ac_builddir=$ext_builddir
11517  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
11518
11519
11520        case $host_alias in
11521      *cygwin* )
11522        SAPI_CGI_PATH=sapi/cgi/php-cgi.exe
11523        ;;
11524      * )
11525        SAPI_CGI_PATH=sapi/cgi/php-cgi
11526        ;;
11527    esac
11528
11529
11530  if test "program" = "program"; then
11531    PHP_BINARIES="$PHP_BINARIES cgi"
11532  elif test "$PHP_SAPI" != "none"; then
11533    as_fn_error $? "
11534+--------------------------------------------------------------------+
11535|                        *** ATTENTION ***                           |
11536|                                                                    |
11537| You've configured multiple SAPIs to be built. You can build only   |
11538| one SAPI module plus CGI, CLI and FPM binaries at the same time.   |
11539+--------------------------------------------------------------------+
11540" "$LINENO" 5
11541  else
11542    PHP_SAPI=cgi
11543  fi
11544
11545
11546
11547    BUILD_DIR="$BUILD_DIR sapi/cgi"
11548
11549
11550
11551  PHP_INSTALLED_SAPIS="$PHP_INSTALLED_SAPIS cgi"
11552
11553
11554
11555  php_c_pre='$(LIBTOOL) --mode=compile $(CC)'
11556  php_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS)'
11557  php_c_post=
11558  php_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
11559  php_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS)'
11560  php_cxx_post=
11561  php_lo=lo
11562
11563  case $with_pic in
11564    yes) pic_setting='-prefer-pic';;
11565    no)  pic_setting='-prefer-non-pic';;
11566  esac
11567
11568  shared_c_pre='$(LIBTOOL) --mode=compile $(CC)'
11569  shared_c_meta='$(COMMON_FLAGS) $(CFLAGS_CLEAN) $(EXTRA_CFLAGS) '$pic_setting
11570  shared_c_post=
11571  shared_cxx_pre='$(LIBTOOL) --mode=compile $(CXX)'
11572  shared_cxx_meta='$(COMMON_FLAGS) $(CXXFLAGS_CLEAN) $(EXTRA_CXXFLAGS) '$pic_setting
11573  shared_cxx_post=
11574  shared_lo=lo
11575
11576    install_binaries="install-binaries"
11577    install_binary_targets="$install_binary_targets install-cgi"
11578
11579  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_CGI_OBJS"
11580
11581
11582  case sapi/cgi in
11583  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
11584  /*) ac_srcdir=`echo "sapi/cgi"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
11585  *) ac_srcdir="$abs_srcdir/sapi/cgi/"; ac_bdir="sapi/cgi/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
11586  esac
11587
11588
11589
11590  b_c_pre=$php_c_pre
11591  b_cxx_pre=$php_cxx_pre
11592  b_c_meta=$php_c_meta
11593  b_cxx_meta=$php_cxx_meta
11594  b_c_post=$php_c_post
11595  b_cxx_post=$php_cxx_post
11596  b_lo=$php_lo
11597
11598
11599  old_IFS=$IFS
11600  for ac_src in cgi_main.c; do
11601
11602      IFS=.
11603      set $ac_src
11604      ac_obj=$1
11605      IFS=$old_IFS
11606
11607      PHP_CGI_OBJS="$PHP_CGI_OBJS $ac_bdir$ac_obj.lo"
11608
11609      case $ac_src in
11610        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11611        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11612        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
11613        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
11614      esac
11615
11616      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
11617
11618    cat >>Makefile.objects<<EOF
11619-include $ac_bdir$ac_obj.dep
11620$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
11621	$ac_comp
11622EOF
11623  done
11624
11625
11626
11627
11628    case $host_alias in
11629      *aix*)
11630        if test "$php_sapi_module" = "shared"; then
11631          BUILD_CGI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CGI_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/.libs\/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FASTCGI_OBJS) \$(PHP_CGI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)"
11632        else
11633          BUILD_CGI="echo '\#! .' > php.sym && echo >>php.sym && nm -BCpg \`echo \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_CGI_OBJS) | sed 's/\([A-Za-z0-9_]*\)\.lo/\1.o/g'\` | \$(AWK) '{ if (((\$\$2 == \"T\") || (\$\$2 == \"D\") || (\$\$2 == \"B\")) && (substr(\$\$3,1,1) != \".\")) { print \$\$3 } }' | sort -u >> php.sym && \$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) -Wl,-brtl -Wl,-bE:php.sym \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS) \$(PHP_BINARY_OBJS) \$(PHP_FASTCGI_OBJS) \$(PHP_CGI_OBJS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)"
11634        fi
11635        ;;
11636      *darwin*)
11637        BUILD_CGI="\$(CC) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(NATIVE_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(PHP_FRAMEWORKS) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)"
11638      ;;
11639      *)
11640        BUILD_CGI="\$(LIBTOOL) --mode=link \$(CC) -export-dynamic \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(EXTRA_LDFLAGS_PROGRAM) \$(LDFLAGS) \$(PHP_RPATHS) \$(PHP_GLOBAL_OBJS:.lo=.o) \$(PHP_BINARY_OBJS:.lo=.o) \$(PHP_FASTCGI_OBJS:.lo=.o) \$(PHP_CGI_OBJS:.lo=.o) \$(EXTRA_LIBS) \$(ZEND_EXTRA_LIBS) -o \$(SAPI_CGI_PATH)"
11641      ;;
11642    esac
11643
11644
11645  PHP_VAR_SUBST="$PHP_VAR_SUBST SAPI_CGI_PATH"
11646
11647
11648  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_CGI"
11649
11650
11651
11652  PHP_OUTPUT_FILES="$PHP_OUTPUT_FILES sapi/cgi/php-cgi.1"
11653
11654else
11655  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11656printf "%s\n" "no" >&6; }
11657fi
11658
11659
11660
11661{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for chosen SAPI module" >&5
11662printf %s "checking for chosen SAPI module... " >&6; }
11663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_SAPI" >&5
11664printf "%s\n" "$PHP_SAPI" >&6; }
11665
11666{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for executable SAPI binaries" >&5
11667printf %s "checking for executable SAPI binaries... " >&6; }
11668if test "$PHP_BINARIES"; then
11669  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_BINARIES" >&5
11670printf "%s\n" "$PHP_BINARIES" >&6; }
11671else
11672  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
11673printf "%s\n" "none" >&6; }
11674fi
11675
11676if test -z "$PHP_INSTALLED_SAPIS"; then
11677  as_fn_error $? "Nothing to build." "$LINENO" 5
11678fi
11679
11680if test "$enable_zts" = "yes"; then
11681    if test -n "$ac_cv_pthreads_lib"; then
11682    LIBS="$LIBS -l$ac_cv_pthreads_lib"
11683  fi
11684  if test -n "$ac_cv_pthreads_cflags"; then
11685    CFLAGS="$CFLAGS $ac_cv_pthreads_cflags"
11686  fi
11687
11688
11689  if test -z "$host_alias" && test -n "$host"; then
11690    host_alias=$host
11691  fi
11692  if test -z "$host_alias"; then
11693    as_fn_error $? "host_alias is not set. Make sure to run config.guess" "$LINENO" 5
11694  fi
11695  case $host_alias in
11696  *solaris*)
11697    PTHREAD_FLAGS="-D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT";;
11698  *freebsd*)
11699    PTHREAD_FLAGS="-D_REENTRANT -D_THREAD_SAFE";;
11700  *linux*)
11701    PTHREAD_FLAGS=-D_REENTRANT;;
11702  *aix*)
11703    PTHREAD_FLAGS=-D_THREAD_SAFE;;
11704  *irix*)
11705    PTHREAD_FLAGS=-D_POSIX_THREAD_SAFE_FUNCTIONS;;
11706  *hpux*)
11707    PTHREAD_FLAGS=-D_REENTRANT;;
11708  *sco*)
11709    PTHREAD_FLAGS=-D_REENTRANT;;
11710  esac
11711
11712  if test -n "$PTHREAD_FLAGS"; then
11713    CPPFLAGS="$CPPFLAGS $PTHREAD_FLAGS"
11714  fi
11715
11716fi
11717
11718
11719
11720  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
11721printf "%s\n" "" >&6; }
11722  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Running system checks${T_ME}" >&5
11723printf "%s\n" "${T_MD}Running system checks${T_ME}" >&6; }
11724
11725
11726
11727  PHP_ALT_PATH=/usr/bin:/usr/sbin:/usr/etc:/etc:/usr/ucblib:/usr/lib
11728  # Extract the first word of "sendmail", so it can be a program name with args.
11729set dummy sendmail; ac_word=$2
11730{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11731printf %s "checking for $ac_word... " >&6; }
11732if test ${ac_cv_path_PROG_SENDMAIL+y}
11733then :
11734  printf %s "(cached) " >&6
11735else $as_nop
11736  case $PROG_SENDMAIL in
11737  [\\/]* | ?:[\\/]*)
11738  ac_cv_path_PROG_SENDMAIL="$PROG_SENDMAIL" # Let the user override the test with a path.
11739  ;;
11740  *)
11741  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11742as_dummy="$PATH:$PHP_ALT_PATH"
11743for as_dir in $as_dummy
11744do
11745  IFS=$as_save_IFS
11746  case $as_dir in #(((
11747    '') as_dir=./ ;;
11748    */) ;;
11749    *) as_dir=$as_dir/ ;;
11750  esac
11751    for ac_exec_ext in '' $ac_executable_extensions; do
11752  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11753    ac_cv_path_PROG_SENDMAIL="$as_dir$ac_word$ac_exec_ext"
11754    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
11755    break 2
11756  fi
11757done
11758  done
11759IFS=$as_save_IFS
11760
11761  test -z "$ac_cv_path_PROG_SENDMAIL" && ac_cv_path_PROG_SENDMAIL="/usr/sbin/sendmail"
11762  ;;
11763esac
11764fi
11765PROG_SENDMAIL=$ac_cv_path_PROG_SENDMAIL
11766if test -n "$PROG_SENDMAIL"; then
11767  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PROG_SENDMAIL" >&5
11768printf "%s\n" "$PROG_SENDMAIL" >&6; }
11769else
11770  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11771printf "%s\n" "no" >&6; }
11772fi
11773
11774
11775
11776  PHP_VAR_SUBST="$PHP_VAR_SUBST PROG_SENDMAIL"
11777
11778
11779
11780
11781  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether system uses EBCDIC" >&5
11782printf %s "checking whether system uses EBCDIC... " >&6; }
11783if test ${ac_cv_ebcdic+y}
11784then :
11785  printf %s "(cached) " >&6
11786else $as_nop
11787
11788  if test "$cross_compiling" = yes
11789then :
11790
11791  ac_cv_ebcdic=no
11792
11793else $as_nop
11794  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11795/* end confdefs.h.  */
11796
11797int main(void) {
11798  return (unsigned char)'A' != (unsigned char)0xC1;
11799}
11800
11801_ACEOF
11802if ac_fn_c_try_run "$LINENO"
11803then :
11804
11805  ac_cv_ebcdic=yes
11806
11807else $as_nop
11808
11809  ac_cv_ebcdic=no
11810
11811fi
11812rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11813  conftest.$ac_objext conftest.beam conftest.$ac_ext
11814fi
11815
11816fi
11817{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ebcdic" >&5
11818printf "%s\n" "$ac_cv_ebcdic" >&6; }
11819  if test "$ac_cv_ebcdic" = "yes"; then
11820    as_fn_error $? "PHP does not support EBCDIC targets" "$LINENO" 5
11821  fi
11822
11823
11824{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
11825printf %s "checking whether byte ordering is bigendian... " >&6; }
11826if test ${ac_cv_c_bigendian_php+y}
11827then :
11828  printf %s "(cached) " >&6
11829else $as_nop
11830
11831  ac_cv_c_bigendian_php=unknown
11832  if test "$cross_compiling" = yes
11833then :
11834  ac_cv_c_bigendian_php=unknown
11835else $as_nop
11836  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11837/* end confdefs.h.  */
11838
11839int main(void)
11840{
11841  short one = 1;
11842  char *cp = (char *)&one;
11843
11844  if (*cp == 0) {
11845    return(0);
11846  } else {
11847    return(1);
11848  }
11849}
11850
11851_ACEOF
11852if ac_fn_c_try_run "$LINENO"
11853then :
11854  ac_cv_c_bigendian_php=yes
11855else $as_nop
11856  ac_cv_c_bigendian_php=no
11857fi
11858rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11859  conftest.$ac_objext conftest.beam conftest.$ac_ext
11860fi
11861
11862
11863fi
11864{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian_php" >&5
11865printf "%s\n" "$ac_cv_c_bigendian_php" >&6; }
11866 if test $ac_cv_c_bigendian_php = yes; then
11867
11868printf "%s\n" "#define WORDS_BIGENDIAN /**/" >>confdefs.h
11869
11870 fi
11871
11872
11873
11874  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether writing to stdout works" >&5
11875printf %s "checking whether writing to stdout works... " >&6; }
11876if test ${ac_cv_write_stdout+y}
11877then :
11878  printf %s "(cached) " >&6
11879else $as_nop
11880
11881    if test "$cross_compiling" = yes
11882then :
11883
11884      case $host_alias in
11885        *linux*)
11886          ac_cv_write_stdout=yes
11887          ;;
11888        *)
11889          ac_cv_write_stdout=no
11890          ;;
11891      esac
11892
11893else $as_nop
11894  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11895/* end confdefs.h.  */
11896
11897#ifdef HAVE_UNISTD_H
11898#include <unistd.h>
11899#endif
11900
11901#define TEXT "This is the test message -- "
11902
11903int main()
11904{
11905  int n;
11906
11907  n = write(1, TEXT, sizeof(TEXT)-1);
11908  return (!(n == sizeof(TEXT)-1));
11909}
11910
11911_ACEOF
11912if ac_fn_c_try_run "$LINENO"
11913then :
11914
11915      ac_cv_write_stdout=yes
11916
11917else $as_nop
11918
11919      ac_cv_write_stdout=no
11920
11921fi
11922rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11923  conftest.$ac_objext conftest.beam conftest.$ac_ext
11924fi
11925
11926
11927fi
11928{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_write_stdout" >&5
11929printf "%s\n" "$ac_cv_write_stdout" >&6; }
11930  if test "$ac_cv_write_stdout" = "yes"; then
11931
11932printf "%s\n" "#define PHP_WRITE_STDOUT 1" >>confdefs.h
11933
11934  fi
11935
11936
11937if test -d /usr/pkg/include -a -d /usr/pkg/lib ; then
11938   CPPFLAGS="$CPPFLAGS -I/usr/pkg/include"
11939   LDFLAGS="$LDFLAGS -L/usr/pkg/lib"
11940fi
11941test -d /usr/ucblib &&
11942  if test "/usr/ucblib" != "/usr/$PHP_LIBDIR" && test "/usr/ucblib" != "/usr/lib"; then
11943
11944  if test -z "/usr/ucblib" || echo "/usr/ucblib" | grep '^/' >/dev/null ; then
11945    ai_p=/usr/ucblib
11946  else
11947
11948    ep_dir=`echo /usr/ucblib|$SED 's%/*[^/][^/]*/*$%%'`
11949
11950    ep_realdir=`(cd "$ep_dir" && pwd)`
11951    ai_p="$ep_realdir"/`basename "/usr/ucblib"`
11952  fi
11953
11954
11955
11956
11957
11958  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
11959
11960  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
11961  if test -n "$unique" && test "`eval $cmd`" = "" ; then
11962    eval "LIBPATH$unique=set"
11963
11964    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
11965    LDFLAGS="$LDFLAGS -L$ai_p"
11966    PHP_RPATHS="$PHP_RPATHS $ai_p"
11967
11968  fi
11969
11970
11971
11972  fi
11973
11974
11975
11976
11977
11978  unset ac_cv_func_socket
11979  unset ac_cv_func___socket
11980  unset found
11981
11982  ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
11983if test "x$ac_cv_func_socket" = xyes
11984then :
11985  found=yes
11986else $as_nop
11987   ac_fn_c_check_func "$LINENO" "__socket" "ac_cv_func___socket"
11988if test "x$ac_cv_func___socket" = xyes
11989then :
11990  found=yes
11991else $as_nop
11992  found=no
11993fi
11994
11995fi
11996
11997
11998  case $found in
11999  yes)
12000
12001printf "%s\n" "#define HAVE_SOCKET 1" >>confdefs.h
12002
12003    ac_cv_func_socket=yes
12004  ;;
12005
12006    *)
12007
12008  unset ac_cv_lib_socket_socket
12009  unset ac_cv_lib_socket___socket
12010  unset found
12011  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
12012printf %s "checking for socket in -lsocket... " >&6; }
12013if test ${ac_cv_lib_socket_socket+y}
12014then :
12015  printf %s "(cached) " >&6
12016else $as_nop
12017  ac_check_lib_save_LIBS=$LIBS
12018LIBS="-lsocket  $LIBS"
12019cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12020/* end confdefs.h.  */
12021
12022/* Override any GCC internal prototype to avoid an error.
12023   Use char because int might match the return type of a GCC
12024   builtin and then its argument prototype would still apply.  */
12025char socket ();
12026int
12027main (void)
12028{
12029return socket ();
12030  ;
12031  return 0;
12032}
12033_ACEOF
12034if ac_fn_c_try_link "$LINENO"
12035then :
12036  ac_cv_lib_socket_socket=yes
12037else $as_nop
12038  ac_cv_lib_socket_socket=no
12039fi
12040rm -f core conftest.err conftest.$ac_objext conftest.beam \
12041    conftest$ac_exeext conftest.$ac_ext
12042LIBS=$ac_check_lib_save_LIBS
12043fi
12044{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
12045printf "%s\n" "$ac_cv_lib_socket_socket" >&6; }
12046if test "x$ac_cv_lib_socket_socket" = xyes
12047then :
12048  found=yes
12049else $as_nop
12050
12051    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __socket in -lsocket" >&5
12052printf %s "checking for __socket in -lsocket... " >&6; }
12053if test ${ac_cv_lib_socket___socket+y}
12054then :
12055  printf %s "(cached) " >&6
12056else $as_nop
12057  ac_check_lib_save_LIBS=$LIBS
12058LIBS="-lsocket  $LIBS"
12059cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12060/* end confdefs.h.  */
12061
12062/* Override any GCC internal prototype to avoid an error.
12063   Use char because int might match the return type of a GCC
12064   builtin and then its argument prototype would still apply.  */
12065char __socket ();
12066int
12067main (void)
12068{
12069return __socket ();
12070  ;
12071  return 0;
12072}
12073_ACEOF
12074if ac_fn_c_try_link "$LINENO"
12075then :
12076  ac_cv_lib_socket___socket=yes
12077else $as_nop
12078  ac_cv_lib_socket___socket=no
12079fi
12080rm -f core conftest.err conftest.$ac_objext conftest.beam \
12081    conftest$ac_exeext conftest.$ac_ext
12082LIBS=$ac_check_lib_save_LIBS
12083fi
12084{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___socket" >&5
12085printf "%s\n" "$ac_cv_lib_socket___socket" >&6; }
12086if test "x$ac_cv_lib_socket___socket" = xyes
12087then :
12088  found=yes
12089else $as_nop
12090  found=no
12091fi
12092
12093
12094fi
12095
12096
12097  if test "$found" = "yes"; then
12098    ac_libs=$LIBS
12099    LIBS="$LIBS -lsocket"
12100    if test "$cross_compiling" = yes
12101then :
12102
12103            found=yes
12104
12105else $as_nop
12106  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12107/* end confdefs.h.  */
12108int main() { return (0); }
12109_ACEOF
12110if ac_fn_c_try_run "$LINENO"
12111then :
12112  found=yes
12113else $as_nop
12114  found=no
12115fi
12116rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12117  conftest.$ac_objext conftest.beam conftest.$ac_ext
12118fi
12119
12120    LIBS=$ac_libs
12121  fi
12122
12123  if test "$found" = "yes"; then
12124
12125
12126  case socket in
12127  c|c_r) ;;
12128  *)
12129      LIBS="-lsocket $LIBS"
12130   ;;
12131  esac
12132
12133
12134
12135printf "%s\n" "#define HAVE_SOCKET 1" >>confdefs.h
12136
12137
12138printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
12139
12140    ac_cv_func_socket=yes
12141  else
12142
12143
12144  unset ac_cv_lib_network_socket
12145  unset ac_cv_lib_network___socket
12146  unset found
12147  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lnetwork" >&5
12148printf %s "checking for socket in -lnetwork... " >&6; }
12149if test ${ac_cv_lib_network_socket+y}
12150then :
12151  printf %s "(cached) " >&6
12152else $as_nop
12153  ac_check_lib_save_LIBS=$LIBS
12154LIBS="-lnetwork  $LIBS"
12155cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12156/* end confdefs.h.  */
12157
12158/* Override any GCC internal prototype to avoid an error.
12159   Use char because int might match the return type of a GCC
12160   builtin and then its argument prototype would still apply.  */
12161char socket ();
12162int
12163main (void)
12164{
12165return socket ();
12166  ;
12167  return 0;
12168}
12169_ACEOF
12170if ac_fn_c_try_link "$LINENO"
12171then :
12172  ac_cv_lib_network_socket=yes
12173else $as_nop
12174  ac_cv_lib_network_socket=no
12175fi
12176rm -f core conftest.err conftest.$ac_objext conftest.beam \
12177    conftest$ac_exeext conftest.$ac_ext
12178LIBS=$ac_check_lib_save_LIBS
12179fi
12180{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_socket" >&5
12181printf "%s\n" "$ac_cv_lib_network_socket" >&6; }
12182if test "x$ac_cv_lib_network_socket" = xyes
12183then :
12184  found=yes
12185else $as_nop
12186
12187    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __socket in -lnetwork" >&5
12188printf %s "checking for __socket in -lnetwork... " >&6; }
12189if test ${ac_cv_lib_network___socket+y}
12190then :
12191  printf %s "(cached) " >&6
12192else $as_nop
12193  ac_check_lib_save_LIBS=$LIBS
12194LIBS="-lnetwork  $LIBS"
12195cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12196/* end confdefs.h.  */
12197
12198/* Override any GCC internal prototype to avoid an error.
12199   Use char because int might match the return type of a GCC
12200   builtin and then its argument prototype would still apply.  */
12201char __socket ();
12202int
12203main (void)
12204{
12205return __socket ();
12206  ;
12207  return 0;
12208}
12209_ACEOF
12210if ac_fn_c_try_link "$LINENO"
12211then :
12212  ac_cv_lib_network___socket=yes
12213else $as_nop
12214  ac_cv_lib_network___socket=no
12215fi
12216rm -f core conftest.err conftest.$ac_objext conftest.beam \
12217    conftest$ac_exeext conftest.$ac_ext
12218LIBS=$ac_check_lib_save_LIBS
12219fi
12220{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___socket" >&5
12221printf "%s\n" "$ac_cv_lib_network___socket" >&6; }
12222if test "x$ac_cv_lib_network___socket" = xyes
12223then :
12224  found=yes
12225else $as_nop
12226  found=no
12227fi
12228
12229
12230fi
12231
12232
12233  if test "$found" = "yes"; then
12234    ac_libs=$LIBS
12235    LIBS="$LIBS -lnetwork"
12236    if test "$cross_compiling" = yes
12237then :
12238
12239            found=yes
12240
12241else $as_nop
12242  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12243/* end confdefs.h.  */
12244int main() { return (0); }
12245_ACEOF
12246if ac_fn_c_try_run "$LINENO"
12247then :
12248  found=yes
12249else $as_nop
12250  found=no
12251fi
12252rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12253  conftest.$ac_objext conftest.beam conftest.$ac_ext
12254fi
12255
12256    LIBS=$ac_libs
12257  fi
12258
12259  if test "$found" = "yes"; then
12260
12261
12262  case network in
12263  c|c_r) ;;
12264  *)
12265      LIBS="-lnetwork $LIBS"
12266   ;;
12267  esac
12268
12269
12270
12271printf "%s\n" "#define HAVE_SOCKET 1" >>confdefs.h
12272
12273
12274printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
12275
12276    ac_cv_func_socket=yes
12277  else
12278
12279  :
12280
12281  fi
12282
12283
12284  fi
12285
12286 ;;
12287
12288  esac
12289
12290
12291  unset ac_cv_func_socketpair
12292  unset ac_cv_func___socketpair
12293  unset found
12294
12295  ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair"
12296if test "x$ac_cv_func_socketpair" = xyes
12297then :
12298  found=yes
12299else $as_nop
12300   ac_fn_c_check_func "$LINENO" "__socketpair" "ac_cv_func___socketpair"
12301if test "x$ac_cv_func___socketpair" = xyes
12302then :
12303  found=yes
12304else $as_nop
12305  found=no
12306fi
12307
12308fi
12309
12310
12311  case $found in
12312  yes)
12313
12314printf "%s\n" "#define HAVE_SOCKETPAIR 1" >>confdefs.h
12315
12316    ac_cv_func_socketpair=yes
12317  ;;
12318
12319    *)
12320
12321  unset ac_cv_lib_socket_socketpair
12322  unset ac_cv_lib_socket___socketpair
12323  unset found
12324  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socketpair in -lsocket" >&5
12325printf %s "checking for socketpair in -lsocket... " >&6; }
12326if test ${ac_cv_lib_socket_socketpair+y}
12327then :
12328  printf %s "(cached) " >&6
12329else $as_nop
12330  ac_check_lib_save_LIBS=$LIBS
12331LIBS="-lsocket  $LIBS"
12332cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12333/* end confdefs.h.  */
12334
12335/* Override any GCC internal prototype to avoid an error.
12336   Use char because int might match the return type of a GCC
12337   builtin and then its argument prototype would still apply.  */
12338char socketpair ();
12339int
12340main (void)
12341{
12342return socketpair ();
12343  ;
12344  return 0;
12345}
12346_ACEOF
12347if ac_fn_c_try_link "$LINENO"
12348then :
12349  ac_cv_lib_socket_socketpair=yes
12350else $as_nop
12351  ac_cv_lib_socket_socketpair=no
12352fi
12353rm -f core conftest.err conftest.$ac_objext conftest.beam \
12354    conftest$ac_exeext conftest.$ac_ext
12355LIBS=$ac_check_lib_save_LIBS
12356fi
12357{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socketpair" >&5
12358printf "%s\n" "$ac_cv_lib_socket_socketpair" >&6; }
12359if test "x$ac_cv_lib_socket_socketpair" = xyes
12360then :
12361  found=yes
12362else $as_nop
12363
12364    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __socketpair in -lsocket" >&5
12365printf %s "checking for __socketpair in -lsocket... " >&6; }
12366if test ${ac_cv_lib_socket___socketpair+y}
12367then :
12368  printf %s "(cached) " >&6
12369else $as_nop
12370  ac_check_lib_save_LIBS=$LIBS
12371LIBS="-lsocket  $LIBS"
12372cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12373/* end confdefs.h.  */
12374
12375/* Override any GCC internal prototype to avoid an error.
12376   Use char because int might match the return type of a GCC
12377   builtin and then its argument prototype would still apply.  */
12378char __socketpair ();
12379int
12380main (void)
12381{
12382return __socketpair ();
12383  ;
12384  return 0;
12385}
12386_ACEOF
12387if ac_fn_c_try_link "$LINENO"
12388then :
12389  ac_cv_lib_socket___socketpair=yes
12390else $as_nop
12391  ac_cv_lib_socket___socketpair=no
12392fi
12393rm -f core conftest.err conftest.$ac_objext conftest.beam \
12394    conftest$ac_exeext conftest.$ac_ext
12395LIBS=$ac_check_lib_save_LIBS
12396fi
12397{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___socketpair" >&5
12398printf "%s\n" "$ac_cv_lib_socket___socketpair" >&6; }
12399if test "x$ac_cv_lib_socket___socketpair" = xyes
12400then :
12401  found=yes
12402else $as_nop
12403  found=no
12404fi
12405
12406
12407fi
12408
12409
12410  if test "$found" = "yes"; then
12411    ac_libs=$LIBS
12412    LIBS="$LIBS -lsocket"
12413    if test "$cross_compiling" = yes
12414then :
12415
12416            found=yes
12417
12418else $as_nop
12419  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12420/* end confdefs.h.  */
12421int main() { return (0); }
12422_ACEOF
12423if ac_fn_c_try_run "$LINENO"
12424then :
12425  found=yes
12426else $as_nop
12427  found=no
12428fi
12429rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12430  conftest.$ac_objext conftest.beam conftest.$ac_ext
12431fi
12432
12433    LIBS=$ac_libs
12434  fi
12435
12436  if test "$found" = "yes"; then
12437
12438
12439  case socket in
12440  c|c_r) ;;
12441  *)
12442      LIBS="-lsocket $LIBS"
12443   ;;
12444  esac
12445
12446
12447
12448printf "%s\n" "#define HAVE_SOCKETPAIR 1" >>confdefs.h
12449
12450
12451printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
12452
12453    ac_cv_func_socketpair=yes
12454  else
12455
12456
12457  unset ac_cv_lib_network_socketpair
12458  unset ac_cv_lib_network___socketpair
12459  unset found
12460  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socketpair in -lnetwork" >&5
12461printf %s "checking for socketpair in -lnetwork... " >&6; }
12462if test ${ac_cv_lib_network_socketpair+y}
12463then :
12464  printf %s "(cached) " >&6
12465else $as_nop
12466  ac_check_lib_save_LIBS=$LIBS
12467LIBS="-lnetwork  $LIBS"
12468cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12469/* end confdefs.h.  */
12470
12471/* Override any GCC internal prototype to avoid an error.
12472   Use char because int might match the return type of a GCC
12473   builtin and then its argument prototype would still apply.  */
12474char socketpair ();
12475int
12476main (void)
12477{
12478return socketpair ();
12479  ;
12480  return 0;
12481}
12482_ACEOF
12483if ac_fn_c_try_link "$LINENO"
12484then :
12485  ac_cv_lib_network_socketpair=yes
12486else $as_nop
12487  ac_cv_lib_network_socketpair=no
12488fi
12489rm -f core conftest.err conftest.$ac_objext conftest.beam \
12490    conftest$ac_exeext conftest.$ac_ext
12491LIBS=$ac_check_lib_save_LIBS
12492fi
12493{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_socketpair" >&5
12494printf "%s\n" "$ac_cv_lib_network_socketpair" >&6; }
12495if test "x$ac_cv_lib_network_socketpair" = xyes
12496then :
12497  found=yes
12498else $as_nop
12499
12500    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __socketpair in -lnetwork" >&5
12501printf %s "checking for __socketpair in -lnetwork... " >&6; }
12502if test ${ac_cv_lib_network___socketpair+y}
12503then :
12504  printf %s "(cached) " >&6
12505else $as_nop
12506  ac_check_lib_save_LIBS=$LIBS
12507LIBS="-lnetwork  $LIBS"
12508cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12509/* end confdefs.h.  */
12510
12511/* Override any GCC internal prototype to avoid an error.
12512   Use char because int might match the return type of a GCC
12513   builtin and then its argument prototype would still apply.  */
12514char __socketpair ();
12515int
12516main (void)
12517{
12518return __socketpair ();
12519  ;
12520  return 0;
12521}
12522_ACEOF
12523if ac_fn_c_try_link "$LINENO"
12524then :
12525  ac_cv_lib_network___socketpair=yes
12526else $as_nop
12527  ac_cv_lib_network___socketpair=no
12528fi
12529rm -f core conftest.err conftest.$ac_objext conftest.beam \
12530    conftest$ac_exeext conftest.$ac_ext
12531LIBS=$ac_check_lib_save_LIBS
12532fi
12533{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___socketpair" >&5
12534printf "%s\n" "$ac_cv_lib_network___socketpair" >&6; }
12535if test "x$ac_cv_lib_network___socketpair" = xyes
12536then :
12537  found=yes
12538else $as_nop
12539  found=no
12540fi
12541
12542
12543fi
12544
12545
12546  if test "$found" = "yes"; then
12547    ac_libs=$LIBS
12548    LIBS="$LIBS -lnetwork"
12549    if test "$cross_compiling" = yes
12550then :
12551
12552            found=yes
12553
12554else $as_nop
12555  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12556/* end confdefs.h.  */
12557int main() { return (0); }
12558_ACEOF
12559if ac_fn_c_try_run "$LINENO"
12560then :
12561  found=yes
12562else $as_nop
12563  found=no
12564fi
12565rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12566  conftest.$ac_objext conftest.beam conftest.$ac_ext
12567fi
12568
12569    LIBS=$ac_libs
12570  fi
12571
12572  if test "$found" = "yes"; then
12573
12574
12575  case network in
12576  c|c_r) ;;
12577  *)
12578      LIBS="-lnetwork $LIBS"
12579   ;;
12580  esac
12581
12582
12583
12584printf "%s\n" "#define HAVE_SOCKETPAIR 1" >>confdefs.h
12585
12586
12587printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
12588
12589    ac_cv_func_socketpair=yes
12590  else
12591
12592  :
12593
12594  fi
12595
12596
12597  fi
12598
12599 ;;
12600
12601  esac
12602
12603
12604  unset ac_cv_func_htonl
12605  unset ac_cv_func___htonl
12606  unset found
12607
12608  ac_fn_c_check_func "$LINENO" "htonl" "ac_cv_func_htonl"
12609if test "x$ac_cv_func_htonl" = xyes
12610then :
12611  found=yes
12612else $as_nop
12613   ac_fn_c_check_func "$LINENO" "__htonl" "ac_cv_func___htonl"
12614if test "x$ac_cv_func___htonl" = xyes
12615then :
12616  found=yes
12617else $as_nop
12618  found=no
12619fi
12620
12621fi
12622
12623
12624  case $found in
12625  yes)
12626
12627printf "%s\n" "#define HAVE_HTONL 1" >>confdefs.h
12628
12629    ac_cv_func_htonl=yes
12630  ;;
12631
12632    *)
12633
12634  unset ac_cv_lib_socket_htonl
12635  unset ac_cv_lib_socket___htonl
12636  unset found
12637  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for htonl in -lsocket" >&5
12638printf %s "checking for htonl in -lsocket... " >&6; }
12639if test ${ac_cv_lib_socket_htonl+y}
12640then :
12641  printf %s "(cached) " >&6
12642else $as_nop
12643  ac_check_lib_save_LIBS=$LIBS
12644LIBS="-lsocket  $LIBS"
12645cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12646/* end confdefs.h.  */
12647
12648/* Override any GCC internal prototype to avoid an error.
12649   Use char because int might match the return type of a GCC
12650   builtin and then its argument prototype would still apply.  */
12651char htonl ();
12652int
12653main (void)
12654{
12655return htonl ();
12656  ;
12657  return 0;
12658}
12659_ACEOF
12660if ac_fn_c_try_link "$LINENO"
12661then :
12662  ac_cv_lib_socket_htonl=yes
12663else $as_nop
12664  ac_cv_lib_socket_htonl=no
12665fi
12666rm -f core conftest.err conftest.$ac_objext conftest.beam \
12667    conftest$ac_exeext conftest.$ac_ext
12668LIBS=$ac_check_lib_save_LIBS
12669fi
12670{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_htonl" >&5
12671printf "%s\n" "$ac_cv_lib_socket_htonl" >&6; }
12672if test "x$ac_cv_lib_socket_htonl" = xyes
12673then :
12674  found=yes
12675else $as_nop
12676
12677    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __htonl in -lsocket" >&5
12678printf %s "checking for __htonl in -lsocket... " >&6; }
12679if test ${ac_cv_lib_socket___htonl+y}
12680then :
12681  printf %s "(cached) " >&6
12682else $as_nop
12683  ac_check_lib_save_LIBS=$LIBS
12684LIBS="-lsocket  $LIBS"
12685cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12686/* end confdefs.h.  */
12687
12688/* Override any GCC internal prototype to avoid an error.
12689   Use char because int might match the return type of a GCC
12690   builtin and then its argument prototype would still apply.  */
12691char __htonl ();
12692int
12693main (void)
12694{
12695return __htonl ();
12696  ;
12697  return 0;
12698}
12699_ACEOF
12700if ac_fn_c_try_link "$LINENO"
12701then :
12702  ac_cv_lib_socket___htonl=yes
12703else $as_nop
12704  ac_cv_lib_socket___htonl=no
12705fi
12706rm -f core conftest.err conftest.$ac_objext conftest.beam \
12707    conftest$ac_exeext conftest.$ac_ext
12708LIBS=$ac_check_lib_save_LIBS
12709fi
12710{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___htonl" >&5
12711printf "%s\n" "$ac_cv_lib_socket___htonl" >&6; }
12712if test "x$ac_cv_lib_socket___htonl" = xyes
12713then :
12714  found=yes
12715else $as_nop
12716  found=no
12717fi
12718
12719
12720fi
12721
12722
12723  if test "$found" = "yes"; then
12724    ac_libs=$LIBS
12725    LIBS="$LIBS -lsocket"
12726    if test "$cross_compiling" = yes
12727then :
12728
12729            found=yes
12730
12731else $as_nop
12732  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12733/* end confdefs.h.  */
12734int main() { return (0); }
12735_ACEOF
12736if ac_fn_c_try_run "$LINENO"
12737then :
12738  found=yes
12739else $as_nop
12740  found=no
12741fi
12742rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12743  conftest.$ac_objext conftest.beam conftest.$ac_ext
12744fi
12745
12746    LIBS=$ac_libs
12747  fi
12748
12749  if test "$found" = "yes"; then
12750
12751
12752  case socket in
12753  c|c_r) ;;
12754  *)
12755      LIBS="-lsocket $LIBS"
12756   ;;
12757  esac
12758
12759
12760
12761printf "%s\n" "#define HAVE_HTONL 1" >>confdefs.h
12762
12763
12764printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
12765
12766    ac_cv_func_htonl=yes
12767  else
12768
12769
12770  unset ac_cv_lib_network_htonl
12771  unset ac_cv_lib_network___htonl
12772  unset found
12773  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for htonl in -lnetwork" >&5
12774printf %s "checking for htonl in -lnetwork... " >&6; }
12775if test ${ac_cv_lib_network_htonl+y}
12776then :
12777  printf %s "(cached) " >&6
12778else $as_nop
12779  ac_check_lib_save_LIBS=$LIBS
12780LIBS="-lnetwork  $LIBS"
12781cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12782/* end confdefs.h.  */
12783
12784/* Override any GCC internal prototype to avoid an error.
12785   Use char because int might match the return type of a GCC
12786   builtin and then its argument prototype would still apply.  */
12787char htonl ();
12788int
12789main (void)
12790{
12791return htonl ();
12792  ;
12793  return 0;
12794}
12795_ACEOF
12796if ac_fn_c_try_link "$LINENO"
12797then :
12798  ac_cv_lib_network_htonl=yes
12799else $as_nop
12800  ac_cv_lib_network_htonl=no
12801fi
12802rm -f core conftest.err conftest.$ac_objext conftest.beam \
12803    conftest$ac_exeext conftest.$ac_ext
12804LIBS=$ac_check_lib_save_LIBS
12805fi
12806{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_htonl" >&5
12807printf "%s\n" "$ac_cv_lib_network_htonl" >&6; }
12808if test "x$ac_cv_lib_network_htonl" = xyes
12809then :
12810  found=yes
12811else $as_nop
12812
12813    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __htonl in -lnetwork" >&5
12814printf %s "checking for __htonl in -lnetwork... " >&6; }
12815if test ${ac_cv_lib_network___htonl+y}
12816then :
12817  printf %s "(cached) " >&6
12818else $as_nop
12819  ac_check_lib_save_LIBS=$LIBS
12820LIBS="-lnetwork  $LIBS"
12821cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12822/* end confdefs.h.  */
12823
12824/* Override any GCC internal prototype to avoid an error.
12825   Use char because int might match the return type of a GCC
12826   builtin and then its argument prototype would still apply.  */
12827char __htonl ();
12828int
12829main (void)
12830{
12831return __htonl ();
12832  ;
12833  return 0;
12834}
12835_ACEOF
12836if ac_fn_c_try_link "$LINENO"
12837then :
12838  ac_cv_lib_network___htonl=yes
12839else $as_nop
12840  ac_cv_lib_network___htonl=no
12841fi
12842rm -f core conftest.err conftest.$ac_objext conftest.beam \
12843    conftest$ac_exeext conftest.$ac_ext
12844LIBS=$ac_check_lib_save_LIBS
12845fi
12846{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___htonl" >&5
12847printf "%s\n" "$ac_cv_lib_network___htonl" >&6; }
12848if test "x$ac_cv_lib_network___htonl" = xyes
12849then :
12850  found=yes
12851else $as_nop
12852  found=no
12853fi
12854
12855
12856fi
12857
12858
12859  if test "$found" = "yes"; then
12860    ac_libs=$LIBS
12861    LIBS="$LIBS -lnetwork"
12862    if test "$cross_compiling" = yes
12863then :
12864
12865            found=yes
12866
12867else $as_nop
12868  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12869/* end confdefs.h.  */
12870int main() { return (0); }
12871_ACEOF
12872if ac_fn_c_try_run "$LINENO"
12873then :
12874  found=yes
12875else $as_nop
12876  found=no
12877fi
12878rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12879  conftest.$ac_objext conftest.beam conftest.$ac_ext
12880fi
12881
12882    LIBS=$ac_libs
12883  fi
12884
12885  if test "$found" = "yes"; then
12886
12887
12888  case network in
12889  c|c_r) ;;
12890  *)
12891      LIBS="-lnetwork $LIBS"
12892   ;;
12893  esac
12894
12895
12896
12897printf "%s\n" "#define HAVE_HTONL 1" >>confdefs.h
12898
12899
12900printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
12901
12902    ac_cv_func_htonl=yes
12903  else
12904
12905  :
12906
12907  fi
12908
12909
12910  fi
12911
12912 ;;
12913
12914  esac
12915
12916
12917  unset ac_cv_func_gethostname
12918  unset ac_cv_func___gethostname
12919  unset found
12920
12921  ac_fn_c_check_func "$LINENO" "gethostname" "ac_cv_func_gethostname"
12922if test "x$ac_cv_func_gethostname" = xyes
12923then :
12924  found=yes
12925else $as_nop
12926   ac_fn_c_check_func "$LINENO" "__gethostname" "ac_cv_func___gethostname"
12927if test "x$ac_cv_func___gethostname" = xyes
12928then :
12929  found=yes
12930else $as_nop
12931  found=no
12932fi
12933
12934fi
12935
12936
12937  case $found in
12938  yes)
12939
12940printf "%s\n" "#define HAVE_GETHOSTNAME 1" >>confdefs.h
12941
12942    ac_cv_func_gethostname=yes
12943  ;;
12944
12945    *)
12946
12947  unset ac_cv_lib_nsl_gethostname
12948  unset ac_cv_lib_nsl___gethostname
12949  unset found
12950  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostname in -lnsl" >&5
12951printf %s "checking for gethostname in -lnsl... " >&6; }
12952if test ${ac_cv_lib_nsl_gethostname+y}
12953then :
12954  printf %s "(cached) " >&6
12955else $as_nop
12956  ac_check_lib_save_LIBS=$LIBS
12957LIBS="-lnsl  $LIBS"
12958cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12959/* end confdefs.h.  */
12960
12961/* Override any GCC internal prototype to avoid an error.
12962   Use char because int might match the return type of a GCC
12963   builtin and then its argument prototype would still apply.  */
12964char gethostname ();
12965int
12966main (void)
12967{
12968return gethostname ();
12969  ;
12970  return 0;
12971}
12972_ACEOF
12973if ac_fn_c_try_link "$LINENO"
12974then :
12975  ac_cv_lib_nsl_gethostname=yes
12976else $as_nop
12977  ac_cv_lib_nsl_gethostname=no
12978fi
12979rm -f core conftest.err conftest.$ac_objext conftest.beam \
12980    conftest$ac_exeext conftest.$ac_ext
12981LIBS=$ac_check_lib_save_LIBS
12982fi
12983{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostname" >&5
12984printf "%s\n" "$ac_cv_lib_nsl_gethostname" >&6; }
12985if test "x$ac_cv_lib_nsl_gethostname" = xyes
12986then :
12987  found=yes
12988else $as_nop
12989
12990    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gethostname in -lnsl" >&5
12991printf %s "checking for __gethostname in -lnsl... " >&6; }
12992if test ${ac_cv_lib_nsl___gethostname+y}
12993then :
12994  printf %s "(cached) " >&6
12995else $as_nop
12996  ac_check_lib_save_LIBS=$LIBS
12997LIBS="-lnsl  $LIBS"
12998cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12999/* end confdefs.h.  */
13000
13001/* Override any GCC internal prototype to avoid an error.
13002   Use char because int might match the return type of a GCC
13003   builtin and then its argument prototype would still apply.  */
13004char __gethostname ();
13005int
13006main (void)
13007{
13008return __gethostname ();
13009  ;
13010  return 0;
13011}
13012_ACEOF
13013if ac_fn_c_try_link "$LINENO"
13014then :
13015  ac_cv_lib_nsl___gethostname=yes
13016else $as_nop
13017  ac_cv_lib_nsl___gethostname=no
13018fi
13019rm -f core conftest.err conftest.$ac_objext conftest.beam \
13020    conftest$ac_exeext conftest.$ac_ext
13021LIBS=$ac_check_lib_save_LIBS
13022fi
13023{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl___gethostname" >&5
13024printf "%s\n" "$ac_cv_lib_nsl___gethostname" >&6; }
13025if test "x$ac_cv_lib_nsl___gethostname" = xyes
13026then :
13027  found=yes
13028else $as_nop
13029  found=no
13030fi
13031
13032
13033fi
13034
13035
13036  if test "$found" = "yes"; then
13037    ac_libs=$LIBS
13038    LIBS="$LIBS -lnsl"
13039    if test "$cross_compiling" = yes
13040then :
13041
13042            found=yes
13043
13044else $as_nop
13045  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13046/* end confdefs.h.  */
13047int main() { return (0); }
13048_ACEOF
13049if ac_fn_c_try_run "$LINENO"
13050then :
13051  found=yes
13052else $as_nop
13053  found=no
13054fi
13055rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13056  conftest.$ac_objext conftest.beam conftest.$ac_ext
13057fi
13058
13059    LIBS=$ac_libs
13060  fi
13061
13062  if test "$found" = "yes"; then
13063
13064
13065  case nsl in
13066  c|c_r) ;;
13067  *)
13068      LIBS="-lnsl $LIBS"
13069   ;;
13070  esac
13071
13072
13073
13074printf "%s\n" "#define HAVE_GETHOSTNAME 1" >>confdefs.h
13075
13076
13077printf "%s\n" "#define HAVE_LIBNSL 1" >>confdefs.h
13078
13079    ac_cv_func_gethostname=yes
13080  else
13081
13082
13083  unset ac_cv_lib_network_gethostname
13084  unset ac_cv_lib_network___gethostname
13085  unset found
13086  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostname in -lnetwork" >&5
13087printf %s "checking for gethostname in -lnetwork... " >&6; }
13088if test ${ac_cv_lib_network_gethostname+y}
13089then :
13090  printf %s "(cached) " >&6
13091else $as_nop
13092  ac_check_lib_save_LIBS=$LIBS
13093LIBS="-lnetwork  $LIBS"
13094cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13095/* end confdefs.h.  */
13096
13097/* Override any GCC internal prototype to avoid an error.
13098   Use char because int might match the return type of a GCC
13099   builtin and then its argument prototype would still apply.  */
13100char gethostname ();
13101int
13102main (void)
13103{
13104return gethostname ();
13105  ;
13106  return 0;
13107}
13108_ACEOF
13109if ac_fn_c_try_link "$LINENO"
13110then :
13111  ac_cv_lib_network_gethostname=yes
13112else $as_nop
13113  ac_cv_lib_network_gethostname=no
13114fi
13115rm -f core conftest.err conftest.$ac_objext conftest.beam \
13116    conftest$ac_exeext conftest.$ac_ext
13117LIBS=$ac_check_lib_save_LIBS
13118fi
13119{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_gethostname" >&5
13120printf "%s\n" "$ac_cv_lib_network_gethostname" >&6; }
13121if test "x$ac_cv_lib_network_gethostname" = xyes
13122then :
13123  found=yes
13124else $as_nop
13125
13126    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gethostname in -lnetwork" >&5
13127printf %s "checking for __gethostname in -lnetwork... " >&6; }
13128if test ${ac_cv_lib_network___gethostname+y}
13129then :
13130  printf %s "(cached) " >&6
13131else $as_nop
13132  ac_check_lib_save_LIBS=$LIBS
13133LIBS="-lnetwork  $LIBS"
13134cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13135/* end confdefs.h.  */
13136
13137/* Override any GCC internal prototype to avoid an error.
13138   Use char because int might match the return type of a GCC
13139   builtin and then its argument prototype would still apply.  */
13140char __gethostname ();
13141int
13142main (void)
13143{
13144return __gethostname ();
13145  ;
13146  return 0;
13147}
13148_ACEOF
13149if ac_fn_c_try_link "$LINENO"
13150then :
13151  ac_cv_lib_network___gethostname=yes
13152else $as_nop
13153  ac_cv_lib_network___gethostname=no
13154fi
13155rm -f core conftest.err conftest.$ac_objext conftest.beam \
13156    conftest$ac_exeext conftest.$ac_ext
13157LIBS=$ac_check_lib_save_LIBS
13158fi
13159{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___gethostname" >&5
13160printf "%s\n" "$ac_cv_lib_network___gethostname" >&6; }
13161if test "x$ac_cv_lib_network___gethostname" = xyes
13162then :
13163  found=yes
13164else $as_nop
13165  found=no
13166fi
13167
13168
13169fi
13170
13171
13172  if test "$found" = "yes"; then
13173    ac_libs=$LIBS
13174    LIBS="$LIBS -lnetwork"
13175    if test "$cross_compiling" = yes
13176then :
13177
13178            found=yes
13179
13180else $as_nop
13181  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13182/* end confdefs.h.  */
13183int main() { return (0); }
13184_ACEOF
13185if ac_fn_c_try_run "$LINENO"
13186then :
13187  found=yes
13188else $as_nop
13189  found=no
13190fi
13191rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13192  conftest.$ac_objext conftest.beam conftest.$ac_ext
13193fi
13194
13195    LIBS=$ac_libs
13196  fi
13197
13198  if test "$found" = "yes"; then
13199
13200
13201  case network in
13202  c|c_r) ;;
13203  *)
13204      LIBS="-lnetwork $LIBS"
13205   ;;
13206  esac
13207
13208
13209
13210printf "%s\n" "#define HAVE_GETHOSTNAME 1" >>confdefs.h
13211
13212
13213printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
13214
13215    ac_cv_func_gethostname=yes
13216  else
13217
13218  :
13219
13220  fi
13221
13222
13223  fi
13224
13225 ;;
13226
13227  esac
13228
13229
13230  unset ac_cv_func_gethostbyaddr
13231  unset ac_cv_func___gethostbyaddr
13232  unset found
13233
13234  ac_fn_c_check_func "$LINENO" "gethostbyaddr" "ac_cv_func_gethostbyaddr"
13235if test "x$ac_cv_func_gethostbyaddr" = xyes
13236then :
13237  found=yes
13238else $as_nop
13239   ac_fn_c_check_func "$LINENO" "__gethostbyaddr" "ac_cv_func___gethostbyaddr"
13240if test "x$ac_cv_func___gethostbyaddr" = xyes
13241then :
13242  found=yes
13243else $as_nop
13244  found=no
13245fi
13246
13247fi
13248
13249
13250  case $found in
13251  yes)
13252
13253printf "%s\n" "#define HAVE_GETHOSTBYADDR 1" >>confdefs.h
13254
13255    ac_cv_func_gethostbyaddr=yes
13256  ;;
13257
13258    *)
13259
13260  unset ac_cv_lib_nsl_gethostbyaddr
13261  unset ac_cv_lib_nsl___gethostbyaddr
13262  unset found
13263  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostbyaddr in -lnsl" >&5
13264printf %s "checking for gethostbyaddr in -lnsl... " >&6; }
13265if test ${ac_cv_lib_nsl_gethostbyaddr+y}
13266then :
13267  printf %s "(cached) " >&6
13268else $as_nop
13269  ac_check_lib_save_LIBS=$LIBS
13270LIBS="-lnsl  $LIBS"
13271cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13272/* end confdefs.h.  */
13273
13274/* Override any GCC internal prototype to avoid an error.
13275   Use char because int might match the return type of a GCC
13276   builtin and then its argument prototype would still apply.  */
13277char gethostbyaddr ();
13278int
13279main (void)
13280{
13281return gethostbyaddr ();
13282  ;
13283  return 0;
13284}
13285_ACEOF
13286if ac_fn_c_try_link "$LINENO"
13287then :
13288  ac_cv_lib_nsl_gethostbyaddr=yes
13289else $as_nop
13290  ac_cv_lib_nsl_gethostbyaddr=no
13291fi
13292rm -f core conftest.err conftest.$ac_objext conftest.beam \
13293    conftest$ac_exeext conftest.$ac_ext
13294LIBS=$ac_check_lib_save_LIBS
13295fi
13296{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyaddr" >&5
13297printf "%s\n" "$ac_cv_lib_nsl_gethostbyaddr" >&6; }
13298if test "x$ac_cv_lib_nsl_gethostbyaddr" = xyes
13299then :
13300  found=yes
13301else $as_nop
13302
13303    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gethostbyaddr in -lnsl" >&5
13304printf %s "checking for __gethostbyaddr in -lnsl... " >&6; }
13305if test ${ac_cv_lib_nsl___gethostbyaddr+y}
13306then :
13307  printf %s "(cached) " >&6
13308else $as_nop
13309  ac_check_lib_save_LIBS=$LIBS
13310LIBS="-lnsl  $LIBS"
13311cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13312/* end confdefs.h.  */
13313
13314/* Override any GCC internal prototype to avoid an error.
13315   Use char because int might match the return type of a GCC
13316   builtin and then its argument prototype would still apply.  */
13317char __gethostbyaddr ();
13318int
13319main (void)
13320{
13321return __gethostbyaddr ();
13322  ;
13323  return 0;
13324}
13325_ACEOF
13326if ac_fn_c_try_link "$LINENO"
13327then :
13328  ac_cv_lib_nsl___gethostbyaddr=yes
13329else $as_nop
13330  ac_cv_lib_nsl___gethostbyaddr=no
13331fi
13332rm -f core conftest.err conftest.$ac_objext conftest.beam \
13333    conftest$ac_exeext conftest.$ac_ext
13334LIBS=$ac_check_lib_save_LIBS
13335fi
13336{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl___gethostbyaddr" >&5
13337printf "%s\n" "$ac_cv_lib_nsl___gethostbyaddr" >&6; }
13338if test "x$ac_cv_lib_nsl___gethostbyaddr" = xyes
13339then :
13340  found=yes
13341else $as_nop
13342  found=no
13343fi
13344
13345
13346fi
13347
13348
13349  if test "$found" = "yes"; then
13350    ac_libs=$LIBS
13351    LIBS="$LIBS -lnsl"
13352    if test "$cross_compiling" = yes
13353then :
13354
13355            found=yes
13356
13357else $as_nop
13358  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13359/* end confdefs.h.  */
13360int main() { return (0); }
13361_ACEOF
13362if ac_fn_c_try_run "$LINENO"
13363then :
13364  found=yes
13365else $as_nop
13366  found=no
13367fi
13368rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13369  conftest.$ac_objext conftest.beam conftest.$ac_ext
13370fi
13371
13372    LIBS=$ac_libs
13373  fi
13374
13375  if test "$found" = "yes"; then
13376
13377
13378  case nsl in
13379  c|c_r) ;;
13380  *)
13381      LIBS="-lnsl $LIBS"
13382   ;;
13383  esac
13384
13385
13386
13387printf "%s\n" "#define HAVE_GETHOSTBYADDR 1" >>confdefs.h
13388
13389
13390printf "%s\n" "#define HAVE_LIBNSL 1" >>confdefs.h
13391
13392    ac_cv_func_gethostbyaddr=yes
13393  else
13394
13395
13396  unset ac_cv_lib_network_gethostbyaddr
13397  unset ac_cv_lib_network___gethostbyaddr
13398  unset found
13399  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostbyaddr in -lnetwork" >&5
13400printf %s "checking for gethostbyaddr in -lnetwork... " >&6; }
13401if test ${ac_cv_lib_network_gethostbyaddr+y}
13402then :
13403  printf %s "(cached) " >&6
13404else $as_nop
13405  ac_check_lib_save_LIBS=$LIBS
13406LIBS="-lnetwork  $LIBS"
13407cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13408/* end confdefs.h.  */
13409
13410/* Override any GCC internal prototype to avoid an error.
13411   Use char because int might match the return type of a GCC
13412   builtin and then its argument prototype would still apply.  */
13413char gethostbyaddr ();
13414int
13415main (void)
13416{
13417return gethostbyaddr ();
13418  ;
13419  return 0;
13420}
13421_ACEOF
13422if ac_fn_c_try_link "$LINENO"
13423then :
13424  ac_cv_lib_network_gethostbyaddr=yes
13425else $as_nop
13426  ac_cv_lib_network_gethostbyaddr=no
13427fi
13428rm -f core conftest.err conftest.$ac_objext conftest.beam \
13429    conftest$ac_exeext conftest.$ac_ext
13430LIBS=$ac_check_lib_save_LIBS
13431fi
13432{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_gethostbyaddr" >&5
13433printf "%s\n" "$ac_cv_lib_network_gethostbyaddr" >&6; }
13434if test "x$ac_cv_lib_network_gethostbyaddr" = xyes
13435then :
13436  found=yes
13437else $as_nop
13438
13439    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gethostbyaddr in -lnetwork" >&5
13440printf %s "checking for __gethostbyaddr in -lnetwork... " >&6; }
13441if test ${ac_cv_lib_network___gethostbyaddr+y}
13442then :
13443  printf %s "(cached) " >&6
13444else $as_nop
13445  ac_check_lib_save_LIBS=$LIBS
13446LIBS="-lnetwork  $LIBS"
13447cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13448/* end confdefs.h.  */
13449
13450/* Override any GCC internal prototype to avoid an error.
13451   Use char because int might match the return type of a GCC
13452   builtin and then its argument prototype would still apply.  */
13453char __gethostbyaddr ();
13454int
13455main (void)
13456{
13457return __gethostbyaddr ();
13458  ;
13459  return 0;
13460}
13461_ACEOF
13462if ac_fn_c_try_link "$LINENO"
13463then :
13464  ac_cv_lib_network___gethostbyaddr=yes
13465else $as_nop
13466  ac_cv_lib_network___gethostbyaddr=no
13467fi
13468rm -f core conftest.err conftest.$ac_objext conftest.beam \
13469    conftest$ac_exeext conftest.$ac_ext
13470LIBS=$ac_check_lib_save_LIBS
13471fi
13472{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___gethostbyaddr" >&5
13473printf "%s\n" "$ac_cv_lib_network___gethostbyaddr" >&6; }
13474if test "x$ac_cv_lib_network___gethostbyaddr" = xyes
13475then :
13476  found=yes
13477else $as_nop
13478  found=no
13479fi
13480
13481
13482fi
13483
13484
13485  if test "$found" = "yes"; then
13486    ac_libs=$LIBS
13487    LIBS="$LIBS -lnetwork"
13488    if test "$cross_compiling" = yes
13489then :
13490
13491            found=yes
13492
13493else $as_nop
13494  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13495/* end confdefs.h.  */
13496int main() { return (0); }
13497_ACEOF
13498if ac_fn_c_try_run "$LINENO"
13499then :
13500  found=yes
13501else $as_nop
13502  found=no
13503fi
13504rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13505  conftest.$ac_objext conftest.beam conftest.$ac_ext
13506fi
13507
13508    LIBS=$ac_libs
13509  fi
13510
13511  if test "$found" = "yes"; then
13512
13513
13514  case network in
13515  c|c_r) ;;
13516  *)
13517      LIBS="-lnetwork $LIBS"
13518   ;;
13519  esac
13520
13521
13522
13523printf "%s\n" "#define HAVE_GETHOSTBYADDR 1" >>confdefs.h
13524
13525
13526printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
13527
13528    ac_cv_func_gethostbyaddr=yes
13529  else
13530
13531  :
13532
13533  fi
13534
13535
13536  fi
13537
13538 ;;
13539
13540  esac
13541
13542
13543  unset ac_cv_func_dlopen
13544  unset ac_cv_func___dlopen
13545  unset found
13546
13547  ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
13548if test "x$ac_cv_func_dlopen" = xyes
13549then :
13550  found=yes
13551else $as_nop
13552   ac_fn_c_check_func "$LINENO" "__dlopen" "ac_cv_func___dlopen"
13553if test "x$ac_cv_func___dlopen" = xyes
13554then :
13555  found=yes
13556else $as_nop
13557  found=no
13558fi
13559
13560fi
13561
13562
13563  case $found in
13564  yes)
13565
13566printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
13567
13568    ac_cv_func_dlopen=yes
13569  ;;
13570
13571    *)
13572
13573  unset ac_cv_lib_dl_dlopen
13574  unset ac_cv_lib_dl___dlopen
13575  unset found
13576  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
13577printf %s "checking for dlopen in -ldl... " >&6; }
13578if test ${ac_cv_lib_dl_dlopen+y}
13579then :
13580  printf %s "(cached) " >&6
13581else $as_nop
13582  ac_check_lib_save_LIBS=$LIBS
13583LIBS="-ldl  $LIBS"
13584cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13585/* end confdefs.h.  */
13586
13587/* Override any GCC internal prototype to avoid an error.
13588   Use char because int might match the return type of a GCC
13589   builtin and then its argument prototype would still apply.  */
13590char dlopen ();
13591int
13592main (void)
13593{
13594return dlopen ();
13595  ;
13596  return 0;
13597}
13598_ACEOF
13599if ac_fn_c_try_link "$LINENO"
13600then :
13601  ac_cv_lib_dl_dlopen=yes
13602else $as_nop
13603  ac_cv_lib_dl_dlopen=no
13604fi
13605rm -f core conftest.err conftest.$ac_objext conftest.beam \
13606    conftest$ac_exeext conftest.$ac_ext
13607LIBS=$ac_check_lib_save_LIBS
13608fi
13609{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
13610printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
13611if test "x$ac_cv_lib_dl_dlopen" = xyes
13612then :
13613  found=yes
13614else $as_nop
13615
13616    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dlopen in -ldl" >&5
13617printf %s "checking for __dlopen in -ldl... " >&6; }
13618if test ${ac_cv_lib_dl___dlopen+y}
13619then :
13620  printf %s "(cached) " >&6
13621else $as_nop
13622  ac_check_lib_save_LIBS=$LIBS
13623LIBS="-ldl  $LIBS"
13624cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13625/* end confdefs.h.  */
13626
13627/* Override any GCC internal prototype to avoid an error.
13628   Use char because int might match the return type of a GCC
13629   builtin and then its argument prototype would still apply.  */
13630char __dlopen ();
13631int
13632main (void)
13633{
13634return __dlopen ();
13635  ;
13636  return 0;
13637}
13638_ACEOF
13639if ac_fn_c_try_link "$LINENO"
13640then :
13641  ac_cv_lib_dl___dlopen=yes
13642else $as_nop
13643  ac_cv_lib_dl___dlopen=no
13644fi
13645rm -f core conftest.err conftest.$ac_objext conftest.beam \
13646    conftest$ac_exeext conftest.$ac_ext
13647LIBS=$ac_check_lib_save_LIBS
13648fi
13649{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl___dlopen" >&5
13650printf "%s\n" "$ac_cv_lib_dl___dlopen" >&6; }
13651if test "x$ac_cv_lib_dl___dlopen" = xyes
13652then :
13653  found=yes
13654else $as_nop
13655  found=no
13656fi
13657
13658
13659fi
13660
13661
13662  if test "$found" = "yes"; then
13663    ac_libs=$LIBS
13664    LIBS="$LIBS -ldl"
13665    if test "$cross_compiling" = yes
13666then :
13667
13668            found=yes
13669
13670else $as_nop
13671  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13672/* end confdefs.h.  */
13673int main() { return (0); }
13674_ACEOF
13675if ac_fn_c_try_run "$LINENO"
13676then :
13677  found=yes
13678else $as_nop
13679  found=no
13680fi
13681rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13682  conftest.$ac_objext conftest.beam conftest.$ac_ext
13683fi
13684
13685    LIBS=$ac_libs
13686  fi
13687
13688  if test "$found" = "yes"; then
13689
13690
13691  case dl in
13692  c|c_r) ;;
13693  *)
13694      LIBS="-ldl $LIBS"
13695   ;;
13696  esac
13697
13698
13699
13700printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
13701
13702
13703printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h
13704
13705    ac_cv_func_dlopen=yes
13706  else
13707
13708
13709  unset ac_cv_lib_root_dlopen
13710  unset ac_cv_lib_root___dlopen
13711  unset found
13712  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lroot" >&5
13713printf %s "checking for dlopen in -lroot... " >&6; }
13714if test ${ac_cv_lib_root_dlopen+y}
13715then :
13716  printf %s "(cached) " >&6
13717else $as_nop
13718  ac_check_lib_save_LIBS=$LIBS
13719LIBS="-lroot  $LIBS"
13720cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13721/* end confdefs.h.  */
13722
13723/* Override any GCC internal prototype to avoid an error.
13724   Use char because int might match the return type of a GCC
13725   builtin and then its argument prototype would still apply.  */
13726char dlopen ();
13727int
13728main (void)
13729{
13730return dlopen ();
13731  ;
13732  return 0;
13733}
13734_ACEOF
13735if ac_fn_c_try_link "$LINENO"
13736then :
13737  ac_cv_lib_root_dlopen=yes
13738else $as_nop
13739  ac_cv_lib_root_dlopen=no
13740fi
13741rm -f core conftest.err conftest.$ac_objext conftest.beam \
13742    conftest$ac_exeext conftest.$ac_ext
13743LIBS=$ac_check_lib_save_LIBS
13744fi
13745{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root_dlopen" >&5
13746printf "%s\n" "$ac_cv_lib_root_dlopen" >&6; }
13747if test "x$ac_cv_lib_root_dlopen" = xyes
13748then :
13749  found=yes
13750else $as_nop
13751
13752    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dlopen in -lroot" >&5
13753printf %s "checking for __dlopen in -lroot... " >&6; }
13754if test ${ac_cv_lib_root___dlopen+y}
13755then :
13756  printf %s "(cached) " >&6
13757else $as_nop
13758  ac_check_lib_save_LIBS=$LIBS
13759LIBS="-lroot  $LIBS"
13760cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13761/* end confdefs.h.  */
13762
13763/* Override any GCC internal prototype to avoid an error.
13764   Use char because int might match the return type of a GCC
13765   builtin and then its argument prototype would still apply.  */
13766char __dlopen ();
13767int
13768main (void)
13769{
13770return __dlopen ();
13771  ;
13772  return 0;
13773}
13774_ACEOF
13775if ac_fn_c_try_link "$LINENO"
13776then :
13777  ac_cv_lib_root___dlopen=yes
13778else $as_nop
13779  ac_cv_lib_root___dlopen=no
13780fi
13781rm -f core conftest.err conftest.$ac_objext conftest.beam \
13782    conftest$ac_exeext conftest.$ac_ext
13783LIBS=$ac_check_lib_save_LIBS
13784fi
13785{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root___dlopen" >&5
13786printf "%s\n" "$ac_cv_lib_root___dlopen" >&6; }
13787if test "x$ac_cv_lib_root___dlopen" = xyes
13788then :
13789  found=yes
13790else $as_nop
13791  found=no
13792fi
13793
13794
13795fi
13796
13797
13798  if test "$found" = "yes"; then
13799    ac_libs=$LIBS
13800    LIBS="$LIBS -lroot"
13801    if test "$cross_compiling" = yes
13802then :
13803
13804            found=yes
13805
13806else $as_nop
13807  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13808/* end confdefs.h.  */
13809int main() { return (0); }
13810_ACEOF
13811if ac_fn_c_try_run "$LINENO"
13812then :
13813  found=yes
13814else $as_nop
13815  found=no
13816fi
13817rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13818  conftest.$ac_objext conftest.beam conftest.$ac_ext
13819fi
13820
13821    LIBS=$ac_libs
13822  fi
13823
13824  if test "$found" = "yes"; then
13825
13826
13827  case root in
13828  c|c_r) ;;
13829  *)
13830      LIBS="-lroot $LIBS"
13831   ;;
13832  esac
13833
13834
13835
13836printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
13837
13838
13839printf "%s\n" "#define HAVE_LIBROOT 1" >>confdefs.h
13840
13841    ac_cv_func_dlopen=yes
13842  else
13843
13844  :
13845
13846  fi
13847
13848
13849  fi
13850
13851 ;;
13852
13853  esac
13854
13855
13856  unset ac_cv_func_dlsym
13857  unset ac_cv_func___dlsym
13858  unset found
13859
13860  ac_fn_c_check_func "$LINENO" "dlsym" "ac_cv_func_dlsym"
13861if test "x$ac_cv_func_dlsym" = xyes
13862then :
13863  found=yes
13864else $as_nop
13865   ac_fn_c_check_func "$LINENO" "__dlsym" "ac_cv_func___dlsym"
13866if test "x$ac_cv_func___dlsym" = xyes
13867then :
13868  found=yes
13869else $as_nop
13870  found=no
13871fi
13872
13873fi
13874
13875
13876  case $found in
13877  yes)
13878
13879printf "%s\n" "#define HAVE_DLSYM 1" >>confdefs.h
13880
13881    ac_cv_func_dlsym=yes
13882  ;;
13883
13884    *)
13885
13886  unset ac_cv_lib_dl_dlsym
13887  unset ac_cv_lib_dl___dlsym
13888  unset found
13889  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlsym in -ldl" >&5
13890printf %s "checking for dlsym in -ldl... " >&6; }
13891if test ${ac_cv_lib_dl_dlsym+y}
13892then :
13893  printf %s "(cached) " >&6
13894else $as_nop
13895  ac_check_lib_save_LIBS=$LIBS
13896LIBS="-ldl  $LIBS"
13897cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13898/* end confdefs.h.  */
13899
13900/* Override any GCC internal prototype to avoid an error.
13901   Use char because int might match the return type of a GCC
13902   builtin and then its argument prototype would still apply.  */
13903char dlsym ();
13904int
13905main (void)
13906{
13907return dlsym ();
13908  ;
13909  return 0;
13910}
13911_ACEOF
13912if ac_fn_c_try_link "$LINENO"
13913then :
13914  ac_cv_lib_dl_dlsym=yes
13915else $as_nop
13916  ac_cv_lib_dl_dlsym=no
13917fi
13918rm -f core conftest.err conftest.$ac_objext conftest.beam \
13919    conftest$ac_exeext conftest.$ac_ext
13920LIBS=$ac_check_lib_save_LIBS
13921fi
13922{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlsym" >&5
13923printf "%s\n" "$ac_cv_lib_dl_dlsym" >&6; }
13924if test "x$ac_cv_lib_dl_dlsym" = xyes
13925then :
13926  found=yes
13927else $as_nop
13928
13929    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dlsym in -ldl" >&5
13930printf %s "checking for __dlsym in -ldl... " >&6; }
13931if test ${ac_cv_lib_dl___dlsym+y}
13932then :
13933  printf %s "(cached) " >&6
13934else $as_nop
13935  ac_check_lib_save_LIBS=$LIBS
13936LIBS="-ldl  $LIBS"
13937cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13938/* end confdefs.h.  */
13939
13940/* Override any GCC internal prototype to avoid an error.
13941   Use char because int might match the return type of a GCC
13942   builtin and then its argument prototype would still apply.  */
13943char __dlsym ();
13944int
13945main (void)
13946{
13947return __dlsym ();
13948  ;
13949  return 0;
13950}
13951_ACEOF
13952if ac_fn_c_try_link "$LINENO"
13953then :
13954  ac_cv_lib_dl___dlsym=yes
13955else $as_nop
13956  ac_cv_lib_dl___dlsym=no
13957fi
13958rm -f core conftest.err conftest.$ac_objext conftest.beam \
13959    conftest$ac_exeext conftest.$ac_ext
13960LIBS=$ac_check_lib_save_LIBS
13961fi
13962{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl___dlsym" >&5
13963printf "%s\n" "$ac_cv_lib_dl___dlsym" >&6; }
13964if test "x$ac_cv_lib_dl___dlsym" = xyes
13965then :
13966  found=yes
13967else $as_nop
13968  found=no
13969fi
13970
13971
13972fi
13973
13974
13975  if test "$found" = "yes"; then
13976    ac_libs=$LIBS
13977    LIBS="$LIBS -ldl"
13978    if test "$cross_compiling" = yes
13979then :
13980
13981            found=yes
13982
13983else $as_nop
13984  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13985/* end confdefs.h.  */
13986int main() { return (0); }
13987_ACEOF
13988if ac_fn_c_try_run "$LINENO"
13989then :
13990  found=yes
13991else $as_nop
13992  found=no
13993fi
13994rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13995  conftest.$ac_objext conftest.beam conftest.$ac_ext
13996fi
13997
13998    LIBS=$ac_libs
13999  fi
14000
14001  if test "$found" = "yes"; then
14002
14003
14004  case dl in
14005  c|c_r) ;;
14006  *)
14007      LIBS="-ldl $LIBS"
14008   ;;
14009  esac
14010
14011
14012
14013printf "%s\n" "#define HAVE_DLSYM 1" >>confdefs.h
14014
14015
14016printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h
14017
14018    ac_cv_func_dlsym=yes
14019  else
14020
14021
14022  unset ac_cv_lib_root_dlsym
14023  unset ac_cv_lib_root___dlsym
14024  unset found
14025  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlsym in -lroot" >&5
14026printf %s "checking for dlsym in -lroot... " >&6; }
14027if test ${ac_cv_lib_root_dlsym+y}
14028then :
14029  printf %s "(cached) " >&6
14030else $as_nop
14031  ac_check_lib_save_LIBS=$LIBS
14032LIBS="-lroot  $LIBS"
14033cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14034/* end confdefs.h.  */
14035
14036/* Override any GCC internal prototype to avoid an error.
14037   Use char because int might match the return type of a GCC
14038   builtin and then its argument prototype would still apply.  */
14039char dlsym ();
14040int
14041main (void)
14042{
14043return dlsym ();
14044  ;
14045  return 0;
14046}
14047_ACEOF
14048if ac_fn_c_try_link "$LINENO"
14049then :
14050  ac_cv_lib_root_dlsym=yes
14051else $as_nop
14052  ac_cv_lib_root_dlsym=no
14053fi
14054rm -f core conftest.err conftest.$ac_objext conftest.beam \
14055    conftest$ac_exeext conftest.$ac_ext
14056LIBS=$ac_check_lib_save_LIBS
14057fi
14058{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root_dlsym" >&5
14059printf "%s\n" "$ac_cv_lib_root_dlsym" >&6; }
14060if test "x$ac_cv_lib_root_dlsym" = xyes
14061then :
14062  found=yes
14063else $as_nop
14064
14065    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dlsym in -lroot" >&5
14066printf %s "checking for __dlsym in -lroot... " >&6; }
14067if test ${ac_cv_lib_root___dlsym+y}
14068then :
14069  printf %s "(cached) " >&6
14070else $as_nop
14071  ac_check_lib_save_LIBS=$LIBS
14072LIBS="-lroot  $LIBS"
14073cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14074/* end confdefs.h.  */
14075
14076/* Override any GCC internal prototype to avoid an error.
14077   Use char because int might match the return type of a GCC
14078   builtin and then its argument prototype would still apply.  */
14079char __dlsym ();
14080int
14081main (void)
14082{
14083return __dlsym ();
14084  ;
14085  return 0;
14086}
14087_ACEOF
14088if ac_fn_c_try_link "$LINENO"
14089then :
14090  ac_cv_lib_root___dlsym=yes
14091else $as_nop
14092  ac_cv_lib_root___dlsym=no
14093fi
14094rm -f core conftest.err conftest.$ac_objext conftest.beam \
14095    conftest$ac_exeext conftest.$ac_ext
14096LIBS=$ac_check_lib_save_LIBS
14097fi
14098{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root___dlsym" >&5
14099printf "%s\n" "$ac_cv_lib_root___dlsym" >&6; }
14100if test "x$ac_cv_lib_root___dlsym" = xyes
14101then :
14102  found=yes
14103else $as_nop
14104  found=no
14105fi
14106
14107
14108fi
14109
14110
14111  if test "$found" = "yes"; then
14112    ac_libs=$LIBS
14113    LIBS="$LIBS -lroot"
14114    if test "$cross_compiling" = yes
14115then :
14116
14117            found=yes
14118
14119else $as_nop
14120  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14121/* end confdefs.h.  */
14122int main() { return (0); }
14123_ACEOF
14124if ac_fn_c_try_run "$LINENO"
14125then :
14126  found=yes
14127else $as_nop
14128  found=no
14129fi
14130rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14131  conftest.$ac_objext conftest.beam conftest.$ac_ext
14132fi
14133
14134    LIBS=$ac_libs
14135  fi
14136
14137  if test "$found" = "yes"; then
14138
14139
14140  case root in
14141  c|c_r) ;;
14142  *)
14143      LIBS="-lroot $LIBS"
14144   ;;
14145  esac
14146
14147
14148
14149printf "%s\n" "#define HAVE_DLSYM 1" >>confdefs.h
14150
14151
14152printf "%s\n" "#define HAVE_LIBROOT 1" >>confdefs.h
14153
14154    ac_cv_func_dlsym=yes
14155  else
14156
14157  :
14158
14159  fi
14160
14161
14162  fi
14163
14164 ;;
14165
14166  esac
14167
14168if test "$ac_cv_func_dlopen" = "yes"; then
14169
14170printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h
14171
14172fi
14173{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sin in -lm" >&5
14174printf %s "checking for sin in -lm... " >&6; }
14175if test ${ac_cv_lib_m_sin+y}
14176then :
14177  printf %s "(cached) " >&6
14178else $as_nop
14179  ac_check_lib_save_LIBS=$LIBS
14180LIBS="-lm  $LIBS"
14181cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14182/* end confdefs.h.  */
14183
14184/* Override any GCC internal prototype to avoid an error.
14185   Use char because int might match the return type of a GCC
14186   builtin and then its argument prototype would still apply.  */
14187char sin ();
14188int
14189main (void)
14190{
14191return sin ();
14192  ;
14193  return 0;
14194}
14195_ACEOF
14196if ac_fn_c_try_link "$LINENO"
14197then :
14198  ac_cv_lib_m_sin=yes
14199else $as_nop
14200  ac_cv_lib_m_sin=no
14201fi
14202rm -f core conftest.err conftest.$ac_objext conftest.beam \
14203    conftest$ac_exeext conftest.$ac_ext
14204LIBS=$ac_check_lib_save_LIBS
14205fi
14206{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sin" >&5
14207printf "%s\n" "$ac_cv_lib_m_sin" >&6; }
14208if test "x$ac_cv_lib_m_sin" = xyes
14209then :
14210  printf "%s\n" "#define HAVE_LIBM 1" >>confdefs.h
14211
14212  LIBS="-lm $LIBS"
14213
14214fi
14215
14216
14217
14218  unset ac_cv_func_inet_aton
14219  unset ac_cv_func___inet_aton
14220  unset found
14221
14222  ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
14223if test "x$ac_cv_func_inet_aton" = xyes
14224then :
14225  found=yes
14226else $as_nop
14227   ac_fn_c_check_func "$LINENO" "__inet_aton" "ac_cv_func___inet_aton"
14228if test "x$ac_cv_func___inet_aton" = xyes
14229then :
14230  found=yes
14231else $as_nop
14232  found=no
14233fi
14234
14235fi
14236
14237
14238  case $found in
14239  yes)
14240
14241printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
14242
14243    ac_cv_func_inet_aton=yes
14244  ;;
14245
14246    *)
14247
14248  unset ac_cv_lib_resolv_inet_aton
14249  unset ac_cv_lib_resolv___inet_aton
14250  unset found
14251  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lresolv" >&5
14252printf %s "checking for inet_aton in -lresolv... " >&6; }
14253if test ${ac_cv_lib_resolv_inet_aton+y}
14254then :
14255  printf %s "(cached) " >&6
14256else $as_nop
14257  ac_check_lib_save_LIBS=$LIBS
14258LIBS="-lresolv  $LIBS"
14259cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14260/* end confdefs.h.  */
14261
14262/* Override any GCC internal prototype to avoid an error.
14263   Use char because int might match the return type of a GCC
14264   builtin and then its argument prototype would still apply.  */
14265char inet_aton ();
14266int
14267main (void)
14268{
14269return inet_aton ();
14270  ;
14271  return 0;
14272}
14273_ACEOF
14274if ac_fn_c_try_link "$LINENO"
14275then :
14276  ac_cv_lib_resolv_inet_aton=yes
14277else $as_nop
14278  ac_cv_lib_resolv_inet_aton=no
14279fi
14280rm -f core conftest.err conftest.$ac_objext conftest.beam \
14281    conftest$ac_exeext conftest.$ac_ext
14282LIBS=$ac_check_lib_save_LIBS
14283fi
14284{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_inet_aton" >&5
14285printf "%s\n" "$ac_cv_lib_resolv_inet_aton" >&6; }
14286if test "x$ac_cv_lib_resolv_inet_aton" = xyes
14287then :
14288  found=yes
14289else $as_nop
14290
14291    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __inet_aton in -lresolv" >&5
14292printf %s "checking for __inet_aton in -lresolv... " >&6; }
14293if test ${ac_cv_lib_resolv___inet_aton+y}
14294then :
14295  printf %s "(cached) " >&6
14296else $as_nop
14297  ac_check_lib_save_LIBS=$LIBS
14298LIBS="-lresolv  $LIBS"
14299cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14300/* end confdefs.h.  */
14301
14302/* Override any GCC internal prototype to avoid an error.
14303   Use char because int might match the return type of a GCC
14304   builtin and then its argument prototype would still apply.  */
14305char __inet_aton ();
14306int
14307main (void)
14308{
14309return __inet_aton ();
14310  ;
14311  return 0;
14312}
14313_ACEOF
14314if ac_fn_c_try_link "$LINENO"
14315then :
14316  ac_cv_lib_resolv___inet_aton=yes
14317else $as_nop
14318  ac_cv_lib_resolv___inet_aton=no
14319fi
14320rm -f core conftest.err conftest.$ac_objext conftest.beam \
14321    conftest$ac_exeext conftest.$ac_ext
14322LIBS=$ac_check_lib_save_LIBS
14323fi
14324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___inet_aton" >&5
14325printf "%s\n" "$ac_cv_lib_resolv___inet_aton" >&6; }
14326if test "x$ac_cv_lib_resolv___inet_aton" = xyes
14327then :
14328  found=yes
14329else $as_nop
14330  found=no
14331fi
14332
14333
14334fi
14335
14336
14337  if test "$found" = "yes"; then
14338    ac_libs=$LIBS
14339    LIBS="$LIBS -lresolv"
14340    if test "$cross_compiling" = yes
14341then :
14342
14343            found=yes
14344
14345else $as_nop
14346  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14347/* end confdefs.h.  */
14348int main() { return (0); }
14349_ACEOF
14350if ac_fn_c_try_run "$LINENO"
14351then :
14352  found=yes
14353else $as_nop
14354  found=no
14355fi
14356rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14357  conftest.$ac_objext conftest.beam conftest.$ac_ext
14358fi
14359
14360    LIBS=$ac_libs
14361  fi
14362
14363  if test "$found" = "yes"; then
14364
14365
14366  case resolv in
14367  c|c_r) ;;
14368  *)
14369      LIBS="-lresolv $LIBS"
14370   ;;
14371  esac
14372
14373
14374
14375printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
14376
14377
14378printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
14379
14380    ac_cv_func_inet_aton=yes
14381  else
14382
14383
14384  unset ac_cv_lib_bind_inet_aton
14385  unset ac_cv_lib_bind___inet_aton
14386  unset found
14387  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton in -lbind" >&5
14388printf %s "checking for inet_aton in -lbind... " >&6; }
14389if test ${ac_cv_lib_bind_inet_aton+y}
14390then :
14391  printf %s "(cached) " >&6
14392else $as_nop
14393  ac_check_lib_save_LIBS=$LIBS
14394LIBS="-lbind  $LIBS"
14395cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14396/* end confdefs.h.  */
14397
14398/* Override any GCC internal prototype to avoid an error.
14399   Use char because int might match the return type of a GCC
14400   builtin and then its argument prototype would still apply.  */
14401char inet_aton ();
14402int
14403main (void)
14404{
14405return inet_aton ();
14406  ;
14407  return 0;
14408}
14409_ACEOF
14410if ac_fn_c_try_link "$LINENO"
14411then :
14412  ac_cv_lib_bind_inet_aton=yes
14413else $as_nop
14414  ac_cv_lib_bind_inet_aton=no
14415fi
14416rm -f core conftest.err conftest.$ac_objext conftest.beam \
14417    conftest$ac_exeext conftest.$ac_ext
14418LIBS=$ac_check_lib_save_LIBS
14419fi
14420{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_inet_aton" >&5
14421printf "%s\n" "$ac_cv_lib_bind_inet_aton" >&6; }
14422if test "x$ac_cv_lib_bind_inet_aton" = xyes
14423then :
14424  found=yes
14425else $as_nop
14426
14427    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __inet_aton in -lbind" >&5
14428printf %s "checking for __inet_aton in -lbind... " >&6; }
14429if test ${ac_cv_lib_bind___inet_aton+y}
14430then :
14431  printf %s "(cached) " >&6
14432else $as_nop
14433  ac_check_lib_save_LIBS=$LIBS
14434LIBS="-lbind  $LIBS"
14435cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14436/* end confdefs.h.  */
14437
14438/* Override any GCC internal prototype to avoid an error.
14439   Use char because int might match the return type of a GCC
14440   builtin and then its argument prototype would still apply.  */
14441char __inet_aton ();
14442int
14443main (void)
14444{
14445return __inet_aton ();
14446  ;
14447  return 0;
14448}
14449_ACEOF
14450if ac_fn_c_try_link "$LINENO"
14451then :
14452  ac_cv_lib_bind___inet_aton=yes
14453else $as_nop
14454  ac_cv_lib_bind___inet_aton=no
14455fi
14456rm -f core conftest.err conftest.$ac_objext conftest.beam \
14457    conftest$ac_exeext conftest.$ac_ext
14458LIBS=$ac_check_lib_save_LIBS
14459fi
14460{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___inet_aton" >&5
14461printf "%s\n" "$ac_cv_lib_bind___inet_aton" >&6; }
14462if test "x$ac_cv_lib_bind___inet_aton" = xyes
14463then :
14464  found=yes
14465else $as_nop
14466  found=no
14467fi
14468
14469
14470fi
14471
14472
14473  if test "$found" = "yes"; then
14474    ac_libs=$LIBS
14475    LIBS="$LIBS -lbind"
14476    if test "$cross_compiling" = yes
14477then :
14478
14479            found=yes
14480
14481else $as_nop
14482  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14483/* end confdefs.h.  */
14484int main() { return (0); }
14485_ACEOF
14486if ac_fn_c_try_run "$LINENO"
14487then :
14488  found=yes
14489else $as_nop
14490  found=no
14491fi
14492rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14493  conftest.$ac_objext conftest.beam conftest.$ac_ext
14494fi
14495
14496    LIBS=$ac_libs
14497  fi
14498
14499  if test "$found" = "yes"; then
14500
14501
14502  case bind in
14503  c|c_r) ;;
14504  *)
14505      LIBS="-lbind $LIBS"
14506   ;;
14507  esac
14508
14509
14510
14511printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
14512
14513
14514printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
14515
14516    ac_cv_func_inet_aton=yes
14517  else
14518
14519  :
14520
14521  fi
14522
14523
14524  fi
14525
14526 ;;
14527
14528  esac
14529
14530
14531
14532ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "
14533#ifdef HAVE_SYS_PARAM_H
14534#include <sys/param.h>
14535#endif
14536#ifdef HAVE_SYS_TYPES_H
14537#include <sys/types.h>
14538#endif
14539#ifdef HAVE_SYS_TIME_H
14540#include <sys/time.h>
14541#endif
14542#ifdef HAVE_NETINET_IN_H
14543#include <netinet/in.h>
14544#endif
14545#ifdef HAVE_ARPA_NAMESER_H
14546#include <arpa/nameser.h>
14547#endif
14548
14549"
14550if test "x$ac_cv_header_stdint_h" = xyes
14551then :
14552  printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
14553
14554fi
14555ac_fn_c_check_header_compile "$LINENO" "dirent.h" "ac_cv_header_dirent_h" "
14556#ifdef HAVE_SYS_PARAM_H
14557#include <sys/param.h>
14558#endif
14559#ifdef HAVE_SYS_TYPES_H
14560#include <sys/types.h>
14561#endif
14562#ifdef HAVE_SYS_TIME_H
14563#include <sys/time.h>
14564#endif
14565#ifdef HAVE_NETINET_IN_H
14566#include <netinet/in.h>
14567#endif
14568#ifdef HAVE_ARPA_NAMESER_H
14569#include <arpa/nameser.h>
14570#endif
14571
14572"
14573if test "x$ac_cv_header_dirent_h" = xyes
14574then :
14575  printf "%s\n" "#define HAVE_DIRENT_H 1" >>confdefs.h
14576
14577fi
14578ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "
14579#ifdef HAVE_SYS_PARAM_H
14580#include <sys/param.h>
14581#endif
14582#ifdef HAVE_SYS_TYPES_H
14583#include <sys/types.h>
14584#endif
14585#ifdef HAVE_SYS_TIME_H
14586#include <sys/time.h>
14587#endif
14588#ifdef HAVE_NETINET_IN_H
14589#include <netinet/in.h>
14590#endif
14591#ifdef HAVE_ARPA_NAMESER_H
14592#include <arpa/nameser.h>
14593#endif
14594
14595"
14596if test "x$ac_cv_header_sys_param_h" = xyes
14597then :
14598  printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h
14599
14600fi
14601ac_fn_c_check_header_compile "$LINENO" "sys/types.h" "ac_cv_header_sys_types_h" "
14602#ifdef HAVE_SYS_PARAM_H
14603#include <sys/param.h>
14604#endif
14605#ifdef HAVE_SYS_TYPES_H
14606#include <sys/types.h>
14607#endif
14608#ifdef HAVE_SYS_TIME_H
14609#include <sys/time.h>
14610#endif
14611#ifdef HAVE_NETINET_IN_H
14612#include <netinet/in.h>
14613#endif
14614#ifdef HAVE_ARPA_NAMESER_H
14615#include <arpa/nameser.h>
14616#endif
14617
14618"
14619if test "x$ac_cv_header_sys_types_h" = xyes
14620then :
14621  printf "%s\n" "#define HAVE_SYS_TYPES_H 1" >>confdefs.h
14622
14623fi
14624ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "
14625#ifdef HAVE_SYS_PARAM_H
14626#include <sys/param.h>
14627#endif
14628#ifdef HAVE_SYS_TYPES_H
14629#include <sys/types.h>
14630#endif
14631#ifdef HAVE_SYS_TIME_H
14632#include <sys/time.h>
14633#endif
14634#ifdef HAVE_NETINET_IN_H
14635#include <netinet/in.h>
14636#endif
14637#ifdef HAVE_ARPA_NAMESER_H
14638#include <arpa/nameser.h>
14639#endif
14640
14641"
14642if test "x$ac_cv_header_sys_time_h" = xyes
14643then :
14644  printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h
14645
14646fi
14647ac_fn_c_check_header_compile "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "
14648#ifdef HAVE_SYS_PARAM_H
14649#include <sys/param.h>
14650#endif
14651#ifdef HAVE_SYS_TYPES_H
14652#include <sys/types.h>
14653#endif
14654#ifdef HAVE_SYS_TIME_H
14655#include <sys/time.h>
14656#endif
14657#ifdef HAVE_NETINET_IN_H
14658#include <netinet/in.h>
14659#endif
14660#ifdef HAVE_ARPA_NAMESER_H
14661#include <arpa/nameser.h>
14662#endif
14663
14664"
14665if test "x$ac_cv_header_netinet_in_h" = xyes
14666then :
14667  printf "%s\n" "#define HAVE_NETINET_IN_H 1" >>confdefs.h
14668
14669fi
14670ac_fn_c_check_header_compile "$LINENO" "alloca.h" "ac_cv_header_alloca_h" "
14671#ifdef HAVE_SYS_PARAM_H
14672#include <sys/param.h>
14673#endif
14674#ifdef HAVE_SYS_TYPES_H
14675#include <sys/types.h>
14676#endif
14677#ifdef HAVE_SYS_TIME_H
14678#include <sys/time.h>
14679#endif
14680#ifdef HAVE_NETINET_IN_H
14681#include <netinet/in.h>
14682#endif
14683#ifdef HAVE_ARPA_NAMESER_H
14684#include <arpa/nameser.h>
14685#endif
14686
14687"
14688if test "x$ac_cv_header_alloca_h" = xyes
14689then :
14690  printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
14691
14692fi
14693ac_fn_c_check_header_compile "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "
14694#ifdef HAVE_SYS_PARAM_H
14695#include <sys/param.h>
14696#endif
14697#ifdef HAVE_SYS_TYPES_H
14698#include <sys/types.h>
14699#endif
14700#ifdef HAVE_SYS_TIME_H
14701#include <sys/time.h>
14702#endif
14703#ifdef HAVE_NETINET_IN_H
14704#include <netinet/in.h>
14705#endif
14706#ifdef HAVE_ARPA_NAMESER_H
14707#include <arpa/nameser.h>
14708#endif
14709
14710"
14711if test "x$ac_cv_header_arpa_inet_h" = xyes
14712then :
14713  printf "%s\n" "#define HAVE_ARPA_INET_H 1" >>confdefs.h
14714
14715fi
14716ac_fn_c_check_header_compile "$LINENO" "arpa/nameser.h" "ac_cv_header_arpa_nameser_h" "
14717#ifdef HAVE_SYS_PARAM_H
14718#include <sys/param.h>
14719#endif
14720#ifdef HAVE_SYS_TYPES_H
14721#include <sys/types.h>
14722#endif
14723#ifdef HAVE_SYS_TIME_H
14724#include <sys/time.h>
14725#endif
14726#ifdef HAVE_NETINET_IN_H
14727#include <netinet/in.h>
14728#endif
14729#ifdef HAVE_ARPA_NAMESER_H
14730#include <arpa/nameser.h>
14731#endif
14732
14733"
14734if test "x$ac_cv_header_arpa_nameser_h" = xyes
14735then :
14736  printf "%s\n" "#define HAVE_ARPA_NAMESER_H 1" >>confdefs.h
14737
14738fi
14739ac_fn_c_check_header_compile "$LINENO" "crypt.h" "ac_cv_header_crypt_h" "
14740#ifdef HAVE_SYS_PARAM_H
14741#include <sys/param.h>
14742#endif
14743#ifdef HAVE_SYS_TYPES_H
14744#include <sys/types.h>
14745#endif
14746#ifdef HAVE_SYS_TIME_H
14747#include <sys/time.h>
14748#endif
14749#ifdef HAVE_NETINET_IN_H
14750#include <netinet/in.h>
14751#endif
14752#ifdef HAVE_ARPA_NAMESER_H
14753#include <arpa/nameser.h>
14754#endif
14755
14756"
14757if test "x$ac_cv_header_crypt_h" = xyes
14758then :
14759  printf "%s\n" "#define HAVE_CRYPT_H 1" >>confdefs.h
14760
14761fi
14762ac_fn_c_check_header_compile "$LINENO" "dns.h" "ac_cv_header_dns_h" "
14763#ifdef HAVE_SYS_PARAM_H
14764#include <sys/param.h>
14765#endif
14766#ifdef HAVE_SYS_TYPES_H
14767#include <sys/types.h>
14768#endif
14769#ifdef HAVE_SYS_TIME_H
14770#include <sys/time.h>
14771#endif
14772#ifdef HAVE_NETINET_IN_H
14773#include <netinet/in.h>
14774#endif
14775#ifdef HAVE_ARPA_NAMESER_H
14776#include <arpa/nameser.h>
14777#endif
14778
14779"
14780if test "x$ac_cv_header_dns_h" = xyes
14781then :
14782  printf "%s\n" "#define HAVE_DNS_H 1" >>confdefs.h
14783
14784fi
14785ac_fn_c_check_header_compile "$LINENO" "fcntl.h" "ac_cv_header_fcntl_h" "
14786#ifdef HAVE_SYS_PARAM_H
14787#include <sys/param.h>
14788#endif
14789#ifdef HAVE_SYS_TYPES_H
14790#include <sys/types.h>
14791#endif
14792#ifdef HAVE_SYS_TIME_H
14793#include <sys/time.h>
14794#endif
14795#ifdef HAVE_NETINET_IN_H
14796#include <netinet/in.h>
14797#endif
14798#ifdef HAVE_ARPA_NAMESER_H
14799#include <arpa/nameser.h>
14800#endif
14801
14802"
14803if test "x$ac_cv_header_fcntl_h" = xyes
14804then :
14805  printf "%s\n" "#define HAVE_FCNTL_H 1" >>confdefs.h
14806
14807fi
14808ac_fn_c_check_header_compile "$LINENO" "grp.h" "ac_cv_header_grp_h" "
14809#ifdef HAVE_SYS_PARAM_H
14810#include <sys/param.h>
14811#endif
14812#ifdef HAVE_SYS_TYPES_H
14813#include <sys/types.h>
14814#endif
14815#ifdef HAVE_SYS_TIME_H
14816#include <sys/time.h>
14817#endif
14818#ifdef HAVE_NETINET_IN_H
14819#include <netinet/in.h>
14820#endif
14821#ifdef HAVE_ARPA_NAMESER_H
14822#include <arpa/nameser.h>
14823#endif
14824
14825"
14826if test "x$ac_cv_header_grp_h" = xyes
14827then :
14828  printf "%s\n" "#define HAVE_GRP_H 1" >>confdefs.h
14829
14830fi
14831ac_fn_c_check_header_compile "$LINENO" "ieeefp.h" "ac_cv_header_ieeefp_h" "
14832#ifdef HAVE_SYS_PARAM_H
14833#include <sys/param.h>
14834#endif
14835#ifdef HAVE_SYS_TYPES_H
14836#include <sys/types.h>
14837#endif
14838#ifdef HAVE_SYS_TIME_H
14839#include <sys/time.h>
14840#endif
14841#ifdef HAVE_NETINET_IN_H
14842#include <netinet/in.h>
14843#endif
14844#ifdef HAVE_ARPA_NAMESER_H
14845#include <arpa/nameser.h>
14846#endif
14847
14848"
14849if test "x$ac_cv_header_ieeefp_h" = xyes
14850then :
14851  printf "%s\n" "#define HAVE_IEEEFP_H 1" >>confdefs.h
14852
14853fi
14854ac_fn_c_check_header_compile "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "
14855#ifdef HAVE_SYS_PARAM_H
14856#include <sys/param.h>
14857#endif
14858#ifdef HAVE_SYS_TYPES_H
14859#include <sys/types.h>
14860#endif
14861#ifdef HAVE_SYS_TIME_H
14862#include <sys/time.h>
14863#endif
14864#ifdef HAVE_NETINET_IN_H
14865#include <netinet/in.h>
14866#endif
14867#ifdef HAVE_ARPA_NAMESER_H
14868#include <arpa/nameser.h>
14869#endif
14870
14871"
14872if test "x$ac_cv_header_langinfo_h" = xyes
14873then :
14874  printf "%s\n" "#define HAVE_LANGINFO_H 1" >>confdefs.h
14875
14876fi
14877ac_fn_c_check_header_compile "$LINENO" "malloc.h" "ac_cv_header_malloc_h" "
14878#ifdef HAVE_SYS_PARAM_H
14879#include <sys/param.h>
14880#endif
14881#ifdef HAVE_SYS_TYPES_H
14882#include <sys/types.h>
14883#endif
14884#ifdef HAVE_SYS_TIME_H
14885#include <sys/time.h>
14886#endif
14887#ifdef HAVE_NETINET_IN_H
14888#include <netinet/in.h>
14889#endif
14890#ifdef HAVE_ARPA_NAMESER_H
14891#include <arpa/nameser.h>
14892#endif
14893
14894"
14895if test "x$ac_cv_header_malloc_h" = xyes
14896then :
14897  printf "%s\n" "#define HAVE_MALLOC_H 1" >>confdefs.h
14898
14899fi
14900ac_fn_c_check_header_compile "$LINENO" "poll.h" "ac_cv_header_poll_h" "
14901#ifdef HAVE_SYS_PARAM_H
14902#include <sys/param.h>
14903#endif
14904#ifdef HAVE_SYS_TYPES_H
14905#include <sys/types.h>
14906#endif
14907#ifdef HAVE_SYS_TIME_H
14908#include <sys/time.h>
14909#endif
14910#ifdef HAVE_NETINET_IN_H
14911#include <netinet/in.h>
14912#endif
14913#ifdef HAVE_ARPA_NAMESER_H
14914#include <arpa/nameser.h>
14915#endif
14916
14917"
14918if test "x$ac_cv_header_poll_h" = xyes
14919then :
14920  printf "%s\n" "#define HAVE_POLL_H 1" >>confdefs.h
14921
14922fi
14923ac_fn_c_check_header_compile "$LINENO" "pty.h" "ac_cv_header_pty_h" "
14924#ifdef HAVE_SYS_PARAM_H
14925#include <sys/param.h>
14926#endif
14927#ifdef HAVE_SYS_TYPES_H
14928#include <sys/types.h>
14929#endif
14930#ifdef HAVE_SYS_TIME_H
14931#include <sys/time.h>
14932#endif
14933#ifdef HAVE_NETINET_IN_H
14934#include <netinet/in.h>
14935#endif
14936#ifdef HAVE_ARPA_NAMESER_H
14937#include <arpa/nameser.h>
14938#endif
14939
14940"
14941if test "x$ac_cv_header_pty_h" = xyes
14942then :
14943  printf "%s\n" "#define HAVE_PTY_H 1" >>confdefs.h
14944
14945fi
14946ac_fn_c_check_header_compile "$LINENO" "pwd.h" "ac_cv_header_pwd_h" "
14947#ifdef HAVE_SYS_PARAM_H
14948#include <sys/param.h>
14949#endif
14950#ifdef HAVE_SYS_TYPES_H
14951#include <sys/types.h>
14952#endif
14953#ifdef HAVE_SYS_TIME_H
14954#include <sys/time.h>
14955#endif
14956#ifdef HAVE_NETINET_IN_H
14957#include <netinet/in.h>
14958#endif
14959#ifdef HAVE_ARPA_NAMESER_H
14960#include <arpa/nameser.h>
14961#endif
14962
14963"
14964if test "x$ac_cv_header_pwd_h" = xyes
14965then :
14966  printf "%s\n" "#define HAVE_PWD_H 1" >>confdefs.h
14967
14968fi
14969ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" "
14970#ifdef HAVE_SYS_PARAM_H
14971#include <sys/param.h>
14972#endif
14973#ifdef HAVE_SYS_TYPES_H
14974#include <sys/types.h>
14975#endif
14976#ifdef HAVE_SYS_TIME_H
14977#include <sys/time.h>
14978#endif
14979#ifdef HAVE_NETINET_IN_H
14980#include <netinet/in.h>
14981#endif
14982#ifdef HAVE_ARPA_NAMESER_H
14983#include <arpa/nameser.h>
14984#endif
14985
14986"
14987if test "x$ac_cv_header_resolv_h" = xyes
14988then :
14989  printf "%s\n" "#define HAVE_RESOLV_H 1" >>confdefs.h
14990
14991fi
14992ac_fn_c_check_header_compile "$LINENO" "strings.h" "ac_cv_header_strings_h" "
14993#ifdef HAVE_SYS_PARAM_H
14994#include <sys/param.h>
14995#endif
14996#ifdef HAVE_SYS_TYPES_H
14997#include <sys/types.h>
14998#endif
14999#ifdef HAVE_SYS_TIME_H
15000#include <sys/time.h>
15001#endif
15002#ifdef HAVE_NETINET_IN_H
15003#include <netinet/in.h>
15004#endif
15005#ifdef HAVE_ARPA_NAMESER_H
15006#include <arpa/nameser.h>
15007#endif
15008
15009"
15010if test "x$ac_cv_header_strings_h" = xyes
15011then :
15012  printf "%s\n" "#define HAVE_STRINGS_H 1" >>confdefs.h
15013
15014fi
15015ac_fn_c_check_header_compile "$LINENO" "syslog.h" "ac_cv_header_syslog_h" "
15016#ifdef HAVE_SYS_PARAM_H
15017#include <sys/param.h>
15018#endif
15019#ifdef HAVE_SYS_TYPES_H
15020#include <sys/types.h>
15021#endif
15022#ifdef HAVE_SYS_TIME_H
15023#include <sys/time.h>
15024#endif
15025#ifdef HAVE_NETINET_IN_H
15026#include <netinet/in.h>
15027#endif
15028#ifdef HAVE_ARPA_NAMESER_H
15029#include <arpa/nameser.h>
15030#endif
15031
15032"
15033if test "x$ac_cv_header_syslog_h" = xyes
15034then :
15035  printf "%s\n" "#define HAVE_SYSLOG_H 1" >>confdefs.h
15036
15037fi
15038ac_fn_c_check_header_compile "$LINENO" "sysexits.h" "ac_cv_header_sysexits_h" "
15039#ifdef HAVE_SYS_PARAM_H
15040#include <sys/param.h>
15041#endif
15042#ifdef HAVE_SYS_TYPES_H
15043#include <sys/types.h>
15044#endif
15045#ifdef HAVE_SYS_TIME_H
15046#include <sys/time.h>
15047#endif
15048#ifdef HAVE_NETINET_IN_H
15049#include <netinet/in.h>
15050#endif
15051#ifdef HAVE_ARPA_NAMESER_H
15052#include <arpa/nameser.h>
15053#endif
15054
15055"
15056if test "x$ac_cv_header_sysexits_h" = xyes
15057then :
15058  printf "%s\n" "#define HAVE_SYSEXITS_H 1" >>confdefs.h
15059
15060fi
15061ac_fn_c_check_header_compile "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "
15062#ifdef HAVE_SYS_PARAM_H
15063#include <sys/param.h>
15064#endif
15065#ifdef HAVE_SYS_TYPES_H
15066#include <sys/types.h>
15067#endif
15068#ifdef HAVE_SYS_TIME_H
15069#include <sys/time.h>
15070#endif
15071#ifdef HAVE_NETINET_IN_H
15072#include <netinet/in.h>
15073#endif
15074#ifdef HAVE_ARPA_NAMESER_H
15075#include <arpa/nameser.h>
15076#endif
15077
15078"
15079if test "x$ac_cv_header_sys_ioctl_h" = xyes
15080then :
15081  printf "%s\n" "#define HAVE_SYS_IOCTL_H 1" >>confdefs.h
15082
15083fi
15084ac_fn_c_check_header_compile "$LINENO" "sys/file.h" "ac_cv_header_sys_file_h" "
15085#ifdef HAVE_SYS_PARAM_H
15086#include <sys/param.h>
15087#endif
15088#ifdef HAVE_SYS_TYPES_H
15089#include <sys/types.h>
15090#endif
15091#ifdef HAVE_SYS_TIME_H
15092#include <sys/time.h>
15093#endif
15094#ifdef HAVE_NETINET_IN_H
15095#include <netinet/in.h>
15096#endif
15097#ifdef HAVE_ARPA_NAMESER_H
15098#include <arpa/nameser.h>
15099#endif
15100
15101"
15102if test "x$ac_cv_header_sys_file_h" = xyes
15103then :
15104  printf "%s\n" "#define HAVE_SYS_FILE_H 1" >>confdefs.h
15105
15106fi
15107ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "
15108#ifdef HAVE_SYS_PARAM_H
15109#include <sys/param.h>
15110#endif
15111#ifdef HAVE_SYS_TYPES_H
15112#include <sys/types.h>
15113#endif
15114#ifdef HAVE_SYS_TIME_H
15115#include <sys/time.h>
15116#endif
15117#ifdef HAVE_NETINET_IN_H
15118#include <netinet/in.h>
15119#endif
15120#ifdef HAVE_ARPA_NAMESER_H
15121#include <arpa/nameser.h>
15122#endif
15123
15124"
15125if test "x$ac_cv_header_sys_mman_h" = xyes
15126then :
15127  printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h
15128
15129fi
15130ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" "
15131#ifdef HAVE_SYS_PARAM_H
15132#include <sys/param.h>
15133#endif
15134#ifdef HAVE_SYS_TYPES_H
15135#include <sys/types.h>
15136#endif
15137#ifdef HAVE_SYS_TIME_H
15138#include <sys/time.h>
15139#endif
15140#ifdef HAVE_NETINET_IN_H
15141#include <netinet/in.h>
15142#endif
15143#ifdef HAVE_ARPA_NAMESER_H
15144#include <arpa/nameser.h>
15145#endif
15146
15147"
15148if test "x$ac_cv_header_sys_mount_h" = xyes
15149then :
15150  printf "%s\n" "#define HAVE_SYS_MOUNT_H 1" >>confdefs.h
15151
15152fi
15153ac_fn_c_check_header_compile "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "
15154#ifdef HAVE_SYS_PARAM_H
15155#include <sys/param.h>
15156#endif
15157#ifdef HAVE_SYS_TYPES_H
15158#include <sys/types.h>
15159#endif
15160#ifdef HAVE_SYS_TIME_H
15161#include <sys/time.h>
15162#endif
15163#ifdef HAVE_NETINET_IN_H
15164#include <netinet/in.h>
15165#endif
15166#ifdef HAVE_ARPA_NAMESER_H
15167#include <arpa/nameser.h>
15168#endif
15169
15170"
15171if test "x$ac_cv_header_sys_poll_h" = xyes
15172then :
15173  printf "%s\n" "#define HAVE_SYS_POLL_H 1" >>confdefs.h
15174
15175fi
15176ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "
15177#ifdef HAVE_SYS_PARAM_H
15178#include <sys/param.h>
15179#endif
15180#ifdef HAVE_SYS_TYPES_H
15181#include <sys/types.h>
15182#endif
15183#ifdef HAVE_SYS_TIME_H
15184#include <sys/time.h>
15185#endif
15186#ifdef HAVE_NETINET_IN_H
15187#include <netinet/in.h>
15188#endif
15189#ifdef HAVE_ARPA_NAMESER_H
15190#include <arpa/nameser.h>
15191#endif
15192
15193"
15194if test "x$ac_cv_header_sys_resource_h" = xyes
15195then :
15196  printf "%s\n" "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h
15197
15198fi
15199ac_fn_c_check_header_compile "$LINENO" "sys/select.h" "ac_cv_header_sys_select_h" "
15200#ifdef HAVE_SYS_PARAM_H
15201#include <sys/param.h>
15202#endif
15203#ifdef HAVE_SYS_TYPES_H
15204#include <sys/types.h>
15205#endif
15206#ifdef HAVE_SYS_TIME_H
15207#include <sys/time.h>
15208#endif
15209#ifdef HAVE_NETINET_IN_H
15210#include <netinet/in.h>
15211#endif
15212#ifdef HAVE_ARPA_NAMESER_H
15213#include <arpa/nameser.h>
15214#endif
15215
15216"
15217if test "x$ac_cv_header_sys_select_h" = xyes
15218then :
15219  printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h
15220
15221fi
15222ac_fn_c_check_header_compile "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "
15223#ifdef HAVE_SYS_PARAM_H
15224#include <sys/param.h>
15225#endif
15226#ifdef HAVE_SYS_TYPES_H
15227#include <sys/types.h>
15228#endif
15229#ifdef HAVE_SYS_TIME_H
15230#include <sys/time.h>
15231#endif
15232#ifdef HAVE_NETINET_IN_H
15233#include <netinet/in.h>
15234#endif
15235#ifdef HAVE_ARPA_NAMESER_H
15236#include <arpa/nameser.h>
15237#endif
15238
15239"
15240if test "x$ac_cv_header_sys_socket_h" = xyes
15241then :
15242  printf "%s\n" "#define HAVE_SYS_SOCKET_H 1" >>confdefs.h
15243
15244fi
15245ac_fn_c_check_header_compile "$LINENO" "sys/stat.h" "ac_cv_header_sys_stat_h" "
15246#ifdef HAVE_SYS_PARAM_H
15247#include <sys/param.h>
15248#endif
15249#ifdef HAVE_SYS_TYPES_H
15250#include <sys/types.h>
15251#endif
15252#ifdef HAVE_SYS_TIME_H
15253#include <sys/time.h>
15254#endif
15255#ifdef HAVE_NETINET_IN_H
15256#include <netinet/in.h>
15257#endif
15258#ifdef HAVE_ARPA_NAMESER_H
15259#include <arpa/nameser.h>
15260#endif
15261
15262"
15263if test "x$ac_cv_header_sys_stat_h" = xyes
15264then :
15265  printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h
15266
15267fi
15268ac_fn_c_check_header_compile "$LINENO" "sys/statfs.h" "ac_cv_header_sys_statfs_h" "
15269#ifdef HAVE_SYS_PARAM_H
15270#include <sys/param.h>
15271#endif
15272#ifdef HAVE_SYS_TYPES_H
15273#include <sys/types.h>
15274#endif
15275#ifdef HAVE_SYS_TIME_H
15276#include <sys/time.h>
15277#endif
15278#ifdef HAVE_NETINET_IN_H
15279#include <netinet/in.h>
15280#endif
15281#ifdef HAVE_ARPA_NAMESER_H
15282#include <arpa/nameser.h>
15283#endif
15284
15285"
15286if test "x$ac_cv_header_sys_statfs_h" = xyes
15287then :
15288  printf "%s\n" "#define HAVE_SYS_STATFS_H 1" >>confdefs.h
15289
15290fi
15291ac_fn_c_check_header_compile "$LINENO" "sys/statvfs.h" "ac_cv_header_sys_statvfs_h" "
15292#ifdef HAVE_SYS_PARAM_H
15293#include <sys/param.h>
15294#endif
15295#ifdef HAVE_SYS_TYPES_H
15296#include <sys/types.h>
15297#endif
15298#ifdef HAVE_SYS_TIME_H
15299#include <sys/time.h>
15300#endif
15301#ifdef HAVE_NETINET_IN_H
15302#include <netinet/in.h>
15303#endif
15304#ifdef HAVE_ARPA_NAMESER_H
15305#include <arpa/nameser.h>
15306#endif
15307
15308"
15309if test "x$ac_cv_header_sys_statvfs_h" = xyes
15310then :
15311  printf "%s\n" "#define HAVE_SYS_STATVFS_H 1" >>confdefs.h
15312
15313fi
15314ac_fn_c_check_header_compile "$LINENO" "sys/vfs.h" "ac_cv_header_sys_vfs_h" "
15315#ifdef HAVE_SYS_PARAM_H
15316#include <sys/param.h>
15317#endif
15318#ifdef HAVE_SYS_TYPES_H
15319#include <sys/types.h>
15320#endif
15321#ifdef HAVE_SYS_TIME_H
15322#include <sys/time.h>
15323#endif
15324#ifdef HAVE_NETINET_IN_H
15325#include <netinet/in.h>
15326#endif
15327#ifdef HAVE_ARPA_NAMESER_H
15328#include <arpa/nameser.h>
15329#endif
15330
15331"
15332if test "x$ac_cv_header_sys_vfs_h" = xyes
15333then :
15334  printf "%s\n" "#define HAVE_SYS_VFS_H 1" >>confdefs.h
15335
15336fi
15337ac_fn_c_check_header_compile "$LINENO" "sys/sysexits.h" "ac_cv_header_sys_sysexits_h" "
15338#ifdef HAVE_SYS_PARAM_H
15339#include <sys/param.h>
15340#endif
15341#ifdef HAVE_SYS_TYPES_H
15342#include <sys/types.h>
15343#endif
15344#ifdef HAVE_SYS_TIME_H
15345#include <sys/time.h>
15346#endif
15347#ifdef HAVE_NETINET_IN_H
15348#include <netinet/in.h>
15349#endif
15350#ifdef HAVE_ARPA_NAMESER_H
15351#include <arpa/nameser.h>
15352#endif
15353
15354"
15355if test "x$ac_cv_header_sys_sysexits_h" = xyes
15356then :
15357  printf "%s\n" "#define HAVE_SYS_SYSEXITS_H 1" >>confdefs.h
15358
15359fi
15360ac_fn_c_check_header_compile "$LINENO" "sys/uio.h" "ac_cv_header_sys_uio_h" "
15361#ifdef HAVE_SYS_PARAM_H
15362#include <sys/param.h>
15363#endif
15364#ifdef HAVE_SYS_TYPES_H
15365#include <sys/types.h>
15366#endif
15367#ifdef HAVE_SYS_TIME_H
15368#include <sys/time.h>
15369#endif
15370#ifdef HAVE_NETINET_IN_H
15371#include <netinet/in.h>
15372#endif
15373#ifdef HAVE_ARPA_NAMESER_H
15374#include <arpa/nameser.h>
15375#endif
15376
15377"
15378if test "x$ac_cv_header_sys_uio_h" = xyes
15379then :
15380  printf "%s\n" "#define HAVE_SYS_UIO_H 1" >>confdefs.h
15381
15382fi
15383ac_fn_c_check_header_compile "$LINENO" "sys/wait.h" "ac_cv_header_sys_wait_h" "
15384#ifdef HAVE_SYS_PARAM_H
15385#include <sys/param.h>
15386#endif
15387#ifdef HAVE_SYS_TYPES_H
15388#include <sys/types.h>
15389#endif
15390#ifdef HAVE_SYS_TIME_H
15391#include <sys/time.h>
15392#endif
15393#ifdef HAVE_NETINET_IN_H
15394#include <netinet/in.h>
15395#endif
15396#ifdef HAVE_ARPA_NAMESER_H
15397#include <arpa/nameser.h>
15398#endif
15399
15400"
15401if test "x$ac_cv_header_sys_wait_h" = xyes
15402then :
15403  printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
15404
15405fi
15406ac_fn_c_check_header_compile "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "
15407#ifdef HAVE_SYS_PARAM_H
15408#include <sys/param.h>
15409#endif
15410#ifdef HAVE_SYS_TYPES_H
15411#include <sys/types.h>
15412#endif
15413#ifdef HAVE_SYS_TIME_H
15414#include <sys/time.h>
15415#endif
15416#ifdef HAVE_NETINET_IN_H
15417#include <netinet/in.h>
15418#endif
15419#ifdef HAVE_ARPA_NAMESER_H
15420#include <arpa/nameser.h>
15421#endif
15422
15423"
15424if test "x$ac_cv_header_sys_loadavg_h" = xyes
15425then :
15426  printf "%s\n" "#define HAVE_SYS_LOADAVG_H 1" >>confdefs.h
15427
15428fi
15429ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "
15430#ifdef HAVE_SYS_PARAM_H
15431#include <sys/param.h>
15432#endif
15433#ifdef HAVE_SYS_TYPES_H
15434#include <sys/types.h>
15435#endif
15436#ifdef HAVE_SYS_TIME_H
15437#include <sys/time.h>
15438#endif
15439#ifdef HAVE_NETINET_IN_H
15440#include <netinet/in.h>
15441#endif
15442#ifdef HAVE_ARPA_NAMESER_H
15443#include <arpa/nameser.h>
15444#endif
15445
15446"
15447if test "x$ac_cv_header_unistd_h" = xyes
15448then :
15449  printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
15450
15451fi
15452ac_fn_c_check_header_compile "$LINENO" "unix.h" "ac_cv_header_unix_h" "
15453#ifdef HAVE_SYS_PARAM_H
15454#include <sys/param.h>
15455#endif
15456#ifdef HAVE_SYS_TYPES_H
15457#include <sys/types.h>
15458#endif
15459#ifdef HAVE_SYS_TIME_H
15460#include <sys/time.h>
15461#endif
15462#ifdef HAVE_NETINET_IN_H
15463#include <netinet/in.h>
15464#endif
15465#ifdef HAVE_ARPA_NAMESER_H
15466#include <arpa/nameser.h>
15467#endif
15468
15469"
15470if test "x$ac_cv_header_unix_h" = xyes
15471then :
15472  printf "%s\n" "#define HAVE_UNIX_H 1" >>confdefs.h
15473
15474fi
15475ac_fn_c_check_header_compile "$LINENO" "utime.h" "ac_cv_header_utime_h" "
15476#ifdef HAVE_SYS_PARAM_H
15477#include <sys/param.h>
15478#endif
15479#ifdef HAVE_SYS_TYPES_H
15480#include <sys/types.h>
15481#endif
15482#ifdef HAVE_SYS_TIME_H
15483#include <sys/time.h>
15484#endif
15485#ifdef HAVE_NETINET_IN_H
15486#include <netinet/in.h>
15487#endif
15488#ifdef HAVE_ARPA_NAMESER_H
15489#include <arpa/nameser.h>
15490#endif
15491
15492"
15493if test "x$ac_cv_header_utime_h" = xyes
15494then :
15495  printf "%s\n" "#define HAVE_UTIME_H 1" >>confdefs.h
15496
15497fi
15498ac_fn_c_check_header_compile "$LINENO" "sys/utsname.h" "ac_cv_header_sys_utsname_h" "
15499#ifdef HAVE_SYS_PARAM_H
15500#include <sys/param.h>
15501#endif
15502#ifdef HAVE_SYS_TYPES_H
15503#include <sys/types.h>
15504#endif
15505#ifdef HAVE_SYS_TIME_H
15506#include <sys/time.h>
15507#endif
15508#ifdef HAVE_NETINET_IN_H
15509#include <netinet/in.h>
15510#endif
15511#ifdef HAVE_ARPA_NAMESER_H
15512#include <arpa/nameser.h>
15513#endif
15514
15515"
15516if test "x$ac_cv_header_sys_utsname_h" = xyes
15517then :
15518  printf "%s\n" "#define HAVE_SYS_UTSNAME_H 1" >>confdefs.h
15519
15520fi
15521ac_fn_c_check_header_compile "$LINENO" "sys/ipc.h" "ac_cv_header_sys_ipc_h" "
15522#ifdef HAVE_SYS_PARAM_H
15523#include <sys/param.h>
15524#endif
15525#ifdef HAVE_SYS_TYPES_H
15526#include <sys/types.h>
15527#endif
15528#ifdef HAVE_SYS_TIME_H
15529#include <sys/time.h>
15530#endif
15531#ifdef HAVE_NETINET_IN_H
15532#include <netinet/in.h>
15533#endif
15534#ifdef HAVE_ARPA_NAMESER_H
15535#include <arpa/nameser.h>
15536#endif
15537
15538"
15539if test "x$ac_cv_header_sys_ipc_h" = xyes
15540then :
15541  printf "%s\n" "#define HAVE_SYS_IPC_H 1" >>confdefs.h
15542
15543fi
15544ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "
15545#ifdef HAVE_SYS_PARAM_H
15546#include <sys/param.h>
15547#endif
15548#ifdef HAVE_SYS_TYPES_H
15549#include <sys/types.h>
15550#endif
15551#ifdef HAVE_SYS_TIME_H
15552#include <sys/time.h>
15553#endif
15554#ifdef HAVE_NETINET_IN_H
15555#include <netinet/in.h>
15556#endif
15557#ifdef HAVE_ARPA_NAMESER_H
15558#include <arpa/nameser.h>
15559#endif
15560
15561"
15562if test "x$ac_cv_header_dlfcn_h" = xyes
15563then :
15564  printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h
15565
15566fi
15567ac_fn_c_check_header_compile "$LINENO" "tmmintrin.h" "ac_cv_header_tmmintrin_h" "
15568#ifdef HAVE_SYS_PARAM_H
15569#include <sys/param.h>
15570#endif
15571#ifdef HAVE_SYS_TYPES_H
15572#include <sys/types.h>
15573#endif
15574#ifdef HAVE_SYS_TIME_H
15575#include <sys/time.h>
15576#endif
15577#ifdef HAVE_NETINET_IN_H
15578#include <netinet/in.h>
15579#endif
15580#ifdef HAVE_ARPA_NAMESER_H
15581#include <arpa/nameser.h>
15582#endif
15583
15584"
15585if test "x$ac_cv_header_tmmintrin_h" = xyes
15586then :
15587  printf "%s\n" "#define HAVE_TMMINTRIN_H 1" >>confdefs.h
15588
15589fi
15590ac_fn_c_check_header_compile "$LINENO" "nmmintrin.h" "ac_cv_header_nmmintrin_h" "
15591#ifdef HAVE_SYS_PARAM_H
15592#include <sys/param.h>
15593#endif
15594#ifdef HAVE_SYS_TYPES_H
15595#include <sys/types.h>
15596#endif
15597#ifdef HAVE_SYS_TIME_H
15598#include <sys/time.h>
15599#endif
15600#ifdef HAVE_NETINET_IN_H
15601#include <netinet/in.h>
15602#endif
15603#ifdef HAVE_ARPA_NAMESER_H
15604#include <arpa/nameser.h>
15605#endif
15606
15607"
15608if test "x$ac_cv_header_nmmintrin_h" = xyes
15609then :
15610  printf "%s\n" "#define HAVE_NMMINTRIN_H 1" >>confdefs.h
15611
15612fi
15613ac_fn_c_check_header_compile "$LINENO" "wmmintrin.h" "ac_cv_header_wmmintrin_h" "
15614#ifdef HAVE_SYS_PARAM_H
15615#include <sys/param.h>
15616#endif
15617#ifdef HAVE_SYS_TYPES_H
15618#include <sys/types.h>
15619#endif
15620#ifdef HAVE_SYS_TIME_H
15621#include <sys/time.h>
15622#endif
15623#ifdef HAVE_NETINET_IN_H
15624#include <netinet/in.h>
15625#endif
15626#ifdef HAVE_ARPA_NAMESER_H
15627#include <arpa/nameser.h>
15628#endif
15629
15630"
15631if test "x$ac_cv_header_wmmintrin_h" = xyes
15632then :
15633  printf "%s\n" "#define HAVE_WMMINTRIN_H 1" >>confdefs.h
15634
15635fi
15636ac_fn_c_check_header_compile "$LINENO" "immintrin.h" "ac_cv_header_immintrin_h" "
15637#ifdef HAVE_SYS_PARAM_H
15638#include <sys/param.h>
15639#endif
15640#ifdef HAVE_SYS_TYPES_H
15641#include <sys/types.h>
15642#endif
15643#ifdef HAVE_SYS_TIME_H
15644#include <sys/time.h>
15645#endif
15646#ifdef HAVE_NETINET_IN_H
15647#include <netinet/in.h>
15648#endif
15649#ifdef HAVE_ARPA_NAMESER_H
15650#include <arpa/nameser.h>
15651#endif
15652
15653"
15654if test "x$ac_cv_header_immintrin_h" = xyes
15655then :
15656  printf "%s\n" "#define HAVE_IMMINTRIN_H 1" >>confdefs.h
15657
15658fi
15659
15660
15661
15662  ac_fn_c_check_func "$LINENO" "fopencookie" "ac_cv_func_fopencookie"
15663if test "x$ac_cv_func_fopencookie" = xyes
15664then :
15665  have_glibc_fopencookie=yes
15666fi
15667
15668
15669  if test "$have_glibc_fopencookie" = "yes"; then
15670cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15671/* end confdefs.h.  */
15672
15673#define _GNU_SOURCE
15674#include <stdio.h>
15675
15676int
15677main (void)
15678{
15679cookie_io_functions_t cookie;
15680  ;
15681  return 0;
15682}
15683_ACEOF
15684if ac_fn_c_try_compile "$LINENO"
15685then :
15686  have_cookie_io_functions_t=yes
15687fi
15688rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15689
15690    if test "$have_cookie_io_functions_t" = "yes"; then
15691      cookie_io_functions_t=cookie_io_functions_t
15692      have_fopen_cookie=yes
15693
15694if test "$cross_compiling" = yes
15695then :
15696
15697    case $host_alias in
15698    *linux*)
15699      cookie_io_functions_use_off64_t=yes
15700      ;;
15701    *)
15702      cookie_io_functions_use_off64_t=no
15703      ;;
15704  esac
15705
15706else $as_nop
15707  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15708/* end confdefs.h.  */
15709
15710#define _GNU_SOURCE
15711#include <stdio.h>
15712#include <stdlib.h>
15713
15714struct cookiedata {
15715  off64_t pos;
15716};
15717
15718ssize_t reader(void *cookie, char *buffer, size_t size)
15719{ return size; }
15720ssize_t writer(void *cookie, const char *buffer, size_t size)
15721{ return size; }
15722int closer(void *cookie)
15723{ return 0; }
15724int seeker(void *cookie, off64_t *position, int whence)
15725{ ((struct cookiedata*)cookie)->pos = *position; return 0; }
15726
15727cookie_io_functions_t funcs = {reader, writer, seeker, closer};
15728
15729int main() {
15730  struct cookiedata g = { 0 };
15731  FILE *fp = fopencookie(&g, "r", funcs);
15732
15733  if (fp && fseek(fp, 8192, SEEK_SET) == 0 && g.pos == 8192)
15734    return 0;
15735  return 1;
15736}
15737
15738
15739_ACEOF
15740if ac_fn_c_try_run "$LINENO"
15741then :
15742
15743  cookie_io_functions_use_off64_t=yes
15744
15745else $as_nop
15746
15747  cookie_io_functions_use_off64_t=no
15748
15749fi
15750rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15751  conftest.$ac_objext conftest.beam conftest.$ac_ext
15752fi
15753
15754
15755    else
15756
15757cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15758/* end confdefs.h.  */
15759
15760#define _GNU_SOURCE
15761#include <stdio.h>
15762
15763int
15764main (void)
15765{
15766_IO_cookie_io_functions_t cookie;
15767  ;
15768  return 0;
15769}
15770_ACEOF
15771if ac_fn_c_try_compile "$LINENO"
15772then :
15773  have_IO_cookie_io_functions_t=yes
15774fi
15775rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15776      if test "$have_cookie_io_functions_t" = "yes" ; then
15777        cookie_io_functions_t=_IO_cookie_io_functions_t
15778        have_fopen_cookie=yes
15779      fi
15780    fi
15781
15782    if test "$have_fopen_cookie" = "yes" ; then
15783
15784printf "%s\n" "#define HAVE_FOPENCOOKIE 1" >>confdefs.h
15785
15786
15787printf "%s\n" "#define COOKIE_IO_FUNCTIONS_T $cookie_io_functions_t" >>confdefs.h
15788
15789      if test "$cookie_io_functions_use_off64_t" = "yes" ; then
15790
15791printf "%s\n" "#define COOKIE_SEEKER_USES_OFF64_T 1" >>confdefs.h
15792
15793      fi
15794    fi
15795  fi
15796
15797
15798  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken getcwd" >&5
15799printf %s "checking for broken getcwd... " >&6; }
15800  os=`uname -sr 2>/dev/null`
15801  case $os in
15802    SunOS*)
15803
15804printf "%s\n" "#define HAVE_BROKEN_GETCWD 1" >>confdefs.h
15805
15806      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15807printf "%s\n" "yes" >&6; };;
15808    *)
15809      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
15810printf "%s\n" "no" >&6; };;
15811  esac
15812
15813if test "$GCC" = "yes"; then
15814
15815  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken gcc optimize-strlen" >&5
15816printf %s "checking for broken gcc optimize-strlen... " >&6; }
15817if test ${ac_cv_have_broken_gcc_strlen_opt+y}
15818then :
15819  printf %s "(cached) " >&6
15820else $as_nop
15821
15822  if test "$cross_compiling" = yes
15823then :
15824
15825  ac_cv_have_broken_gcc_strlen_opt=no
15826
15827else $as_nop
15828  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15829/* end confdefs.h.  */
15830
15831#include <stdlib.h>
15832#include <string.h>
15833#include <stdio.h>
15834struct s
15835{
15836  int i;
15837  char c[1];
15838};
15839int main()
15840{
15841  struct s *s = malloc(sizeof(struct s) + 3);
15842  s->i = 3;
15843  strcpy(s->c, "foo");
15844  return strlen(s->c+1) == 2;
15845}
15846
15847_ACEOF
15848if ac_fn_c_try_run "$LINENO"
15849then :
15850
15851  ac_cv_have_broken_gcc_strlen_opt=yes
15852
15853else $as_nop
15854
15855  ac_cv_have_broken_gcc_strlen_opt=no
15856
15857fi
15858rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15859  conftest.$ac_objext conftest.beam conftest.$ac_ext
15860fi
15861
15862fi
15863{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_broken_gcc_strlen_opt" >&5
15864printf "%s\n" "$ac_cv_have_broken_gcc_strlen_opt" >&6; }
15865  if test "$ac_cv_have_broken_gcc_strlen_opt" = "yes"; then
15866    CFLAGS="$CFLAGS -fno-optimize-strlen"
15867  fi
15868
15869fi
15870
15871
15872{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
15873printf %s "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15874if test ${ac_cv_struct_tm+y}
15875then :
15876  printf %s "(cached) " >&6
15877else $as_nop
15878  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15879/* end confdefs.h.  */
15880#include <sys/types.h>
15881#include <time.h>
15882
15883int
15884main (void)
15885{
15886struct tm tm;
15887				     int *p = &tm.tm_sec;
15888				     return !p;
15889  ;
15890  return 0;
15891}
15892_ACEOF
15893if ac_fn_c_try_compile "$LINENO"
15894then :
15895  ac_cv_struct_tm=time.h
15896else $as_nop
15897  ac_cv_struct_tm=sys/time.h
15898fi
15899rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15900fi
15901{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
15902printf "%s\n" "$ac_cv_struct_tm" >&6; }
15903if test $ac_cv_struct_tm = sys/time.h; then
15904
15905printf "%s\n" "#define TM_IN_SYS_TIME 1" >>confdefs.h
15906
15907fi
15908
15909{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5
15910printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; }
15911if test ${ac_cv_c_undeclared_builtin_options+y}
15912then :
15913  printf %s "(cached) " >&6
15914else $as_nop
15915  ac_save_CFLAGS=$CFLAGS
15916   ac_cv_c_undeclared_builtin_options='cannot detect'
15917   for ac_arg in '' -fno-builtin; do
15918     CFLAGS="$ac_save_CFLAGS $ac_arg"
15919     # This test program should *not* compile successfully.
15920     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15921/* end confdefs.h.  */
15922
15923int
15924main (void)
15925{
15926(void) strchr;
15927  ;
15928  return 0;
15929}
15930_ACEOF
15931if ac_fn_c_try_compile "$LINENO"
15932then :
15933
15934else $as_nop
15935  # This test program should compile successfully.
15936        # No library function is consistently available on
15937        # freestanding implementations, so test against a dummy
15938        # declaration.  Include always-available headers on the
15939        # off chance that they somehow elicit warnings.
15940        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15941/* end confdefs.h.  */
15942#include <float.h>
15943#include <limits.h>
15944#include <stdarg.h>
15945#include <stddef.h>
15946extern void ac_decl (int, char *);
15947
15948int
15949main (void)
15950{
15951(void) ac_decl (0, (char *) 0);
15952  (void) ac_decl;
15953
15954  ;
15955  return 0;
15956}
15957_ACEOF
15958if ac_fn_c_try_compile "$LINENO"
15959then :
15960  if test x"$ac_arg" = x
15961then :
15962  ac_cv_c_undeclared_builtin_options='none needed'
15963else $as_nop
15964  ac_cv_c_undeclared_builtin_options=$ac_arg
15965fi
15966          break
15967fi
15968rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15969fi
15970rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15971    done
15972    CFLAGS=$ac_save_CFLAGS
15973
15974fi
15975{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5
15976printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; }
15977  case $ac_cv_c_undeclared_builtin_options in #(
15978  'cannot detect') :
15979    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
15980printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
15981as_fn_error $? "cannot make $CC report undeclared builtins
15982See \`config.log' for more details" "$LINENO" 5; } ;; #(
15983  'none needed') :
15984    ac_c_undeclared_builtin_options='' ;; #(
15985  *) :
15986    ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;;
15987esac
15988
15989ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
15990#include <$ac_cv_struct_tm>
15991
15992"
15993if test "x$ac_cv_member_struct_tm_tm_zone" = xyes
15994then :
15995
15996printf "%s\n" "#define HAVE_STRUCT_TM_TM_ZONE 1" >>confdefs.h
15997
15998
15999fi
16000
16001if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
16002
16003printf "%s\n" "#define HAVE_TM_ZONE 1" >>confdefs.h
16004
16005else
16006  ac_fn_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
16007" "$ac_c_undeclared_builtin_options" "CFLAGS"
16008if test "x$ac_cv_have_decl_tzname" = xyes
16009then :
16010  ac_have_decl=1
16011else $as_nop
16012  ac_have_decl=0
16013fi
16014printf "%s\n" "#define HAVE_DECL_TZNAME $ac_have_decl" >>confdefs.h
16015
16016  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
16017printf %s "checking for tzname... " >&6; }
16018if test ${ac_cv_var_tzname+y}
16019then :
16020  printf %s "(cached) " >&6
16021else $as_nop
16022  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16023/* end confdefs.h.  */
16024#include <time.h>
16025#if !HAVE_DECL_TZNAME
16026extern char *tzname[];
16027#endif
16028
16029int
16030main (void)
16031{
16032return tzname[0][0];
16033  ;
16034  return 0;
16035}
16036_ACEOF
16037if ac_fn_c_try_link "$LINENO"
16038then :
16039  ac_cv_var_tzname=yes
16040else $as_nop
16041  ac_cv_var_tzname=no
16042fi
16043rm -f core conftest.err conftest.$ac_objext conftest.beam \
16044    conftest$ac_exeext conftest.$ac_ext
16045fi
16046{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
16047printf "%s\n" "$ac_cv_var_tzname" >&6; }
16048  if test $ac_cv_var_tzname = yes; then
16049
16050printf "%s\n" "#define HAVE_TZNAME 1" >>confdefs.h
16051
16052  fi
16053fi
16054
16055
16056
16057  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for missing declarations of reentrant functions" >&5
16058printf %s "checking for missing declarations of reentrant functions... " >&6; }
16059  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16060/* end confdefs.h.  */
16061#include <time.h>
16062int
16063main (void)
16064{
16065struct tm *(*func)() = localtime_r
16066  ;
16067  return 0;
16068}
16069_ACEOF
16070if ac_fn_c_try_compile "$LINENO"
16071then :
16072
16073    :
16074
16075else $as_nop
16076
16077
16078printf "%s\n" "#define MISSING_LOCALTIME_R_DECL 1" >>confdefs.h
16079
16080
16081fi
16082rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16083  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16084/* end confdefs.h.  */
16085#include <time.h>
16086int
16087main (void)
16088{
16089struct tm *(*func)() = gmtime_r
16090  ;
16091  return 0;
16092}
16093_ACEOF
16094if ac_fn_c_try_compile "$LINENO"
16095then :
16096
16097    :
16098
16099else $as_nop
16100
16101
16102printf "%s\n" "#define MISSING_GMTIME_R_DECL 1" >>confdefs.h
16103
16104
16105fi
16106rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16107  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16108/* end confdefs.h.  */
16109#include <time.h>
16110int
16111main (void)
16112{
16113char *(*func)() = asctime_r
16114  ;
16115  return 0;
16116}
16117_ACEOF
16118if ac_fn_c_try_compile "$LINENO"
16119then :
16120
16121    :
16122
16123else $as_nop
16124
16125
16126printf "%s\n" "#define MISSING_ASCTIME_R_DECL 1" >>confdefs.h
16127
16128
16129fi
16130rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16131  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16132/* end confdefs.h.  */
16133#include <time.h>
16134int
16135main (void)
16136{
16137char *(*func)() = ctime_r
16138  ;
16139  return 0;
16140}
16141_ACEOF
16142if ac_fn_c_try_compile "$LINENO"
16143then :
16144
16145    :
16146
16147else $as_nop
16148
16149
16150printf "%s\n" "#define MISSING_CTIME_R_DECL 1" >>confdefs.h
16151
16152
16153fi
16154rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16155  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16156/* end confdefs.h.  */
16157#include <string.h>
16158int
16159main (void)
16160{
16161char *(*func)() = strtok_r
16162  ;
16163  return 0;
16164}
16165_ACEOF
16166if ac_fn_c_try_compile "$LINENO"
16167then :
16168
16169    :
16170
16171else $as_nop
16172
16173
16174printf "%s\n" "#define MISSING_STRTOK_R_DECL 1" >>confdefs.h
16175
16176
16177fi
16178rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16179  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5
16180printf "%s\n" "done" >&6; }
16181
16182
16183  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fclose declaration" >&5
16184printf %s "checking for fclose declaration... " >&6; }
16185  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16186/* end confdefs.h.  */
16187#include <stdio.h>
16188int
16189main (void)
16190{
16191int (*func)() = fclose
16192  ;
16193  return 0;
16194}
16195_ACEOF
16196if ac_fn_c_try_compile "$LINENO"
16197then :
16198
16199
16200printf "%s\n" "#define MISSING_FCLOSE_DECL 0" >>confdefs.h
16201
16202    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
16203printf "%s\n" "ok" >&6; }
16204
16205else $as_nop
16206
16207
16208printf "%s\n" "#define MISSING_FCLOSE_DECL 1" >>confdefs.h
16209
16210    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: missing" >&5
16211printf "%s\n" "missing" >&6; }
16212
16213fi
16214rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16215
16216
16217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct flock" >&5
16218printf %s "checking for struct flock... " >&6; }
16219if test ${ac_cv_struct_flock+y}
16220then :
16221  printf %s "(cached) " >&6
16222else $as_nop
16223  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16224/* end confdefs.h.  */
16225
16226#include <unistd.h>
16227#include <fcntl.h>
16228
16229int
16230main (void)
16231{
16232struct flock x;
16233  ;
16234  return 0;
16235}
16236_ACEOF
16237if ac_fn_c_try_compile "$LINENO"
16238then :
16239
16240          ac_cv_struct_flock=yes
16241
16242else $as_nop
16243
16244          ac_cv_struct_flock=no
16245
16246fi
16247rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16248
16249fi
16250{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_flock" >&5
16251printf "%s\n" "$ac_cv_struct_flock" >&6; }
16252if test "$ac_cv_struct_flock" = "yes" ; then
16253
16254printf "%s\n" "#define HAVE_STRUCT_FLOCK 1" >>confdefs.h
16255
16256fi
16257
16258
16259ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
16260  #ifdef HAVE_SYS_TYPES_H
16261  # include <sys/types.h>
16262  #endif
16263  #ifdef HAVE_SYS_SOCKET_H
16264  # include <sys/socket.h>
16265  #endif
16266
16267"
16268if test "x$ac_cv_type_socklen_t" = xyes
16269then :
16270
16271printf "%s\n" "#define HAVE_SOCKLEN_T 1" >>confdefs.h
16272
16273
16274fi
16275
16276
16277
16278  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5
16279printf %s "checking size of intmax_t... " >&6; }
16280
16281  php_cache_value=php_cv_sizeof_intmax_t
16282  if test ${php_cv_sizeof_intmax_t+y}
16283then :
16284  printf %s "(cached) " >&6
16285else $as_nop
16286
16287    old_LIBS=$LIBS
16288    LIBS=
16289    old_LDFLAGS=$LDFLAGS
16290    LDFLAGS=
16291    if test "$cross_compiling" = yes
16292then :
16293
16294    eval $php_cache_value=0
16295
16296else $as_nop
16297  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16298/* end confdefs.h.  */
16299#include <stdio.h>
16300#include <stdlib.h>
16301#include <stddef.h>
16302#include <inttypes.h>
16303#ifdef HAVE_UNISTD_H
16304#include <unistd.h>
16305#endif
16306
16307
16308int main()
16309{
16310	FILE *fp = fopen("conftestval", "w");
16311	if (!fp) return(1);
16312	fprintf(fp, "%d\n", sizeof(intmax_t));
16313	return(0);
16314}
16315
16316_ACEOF
16317if ac_fn_c_try_run "$LINENO"
16318then :
16319
16320    eval $php_cache_value=`cat conftestval`
16321
16322else $as_nop
16323
16324    eval $php_cache_value=0
16325
16326fi
16327rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16328  conftest.$ac_objext conftest.beam conftest.$ac_ext
16329fi
16330
16331  LDFLAGS=$old_LDFLAGS
16332  LIBS=$old_LIBS
16333
16334fi
16335
16336  if eval test "\$$php_cache_value" != "0"; then
16337
16338
16339printf "%s\n" "#define SIZEOF_INTMAX_T $php_cv_sizeof_intmax_t" >>confdefs.h
16340
16341
16342printf "%s\n" "#define HAVE_INTMAX_T 1" >>confdefs.h
16343
16344
16345
16346  fi
16347
16348  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_sizeof_intmax_t" >&5
16349printf "%s\n" "$php_cv_sizeof_intmax_t" >&6; }
16350
16351
16352  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of ssize_t" >&5
16353printf %s "checking size of ssize_t... " >&6; }
16354
16355  php_cache_value=php_cv_sizeof_ssize_t
16356  if test ${php_cv_sizeof_ssize_t+y}
16357then :
16358  printf %s "(cached) " >&6
16359else $as_nop
16360
16361    old_LIBS=$LIBS
16362    LIBS=
16363    old_LDFLAGS=$LDFLAGS
16364    LDFLAGS=
16365    if test "$cross_compiling" = yes
16366then :
16367
16368    eval $php_cache_value=8
16369
16370else $as_nop
16371  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16372/* end confdefs.h.  */
16373#include <stdio.h>
16374#include <stdlib.h>
16375#include <stddef.h>
16376#include <inttypes.h>
16377#ifdef HAVE_UNISTD_H
16378#include <unistd.h>
16379#endif
16380
16381
16382int main()
16383{
16384	FILE *fp = fopen("conftestval", "w");
16385	if (!fp) return(1);
16386	fprintf(fp, "%d\n", sizeof(ssize_t));
16387	return(0);
16388}
16389
16390_ACEOF
16391if ac_fn_c_try_run "$LINENO"
16392then :
16393
16394    eval $php_cache_value=`cat conftestval`
16395
16396else $as_nop
16397
16398    eval $php_cache_value=0
16399
16400fi
16401rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16402  conftest.$ac_objext conftest.beam conftest.$ac_ext
16403fi
16404
16405  LDFLAGS=$old_LDFLAGS
16406  LIBS=$old_LIBS
16407
16408fi
16409
16410  if eval test "\$$php_cache_value" != "0"; then
16411
16412
16413printf "%s\n" "#define SIZEOF_SSIZE_T $php_cv_sizeof_ssize_t" >>confdefs.h
16414
16415
16416printf "%s\n" "#define HAVE_SSIZE_T 1" >>confdefs.h
16417
16418
16419
16420  fi
16421
16422  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_sizeof_ssize_t" >&5
16423printf "%s\n" "$php_cv_sizeof_ssize_t" >&6; }
16424
16425
16426  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of ptrdiff_t" >&5
16427printf %s "checking size of ptrdiff_t... " >&6; }
16428
16429  php_cache_value=php_cv_sizeof_ptrdiff_t
16430  if test ${php_cv_sizeof_ptrdiff_t+y}
16431then :
16432  printf %s "(cached) " >&6
16433else $as_nop
16434
16435    old_LIBS=$LIBS
16436    LIBS=
16437    old_LDFLAGS=$LDFLAGS
16438    LDFLAGS=
16439    if test "$cross_compiling" = yes
16440then :
16441
16442    eval $php_cache_value=8
16443
16444else $as_nop
16445  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16446/* end confdefs.h.  */
16447#include <stdio.h>
16448#include <stdlib.h>
16449#include <stddef.h>
16450#include <inttypes.h>
16451#ifdef HAVE_UNISTD_H
16452#include <unistd.h>
16453#endif
16454
16455
16456int main()
16457{
16458	FILE *fp = fopen("conftestval", "w");
16459	if (!fp) return(1);
16460	fprintf(fp, "%d\n", sizeof(ptrdiff_t));
16461	return(0);
16462}
16463
16464_ACEOF
16465if ac_fn_c_try_run "$LINENO"
16466then :
16467
16468    eval $php_cache_value=`cat conftestval`
16469
16470else $as_nop
16471
16472    eval $php_cache_value=0
16473
16474fi
16475rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16476  conftest.$ac_objext conftest.beam conftest.$ac_ext
16477fi
16478
16479  LDFLAGS=$old_LDFLAGS
16480  LIBS=$old_LIBS
16481
16482fi
16483
16484  if eval test "\$$php_cache_value" != "0"; then
16485
16486
16487printf "%s\n" "#define SIZEOF_PTRDIFF_T $php_cv_sizeof_ptrdiff_t" >>confdefs.h
16488
16489
16490printf "%s\n" "#define HAVE_PTRDIFF_T 1" >>confdefs.h
16491
16492
16493
16494  fi
16495
16496  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_sizeof_ptrdiff_t" >&5
16497printf "%s\n" "$php_cv_sizeof_ptrdiff_t" >&6; }
16498
16499
16500
16501  # The cast to long int works around a bug in the HP C Compiler
16502# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16503# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16504# This bug is HP SR number 8606223364.
16505{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
16506printf %s "checking size of short... " >&6; }
16507if test ${ac_cv_sizeof_short+y}
16508then :
16509  printf %s "(cached) " >&6
16510else $as_nop
16511  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"
16512then :
16513
16514else $as_nop
16515  if test "$ac_cv_type_short" = yes; then
16516     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16517printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16518as_fn_error 77 "cannot compute sizeof (short)
16519See \`config.log' for more details" "$LINENO" 5; }
16520   else
16521     ac_cv_sizeof_short=0
16522   fi
16523fi
16524
16525fi
16526{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
16527printf "%s\n" "$ac_cv_sizeof_short" >&6; }
16528
16529
16530
16531printf "%s\n" "#define SIZEOF_SHORT $ac_cv_sizeof_short" >>confdefs.h
16532
16533
16534  # The cast to long int works around a bug in the HP C Compiler
16535# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16536# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16537# This bug is HP SR number 8606223364.
16538{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
16539printf %s "checking size of int... " >&6; }
16540if test ${ac_cv_sizeof_int+y}
16541then :
16542  printf %s "(cached) " >&6
16543else $as_nop
16544  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"
16545then :
16546
16547else $as_nop
16548  if test "$ac_cv_type_int" = yes; then
16549     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16550printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16551as_fn_error 77 "cannot compute sizeof (int)
16552See \`config.log' for more details" "$LINENO" 5; }
16553   else
16554     ac_cv_sizeof_int=0
16555   fi
16556fi
16557
16558fi
16559{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
16560printf "%s\n" "$ac_cv_sizeof_int" >&6; }
16561
16562
16563
16564printf "%s\n" "#define SIZEOF_INT $ac_cv_sizeof_int" >>confdefs.h
16565
16566
16567  # The cast to long int works around a bug in the HP C Compiler
16568# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16569# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16570# This bug is HP SR number 8606223364.
16571{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
16572printf %s "checking size of long... " >&6; }
16573if test ${ac_cv_sizeof_long+y}
16574then :
16575  printf %s "(cached) " >&6
16576else $as_nop
16577  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
16578then :
16579
16580else $as_nop
16581  if test "$ac_cv_type_long" = yes; then
16582     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16583printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16584as_fn_error 77 "cannot compute sizeof (long)
16585See \`config.log' for more details" "$LINENO" 5; }
16586   else
16587     ac_cv_sizeof_long=0
16588   fi
16589fi
16590
16591fi
16592{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
16593printf "%s\n" "$ac_cv_sizeof_long" >&6; }
16594
16595
16596
16597printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
16598
16599
16600  # The cast to long int works around a bug in the HP C Compiler
16601# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16602# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16603# This bug is HP SR number 8606223364.
16604{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
16605printf %s "checking size of long long... " >&6; }
16606if test ${ac_cv_sizeof_long_long+y}
16607then :
16608  printf %s "(cached) " >&6
16609else $as_nop
16610  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"
16611then :
16612
16613else $as_nop
16614  if test "$ac_cv_type_long_long" = yes; then
16615     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16616printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16617as_fn_error 77 "cannot compute sizeof (long long)
16618See \`config.log' for more details" "$LINENO" 5; }
16619   else
16620     ac_cv_sizeof_long_long=0
16621   fi
16622fi
16623
16624fi
16625{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
16626printf "%s\n" "$ac_cv_sizeof_long_long" >&6; }
16627
16628
16629
16630printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h
16631
16632
16633  # The cast to long int works around a bug in the HP C Compiler
16634# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16635# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16636# This bug is HP SR number 8606223364.
16637{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
16638printf %s "checking size of size_t... " >&6; }
16639if test ${ac_cv_sizeof_size_t+y}
16640then :
16641  printf %s "(cached) " >&6
16642else $as_nop
16643  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t"        "$ac_includes_default"
16644then :
16645
16646else $as_nop
16647  if test "$ac_cv_type_size_t" = yes; then
16648     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16649printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16650as_fn_error 77 "cannot compute sizeof (size_t)
16651See \`config.log' for more details" "$LINENO" 5; }
16652   else
16653     ac_cv_sizeof_size_t=0
16654   fi
16655fi
16656
16657fi
16658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
16659printf "%s\n" "$ac_cv_sizeof_size_t" >&6; }
16660
16661
16662
16663printf "%s\n" "#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t" >>confdefs.h
16664
16665
16666  # The cast to long int works around a bug in the HP C Compiler
16667# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16668# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16669# This bug is HP SR number 8606223364.
16670{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
16671printf %s "checking size of off_t... " >&6; }
16672if test ${ac_cv_sizeof_off_t+y}
16673then :
16674  printf %s "(cached) " >&6
16675else $as_nop
16676  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t"        "$ac_includes_default"
16677then :
16678
16679else $as_nop
16680  if test "$ac_cv_type_off_t" = yes; then
16681     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16682printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
16683as_fn_error 77 "cannot compute sizeof (off_t)
16684See \`config.log' for more details" "$LINENO" 5; }
16685   else
16686     ac_cv_sizeof_off_t=0
16687   fi
16688fi
16689
16690fi
16691{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
16692printf "%s\n" "$ac_cv_sizeof_off_t" >&6; }
16693
16694
16695
16696printf "%s\n" "#define SIZEOF_OFF_T $ac_cv_sizeof_off_t" >>confdefs.h
16697
16698
16699  ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "
16700#include <stdint.h>
16701#if HAVE_SYS_TYPES_H
16702# include <sys/types.h>
16703#endif
16704
16705"
16706if test "x$ac_cv_type_int8_t" = xyes
16707then :
16708
16709printf "%s\n" "#define HAVE_INT8_T 1" >>confdefs.h
16710
16711
16712else $as_nop
16713
16714    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16715
16716fi
16717ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "
16718#include <stdint.h>
16719#if HAVE_SYS_TYPES_H
16720# include <sys/types.h>
16721#endif
16722
16723"
16724if test "x$ac_cv_type_int16_t" = xyes
16725then :
16726
16727printf "%s\n" "#define HAVE_INT16_T 1" >>confdefs.h
16728
16729
16730else $as_nop
16731
16732    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16733
16734fi
16735ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "
16736#include <stdint.h>
16737#if HAVE_SYS_TYPES_H
16738# include <sys/types.h>
16739#endif
16740
16741"
16742if test "x$ac_cv_type_int32_t" = xyes
16743then :
16744
16745printf "%s\n" "#define HAVE_INT32_T 1" >>confdefs.h
16746
16747
16748else $as_nop
16749
16750    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16751
16752fi
16753ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "
16754#include <stdint.h>
16755#if HAVE_SYS_TYPES_H
16756# include <sys/types.h>
16757#endif
16758
16759"
16760if test "x$ac_cv_type_int64_t" = xyes
16761then :
16762
16763printf "%s\n" "#define HAVE_INT64_T 1" >>confdefs.h
16764
16765
16766else $as_nop
16767
16768    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16769
16770fi
16771ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "
16772#include <stdint.h>
16773#if HAVE_SYS_TYPES_H
16774# include <sys/types.h>
16775#endif
16776
16777"
16778if test "x$ac_cv_type_uint8_t" = xyes
16779then :
16780
16781printf "%s\n" "#define HAVE_UINT8_T 1" >>confdefs.h
16782
16783
16784else $as_nop
16785
16786    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16787
16788fi
16789ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "
16790#include <stdint.h>
16791#if HAVE_SYS_TYPES_H
16792# include <sys/types.h>
16793#endif
16794
16795"
16796if test "x$ac_cv_type_uint16_t" = xyes
16797then :
16798
16799printf "%s\n" "#define HAVE_UINT16_T 1" >>confdefs.h
16800
16801
16802else $as_nop
16803
16804    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16805
16806fi
16807ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "
16808#include <stdint.h>
16809#if HAVE_SYS_TYPES_H
16810# include <sys/types.h>
16811#endif
16812
16813"
16814if test "x$ac_cv_type_uint32_t" = xyes
16815then :
16816
16817printf "%s\n" "#define HAVE_UINT32_T 1" >>confdefs.h
16818
16819
16820else $as_nop
16821
16822    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16823
16824fi
16825ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "
16826#include <stdint.h>
16827#if HAVE_SYS_TYPES_H
16828# include <sys/types.h>
16829#endif
16830
16831"
16832if test "x$ac_cv_type_uint64_t" = xyes
16833then :
16834
16835printf "%s\n" "#define HAVE_UINT64_T 1" >>confdefs.h
16836
16837
16838else $as_nop
16839
16840    as_fn_error $? "One of the intN_t or uintN_t types is not available" "$LINENO" 5
16841
16842fi
16843
16844
16845
16846
16847  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_expect" >&5
16848printf %s "checking for __builtin_expect... " >&6; }
16849
16850  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16851/* end confdefs.h.  */
16852
16853int
16854main (void)
16855{
16856
16857    return __builtin_expect(1,1) ? 1 : 0;
16858
16859  ;
16860  return 0;
16861}
16862_ACEOF
16863if ac_fn_c_try_link "$LINENO"
16864then :
16865
16866    have_builtin_expect=1
16867    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16868printf "%s\n" "yes" >&6; }
16869
16870else $as_nop
16871
16872    have_builtin_expect=0
16873    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16874printf "%s\n" "no" >&6; }
16875
16876fi
16877rm -f core conftest.err conftest.$ac_objext conftest.beam \
16878    conftest$ac_exeext conftest.$ac_ext
16879
16880
16881printf "%s\n" "#define PHP_HAVE_BUILTIN_EXPECT $have_builtin_expect" >>confdefs.h
16882
16883
16884
16885  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_clz" >&5
16886printf %s "checking for __builtin_clz... " >&6; }
16887
16888  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16889/* end confdefs.h.  */
16890
16891int
16892main (void)
16893{
16894
16895    return __builtin_clz(1) ? 1 : 0;
16896
16897  ;
16898  return 0;
16899}
16900_ACEOF
16901if ac_fn_c_try_link "$LINENO"
16902then :
16903
16904    have_builtin_clz=1
16905    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16906printf "%s\n" "yes" >&6; }
16907
16908else $as_nop
16909
16910    have_builtin_clz=0
16911    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16912printf "%s\n" "no" >&6; }
16913
16914fi
16915rm -f core conftest.err conftest.$ac_objext conftest.beam \
16916    conftest$ac_exeext conftest.$ac_ext
16917
16918
16919printf "%s\n" "#define PHP_HAVE_BUILTIN_CLZ $have_builtin_clz" >>confdefs.h
16920
16921
16922
16923  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_clzl" >&5
16924printf %s "checking for __builtin_clzl... " >&6; }
16925
16926  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16927/* end confdefs.h.  */
16928
16929int
16930main (void)
16931{
16932
16933    return __builtin_clzl(1) ? 1 : 0;
16934
16935  ;
16936  return 0;
16937}
16938_ACEOF
16939if ac_fn_c_try_link "$LINENO"
16940then :
16941
16942    have_builtin_clzl=1
16943    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16944printf "%s\n" "yes" >&6; }
16945
16946else $as_nop
16947
16948    have_builtin_clzl=0
16949    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16950printf "%s\n" "no" >&6; }
16951
16952fi
16953rm -f core conftest.err conftest.$ac_objext conftest.beam \
16954    conftest$ac_exeext conftest.$ac_ext
16955
16956
16957printf "%s\n" "#define PHP_HAVE_BUILTIN_CLZL $have_builtin_clzl" >>confdefs.h
16958
16959
16960
16961  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_clzll" >&5
16962printf %s "checking for __builtin_clzll... " >&6; }
16963
16964  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16965/* end confdefs.h.  */
16966
16967int
16968main (void)
16969{
16970
16971    return __builtin_clzll(1) ? 1 : 0;
16972
16973  ;
16974  return 0;
16975}
16976_ACEOF
16977if ac_fn_c_try_link "$LINENO"
16978then :
16979
16980    have_builtin_clzll=1
16981    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16982printf "%s\n" "yes" >&6; }
16983
16984else $as_nop
16985
16986    have_builtin_clzll=0
16987    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
16988printf "%s\n" "no" >&6; }
16989
16990fi
16991rm -f core conftest.err conftest.$ac_objext conftest.beam \
16992    conftest$ac_exeext conftest.$ac_ext
16993
16994
16995printf "%s\n" "#define PHP_HAVE_BUILTIN_CLZLL $have_builtin_clzll" >>confdefs.h
16996
16997
16998
16999  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_ctzl" >&5
17000printf %s "checking for __builtin_ctzl... " >&6; }
17001
17002  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17003/* end confdefs.h.  */
17004
17005int
17006main (void)
17007{
17008
17009    return __builtin_ctzl(2L) ? 1 : 0;
17010
17011  ;
17012  return 0;
17013}
17014_ACEOF
17015if ac_fn_c_try_link "$LINENO"
17016then :
17017
17018    have_builtin_ctzl=1
17019    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17020printf "%s\n" "yes" >&6; }
17021
17022else $as_nop
17023
17024    have_builtin_ctzl=0
17025    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17026printf "%s\n" "no" >&6; }
17027
17028fi
17029rm -f core conftest.err conftest.$ac_objext conftest.beam \
17030    conftest$ac_exeext conftest.$ac_ext
17031
17032
17033printf "%s\n" "#define PHP_HAVE_BUILTIN_CTZL $have_builtin_ctzl" >>confdefs.h
17034
17035
17036
17037  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_ctzll" >&5
17038printf %s "checking for __builtin_ctzll... " >&6; }
17039
17040  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17041/* end confdefs.h.  */
17042
17043int
17044main (void)
17045{
17046
17047    return __builtin_ctzll(2LL) ? 1 : 0;
17048
17049  ;
17050  return 0;
17051}
17052_ACEOF
17053if ac_fn_c_try_link "$LINENO"
17054then :
17055
17056    have_builtin_ctzll=1
17057    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17058printf "%s\n" "yes" >&6; }
17059
17060else $as_nop
17061
17062    have_builtin_ctzll=0
17063    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17064printf "%s\n" "no" >&6; }
17065
17066fi
17067rm -f core conftest.err conftest.$ac_objext conftest.beam \
17068    conftest$ac_exeext conftest.$ac_ext
17069
17070
17071printf "%s\n" "#define PHP_HAVE_BUILTIN_CTZLL $have_builtin_ctzll" >>confdefs.h
17072
17073
17074
17075  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_smull_overflow" >&5
17076printf %s "checking for __builtin_smull_overflow... " >&6; }
17077
17078  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17079/* end confdefs.h.  */
17080
17081int
17082main (void)
17083{
17084
17085    long tmpvar;
17086    return __builtin_smull_overflow(3, 7, &tmpvar);
17087
17088  ;
17089  return 0;
17090}
17091_ACEOF
17092if ac_fn_c_try_link "$LINENO"
17093then :
17094
17095    have_builtin_smull_overflow=1
17096    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17097printf "%s\n" "yes" >&6; }
17098
17099else $as_nop
17100
17101    have_builtin_smull_overflow=0
17102    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17103printf "%s\n" "no" >&6; }
17104
17105fi
17106rm -f core conftest.err conftest.$ac_objext conftest.beam \
17107    conftest$ac_exeext conftest.$ac_ext
17108
17109
17110printf "%s\n" "#define PHP_HAVE_BUILTIN_SMULL_OVERFLOW $have_builtin_smull_overflow" >>confdefs.h
17111
17112
17113
17114  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_smulll_overflow" >&5
17115printf %s "checking for __builtin_smulll_overflow... " >&6; }
17116
17117  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17118/* end confdefs.h.  */
17119
17120int
17121main (void)
17122{
17123
17124    long long tmpvar;
17125    return __builtin_smulll_overflow(3, 7, &tmpvar);
17126
17127  ;
17128  return 0;
17129}
17130_ACEOF
17131if ac_fn_c_try_link "$LINENO"
17132then :
17133
17134    have_builtin_smulll_overflow=1
17135    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17136printf "%s\n" "yes" >&6; }
17137
17138else $as_nop
17139
17140    have_builtin_smulll_overflow=0
17141    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17142printf "%s\n" "no" >&6; }
17143
17144fi
17145rm -f core conftest.err conftest.$ac_objext conftest.beam \
17146    conftest$ac_exeext conftest.$ac_ext
17147
17148
17149printf "%s\n" "#define PHP_HAVE_BUILTIN_SMULLL_OVERFLOW $have_builtin_smulll_overflow" >>confdefs.h
17150
17151
17152
17153  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_saddl_overflow" >&5
17154printf %s "checking for __builtin_saddl_overflow... " >&6; }
17155
17156  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17157/* end confdefs.h.  */
17158
17159int
17160main (void)
17161{
17162
17163    long tmpvar;
17164    return __builtin_saddl_overflow(3, 7, &tmpvar);
17165
17166  ;
17167  return 0;
17168}
17169_ACEOF
17170if ac_fn_c_try_link "$LINENO"
17171then :
17172
17173    have_builtin_saddl_overflow=1
17174    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17175printf "%s\n" "yes" >&6; }
17176
17177else $as_nop
17178
17179    have_builtin_saddl_overflow=0
17180    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17181printf "%s\n" "no" >&6; }
17182
17183fi
17184rm -f core conftest.err conftest.$ac_objext conftest.beam \
17185    conftest$ac_exeext conftest.$ac_ext
17186
17187
17188printf "%s\n" "#define PHP_HAVE_BUILTIN_SADDL_OVERFLOW $have_builtin_saddl_overflow" >>confdefs.h
17189
17190
17191
17192  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_saddll_overflow" >&5
17193printf %s "checking for __builtin_saddll_overflow... " >&6; }
17194
17195  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17196/* end confdefs.h.  */
17197
17198int
17199main (void)
17200{
17201
17202    long long tmpvar;
17203    return __builtin_saddll_overflow(3, 7, &tmpvar);
17204
17205  ;
17206  return 0;
17207}
17208_ACEOF
17209if ac_fn_c_try_link "$LINENO"
17210then :
17211
17212    have_builtin_saddll_overflow=1
17213    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17214printf "%s\n" "yes" >&6; }
17215
17216else $as_nop
17217
17218    have_builtin_saddll_overflow=0
17219    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17220printf "%s\n" "no" >&6; }
17221
17222fi
17223rm -f core conftest.err conftest.$ac_objext conftest.beam \
17224    conftest$ac_exeext conftest.$ac_ext
17225
17226
17227printf "%s\n" "#define PHP_HAVE_BUILTIN_SADDLL_OVERFLOW $have_builtin_saddll_overflow" >>confdefs.h
17228
17229
17230
17231  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_ssubl_overflow" >&5
17232printf %s "checking for __builtin_ssubl_overflow... " >&6; }
17233
17234  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17235/* end confdefs.h.  */
17236
17237int
17238main (void)
17239{
17240
17241    long tmpvar;
17242    return __builtin_ssubl_overflow(3, 7, &tmpvar);
17243
17244  ;
17245  return 0;
17246}
17247_ACEOF
17248if ac_fn_c_try_link "$LINENO"
17249then :
17250
17251    have_builtin_ssubl_overflow=1
17252    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17253printf "%s\n" "yes" >&6; }
17254
17255else $as_nop
17256
17257    have_builtin_ssubl_overflow=0
17258    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17259printf "%s\n" "no" >&6; }
17260
17261fi
17262rm -f core conftest.err conftest.$ac_objext conftest.beam \
17263    conftest$ac_exeext conftest.$ac_ext
17264
17265
17266printf "%s\n" "#define PHP_HAVE_BUILTIN_SSUBL_OVERFLOW $have_builtin_ssubl_overflow" >>confdefs.h
17267
17268
17269
17270  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_ssubll_overflow" >&5
17271printf %s "checking for __builtin_ssubll_overflow... " >&6; }
17272
17273  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17274/* end confdefs.h.  */
17275
17276int
17277main (void)
17278{
17279
17280    long long tmpvar;
17281    return __builtin_ssubll_overflow(3, 7, &tmpvar);
17282
17283  ;
17284  return 0;
17285}
17286_ACEOF
17287if ac_fn_c_try_link "$LINENO"
17288then :
17289
17290    have_builtin_ssubll_overflow=1
17291    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17292printf "%s\n" "yes" >&6; }
17293
17294else $as_nop
17295
17296    have_builtin_ssubll_overflow=0
17297    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17298printf "%s\n" "no" >&6; }
17299
17300fi
17301rm -f core conftest.err conftest.$ac_objext conftest.beam \
17302    conftest$ac_exeext conftest.$ac_ext
17303
17304
17305printf "%s\n" "#define PHP_HAVE_BUILTIN_SSUBLL_OVERFLOW $have_builtin_ssubll_overflow" >>confdefs.h
17306
17307
17308
17309  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_cpu_init" >&5
17310printf %s "checking for __builtin_cpu_init... " >&6; }
17311
17312  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17313/* end confdefs.h.  */
17314
17315int
17316main (void)
17317{
17318
17319    return __builtin_cpu_init()? 1 : 0;
17320
17321  ;
17322  return 0;
17323}
17324_ACEOF
17325if ac_fn_c_try_link "$LINENO"
17326then :
17327
17328    have_builtin_cpu_init=1
17329    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17330printf "%s\n" "yes" >&6; }
17331
17332else $as_nop
17333
17334    have_builtin_cpu_init=0
17335    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17336printf "%s\n" "no" >&6; }
17337
17338fi
17339rm -f core conftest.err conftest.$ac_objext conftest.beam \
17340    conftest$ac_exeext conftest.$ac_ext
17341
17342
17343printf "%s\n" "#define PHP_HAVE_BUILTIN_CPU_INIT $have_builtin_cpu_init" >>confdefs.h
17344
17345
17346
17347  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __builtin_cpu_supports" >&5
17348printf %s "checking for __builtin_cpu_supports... " >&6; }
17349
17350  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17351/* end confdefs.h.  */
17352
17353int
17354main (void)
17355{
17356
17357    return __builtin_cpu_supports("sse")? 1 : 0;
17358
17359  ;
17360  return 0;
17361}
17362_ACEOF
17363if ac_fn_c_try_link "$LINENO"
17364then :
17365
17366    have_builtin_cpu_supports=1
17367    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17368printf "%s\n" "yes" >&6; }
17369
17370else $as_nop
17371
17372    have_builtin_cpu_supports=0
17373    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
17374printf "%s\n" "no" >&6; }
17375
17376fi
17377rm -f core conftest.err conftest.$ac_objext conftest.beam \
17378    conftest$ac_exeext conftest.$ac_ext
17379
17380
17381printf "%s\n" "#define PHP_HAVE_BUILTIN_CPU_SUPPORTS $have_builtin_cpu_supports" >>confdefs.h
17382
17383
17384
17385{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports __alignof__" >&5
17386printf %s "checking whether the compiler supports __alignof__... " >&6; }
17387if test ${ac_cv_alignof_exists+y}
17388then :
17389  printf %s "(cached) " >&6
17390else $as_nop
17391
17392cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17393/* end confdefs.h.  */
17394
17395
17396int
17397main (void)
17398{
17399
17400  int align = __alignof__(int);
17401
17402  ;
17403  return 0;
17404}
17405_ACEOF
17406if ac_fn_c_try_compile "$LINENO"
17407then :
17408
17409  ac_cv_alignof_exists=yes
17410
17411else $as_nop
17412
17413  ac_cv_alignof_exists=no
17414
17415fi
17416rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17417fi
17418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_exists" >&5
17419printf "%s\n" "$ac_cv_alignof_exists" >&6; }
17420if test "$ac_cv_alignof_exists" = "yes"; then
17421
17422printf "%s\n" "#define HAVE_ALIGNOF 1" >>confdefs.h
17423
17424fi
17425
17426ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
17427"
17428if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes
17429then :
17430
17431printf "%s\n" "#define HAVE_STRUCT_TM_TM_GMTOFF 1" >>confdefs.h
17432
17433
17434fi
17435
17436ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
17437if test "x$ac_cv_member_struct_stat_st_blksize" = xyes
17438then :
17439
17440printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLKSIZE 1" >>confdefs.h
17441
17442
17443fi
17444ac_fn_c_check_member "$LINENO" "struct stat" "st_rdev" "ac_cv_member_struct_stat_st_rdev" "$ac_includes_default"
17445if test "x$ac_cv_member_struct_stat_st_rdev" = xyes
17446then :
17447
17448printf "%s\n" "#define HAVE_STRUCT_STAT_ST_RDEV 1" >>confdefs.h
17449
17450
17451fi
17452
17453if test "`uname -s 2>/dev/null`" != "QNX"; then
17454  ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
17455if test "x$ac_cv_member_struct_stat_st_blocks" = xyes
17456then :
17457
17458printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLOCKS 1" >>confdefs.h
17459
17460
17461printf "%s\n" "#define HAVE_ST_BLOCKS 1" >>confdefs.h
17462
17463else $as_nop
17464  case " $LIBOBJS " in
17465  *" fileblocks.$ac_objext "* ) ;;
17466  *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
17467 ;;
17468esac
17469
17470fi
17471
17472
17473fi
17474
17475ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
17476if test "x$ac_cv_type_size_t" = xyes
17477then :
17478
17479else $as_nop
17480
17481printf "%s\n" "#define size_t unsigned int" >>confdefs.h
17482
17483fi
17484
17485{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
17486printf %s "checking for uid_t in sys/types.h... " >&6; }
17487if test ${ac_cv_type_uid_t+y}
17488then :
17489  printf %s "(cached) " >&6
17490else $as_nop
17491  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17492/* end confdefs.h.  */
17493#include <sys/types.h>
17494
17495_ACEOF
17496if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17497  $EGREP "uid_t" >/dev/null 2>&1
17498then :
17499  ac_cv_type_uid_t=yes
17500else $as_nop
17501  ac_cv_type_uid_t=no
17502fi
17503rm -rf conftest*
17504
17505fi
17506{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
17507printf "%s\n" "$ac_cv_type_uid_t" >&6; }
17508if test $ac_cv_type_uid_t = no; then
17509
17510printf "%s\n" "#define uid_t int" >>confdefs.h
17511
17512
17513printf "%s\n" "#define gid_t int" >>confdefs.h
17514
17515fi
17516
17517
17518
17519    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5
17520printf %s "checking for struct sockaddr_storage... " >&6; }
17521if test ${ac_cv_sockaddr_storage+y}
17522then :
17523  printf %s "(cached) " >&6
17524else $as_nop
17525  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17526/* end confdefs.h.  */
17527#include <sys/types.h>
17528#include <sys/socket.h>
17529int
17530main (void)
17531{
17532struct sockaddr_storage s; s
17533  ;
17534  return 0;
17535}
17536_ACEOF
17537if ac_fn_c_try_compile "$LINENO"
17538then :
17539  ac_cv_sockaddr_storage=yes
17540else $as_nop
17541  ac_cv_sockaddr_storage=no
17542fi
17543rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17544
17545fi
17546{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sockaddr_storage" >&5
17547printf "%s\n" "$ac_cv_sockaddr_storage" >&6; }
17548  if test "$ac_cv_sockaddr_storage" = "yes"; then
17549
17550printf "%s\n" "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h
17551
17552  fi
17553    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for field sa_len in struct sockaddr" >&5
17554printf %s "checking for field sa_len in struct sockaddr... " >&6; }
17555if test ${ac_cv_sockaddr_sa_len+y}
17556then :
17557  printf %s "(cached) " >&6
17558else $as_nop
17559
17560    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17561/* end confdefs.h.  */
17562#include <sys/types.h>
17563#include <sys/socket.h>
17564int
17565main (void)
17566{
17567static struct sockaddr sa; int n = (int) sa.sa_len; return n;
17568  ;
17569  return 0;
17570}
17571_ACEOF
17572if ac_fn_c_try_compile "$LINENO"
17573then :
17574  ac_cv_sockaddr_sa_len=yes
17575else $as_nop
17576  ac_cv_sockaddr_sa_len=no
17577fi
17578rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17579
17580fi
17581{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sockaddr_sa_len" >&5
17582printf "%s\n" "$ac_cv_sockaddr_sa_len" >&6; }
17583  if test "$ac_cv_sockaddr_sa_len" = "yes"; then
17584
17585printf "%s\n" "#define HAVE_SOCKADDR_SA_LEN 1" >>confdefs.h
17586
17587  fi
17588
17589
17590case $host_alias in #(
17591  *-*-*android*|*-*-*uclibc*|*-*-*musl*|*freebsd*|*openbsd*) :
17592    true ;; #(
17593  *) :
17594
17595
17596
17597
17598    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __attribute__((ifunc))" >&5
17599printf %s "checking for __attribute__((ifunc))... " >&6; }
17600if test ${ax_cv_have_func_attribute_ifunc+y}
17601then :
17602  printf %s "(cached) " >&6
17603else $as_nop
17604
17605        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17606/* end confdefs.h.  */
17607
17608
17609                    int my_foo( void ) { return 0; }
17610                    static int (*resolve_foo(void))(void) { return my_foo; }
17611                    int foo( void ) __attribute__((ifunc("resolve_foo")));
17612
17613int
17614main (void)
17615{
17616
17617  ;
17618  return 0;
17619}
17620
17621_ACEOF
17622if ac_fn_c_try_link "$LINENO"
17623then :
17624                                      if test -s conftest.err
17625then :
17626  ax_cv_have_func_attribute_ifunc=no
17627else $as_nop
17628  ax_cv_have_func_attribute_ifunc=yes
17629fi
17630else $as_nop
17631  ax_cv_have_func_attribute_ifunc=no
17632fi
17633rm -f core conftest.err conftest.$ac_objext conftest.beam \
17634    conftest$ac_exeext conftest.$ac_ext
17635
17636fi
17637{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_have_func_attribute_ifunc" >&5
17638printf "%s\n" "$ax_cv_have_func_attribute_ifunc" >&6; }
17639
17640    if test yes = $ax_cv_have_func_attribute_ifunc
17641then :
17642
17643printf "%s\n" "#define HAVE_FUNC_ATTRIBUTE_IFUNC 1" >>confdefs.h
17644
17645fi
17646
17647
17648
17649
17650
17651
17652    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __attribute__((target))" >&5
17653printf %s "checking for __attribute__((target))... " >&6; }
17654if test ${ax_cv_have_func_attribute_target+y}
17655then :
17656  printf %s "(cached) " >&6
17657else $as_nop
17658
17659        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17660/* end confdefs.h.  */
17661
17662
17663                    static int bar( void ) __attribute__((target("sse2")));
17664
17665int
17666main (void)
17667{
17668
17669  ;
17670  return 0;
17671}
17672
17673_ACEOF
17674if ac_fn_c_try_link "$LINENO"
17675then :
17676                                      if test -s conftest.err
17677then :
17678  ax_cv_have_func_attribute_target=no
17679else $as_nop
17680  ax_cv_have_func_attribute_target=yes
17681fi
17682else $as_nop
17683  ax_cv_have_func_attribute_target=no
17684fi
17685rm -f core conftest.err conftest.$ac_objext conftest.beam \
17686    conftest$ac_exeext conftest.$ac_ext
17687
17688fi
17689{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_have_func_attribute_target" >&5
17690printf "%s\n" "$ax_cv_have_func_attribute_target" >&6; }
17691
17692    if test yes = $ax_cv_have_func_attribute_target
17693then :
17694
17695printf "%s\n" "#define HAVE_FUNC_ATTRIBUTE_TARGET 1" >>confdefs.h
17696
17697fi
17698
17699
17700
17701 ;;
17702esac
17703
17704{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for IPv6 support" >&5
17705printf %s "checking for IPv6 support... " >&6; }
17706if test ${ac_cv_ipv6_support+y}
17707then :
17708  printf %s "(cached) " >&6
17709else $as_nop
17710  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17711/* end confdefs.h.  */
17712#include <sys/types.h>
17713#include <sys/socket.h>
17714#include <netinet/in.h>
17715int
17716main (void)
17717{
17718struct sockaddr_in6 s; struct in6_addr t=in6addr_any; int i=AF_INET6; s; t.s6_addr[0] = 0;
17719  ;
17720  return 0;
17721}
17722_ACEOF
17723if ac_fn_c_try_link "$LINENO"
17724then :
17725  ac_cv_ipv6_support=yes
17726else $as_nop
17727  ac_cv_ipv6_support=no
17728fi
17729rm -f core conftest.err conftest.$ac_objext conftest.beam \
17730    conftest$ac_exeext conftest.$ac_ext
17731fi
17732{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ipv6_support" >&5
17733printf "%s\n" "$ac_cv_ipv6_support" >&6; }
17734
17735
17736ac_fn_c_check_func "$LINENO" "alphasort" "ac_cv_func_alphasort"
17737if test "x$ac_cv_func_alphasort" = xyes
17738then :
17739  printf "%s\n" "#define HAVE_ALPHASORT 1" >>confdefs.h
17740
17741fi
17742ac_fn_c_check_func "$LINENO" "asctime_r" "ac_cv_func_asctime_r"
17743if test "x$ac_cv_func_asctime_r" = xyes
17744then :
17745  printf "%s\n" "#define HAVE_ASCTIME_R 1" >>confdefs.h
17746
17747fi
17748ac_fn_c_check_func "$LINENO" "chroot" "ac_cv_func_chroot"
17749if test "x$ac_cv_func_chroot" = xyes
17750then :
17751  printf "%s\n" "#define HAVE_CHROOT 1" >>confdefs.h
17752
17753fi
17754ac_fn_c_check_func "$LINENO" "ctime_r" "ac_cv_func_ctime_r"
17755if test "x$ac_cv_func_ctime_r" = xyes
17756then :
17757  printf "%s\n" "#define HAVE_CTIME_R 1" >>confdefs.h
17758
17759fi
17760ac_fn_c_check_func "$LINENO" "explicit_memset" "ac_cv_func_explicit_memset"
17761if test "x$ac_cv_func_explicit_memset" = xyes
17762then :
17763  printf "%s\n" "#define HAVE_EXPLICIT_MEMSET 1" >>confdefs.h
17764
17765fi
17766ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
17767if test "x$ac_cv_func_fdatasync" = xyes
17768then :
17769  printf "%s\n" "#define HAVE_FDATASYNC 1" >>confdefs.h
17770
17771fi
17772ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock"
17773if test "x$ac_cv_func_flock" = xyes
17774then :
17775  printf "%s\n" "#define HAVE_FLOCK 1" >>confdefs.h
17776
17777fi
17778ac_fn_c_check_func "$LINENO" "ftok" "ac_cv_func_ftok"
17779if test "x$ac_cv_func_ftok" = xyes
17780then :
17781  printf "%s\n" "#define HAVE_FTOK 1" >>confdefs.h
17782
17783fi
17784ac_fn_c_check_func "$LINENO" "funopen" "ac_cv_func_funopen"
17785if test "x$ac_cv_func_funopen" = xyes
17786then :
17787  printf "%s\n" "#define HAVE_FUNOPEN 1" >>confdefs.h
17788
17789fi
17790ac_fn_c_check_func "$LINENO" "gai_strerror" "ac_cv_func_gai_strerror"
17791if test "x$ac_cv_func_gai_strerror" = xyes
17792then :
17793  printf "%s\n" "#define HAVE_GAI_STRERROR 1" >>confdefs.h
17794
17795fi
17796ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd"
17797if test "x$ac_cv_func_getcwd" = xyes
17798then :
17799  printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h
17800
17801fi
17802ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
17803if test "x$ac_cv_func_getloadavg" = xyes
17804then :
17805  printf "%s\n" "#define HAVE_GETLOADAVG 1" >>confdefs.h
17806
17807fi
17808ac_fn_c_check_func "$LINENO" "getlogin" "ac_cv_func_getlogin"
17809if test "x$ac_cv_func_getlogin" = xyes
17810then :
17811  printf "%s\n" "#define HAVE_GETLOGIN 1" >>confdefs.h
17812
17813fi
17814ac_fn_c_check_func "$LINENO" "getprotobyname" "ac_cv_func_getprotobyname"
17815if test "x$ac_cv_func_getprotobyname" = xyes
17816then :
17817  printf "%s\n" "#define HAVE_GETPROTOBYNAME 1" >>confdefs.h
17818
17819fi
17820ac_fn_c_check_func "$LINENO" "getprotobynumber" "ac_cv_func_getprotobynumber"
17821if test "x$ac_cv_func_getprotobynumber" = xyes
17822then :
17823  printf "%s\n" "#define HAVE_GETPROTOBYNUMBER 1" >>confdefs.h
17824
17825fi
17826ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname"
17827if test "x$ac_cv_func_getservbyname" = xyes
17828then :
17829  printf "%s\n" "#define HAVE_GETSERVBYNAME 1" >>confdefs.h
17830
17831fi
17832ac_fn_c_check_func "$LINENO" "getservbyport" "ac_cv_func_getservbyport"
17833if test "x$ac_cv_func_getservbyport" = xyes
17834then :
17835  printf "%s\n" "#define HAVE_GETSERVBYPORT 1" >>confdefs.h
17836
17837fi
17838ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
17839if test "x$ac_cv_func_getrusage" = xyes
17840then :
17841  printf "%s\n" "#define HAVE_GETRUSAGE 1" >>confdefs.h
17842
17843fi
17844ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
17845if test "x$ac_cv_func_gettimeofday" = xyes
17846then :
17847  printf "%s\n" "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h
17848
17849fi
17850ac_fn_c_check_func "$LINENO" "gmtime_r" "ac_cv_func_gmtime_r"
17851if test "x$ac_cv_func_gmtime_r" = xyes
17852then :
17853  printf "%s\n" "#define HAVE_GMTIME_R 1" >>confdefs.h
17854
17855fi
17856ac_fn_c_check_func "$LINENO" "getpwnam_r" "ac_cv_func_getpwnam_r"
17857if test "x$ac_cv_func_getpwnam_r" = xyes
17858then :
17859  printf "%s\n" "#define HAVE_GETPWNAM_R 1" >>confdefs.h
17860
17861fi
17862ac_fn_c_check_func "$LINENO" "getgrnam_r" "ac_cv_func_getgrnam_r"
17863if test "x$ac_cv_func_getgrnam_r" = xyes
17864then :
17865  printf "%s\n" "#define HAVE_GETGRNAM_R 1" >>confdefs.h
17866
17867fi
17868ac_fn_c_check_func "$LINENO" "getpwuid_r" "ac_cv_func_getpwuid_r"
17869if test "x$ac_cv_func_getpwuid_r" = xyes
17870then :
17871  printf "%s\n" "#define HAVE_GETPWUID_R 1" >>confdefs.h
17872
17873fi
17874ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
17875if test "x$ac_cv_func_getwd" = xyes
17876then :
17877  printf "%s\n" "#define HAVE_GETWD 1" >>confdefs.h
17878
17879fi
17880ac_fn_c_check_func "$LINENO" "glob" "ac_cv_func_glob"
17881if test "x$ac_cv_func_glob" = xyes
17882then :
17883  printf "%s\n" "#define HAVE_GLOB 1" >>confdefs.h
17884
17885fi
17886ac_fn_c_check_func "$LINENO" "inet_ntoa" "ac_cv_func_inet_ntoa"
17887if test "x$ac_cv_func_inet_ntoa" = xyes
17888then :
17889  printf "%s\n" "#define HAVE_INET_NTOA 1" >>confdefs.h
17890
17891fi
17892ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
17893if test "x$ac_cv_func_inet_ntop" = xyes
17894then :
17895  printf "%s\n" "#define HAVE_INET_NTOP 1" >>confdefs.h
17896
17897fi
17898ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
17899if test "x$ac_cv_func_inet_pton" = xyes
17900then :
17901  printf "%s\n" "#define HAVE_INET_PTON 1" >>confdefs.h
17902
17903fi
17904ac_fn_c_check_func "$LINENO" "localtime_r" "ac_cv_func_localtime_r"
17905if test "x$ac_cv_func_localtime_r" = xyes
17906then :
17907  printf "%s\n" "#define HAVE_LOCALTIME_R 1" >>confdefs.h
17908
17909fi
17910ac_fn_c_check_func "$LINENO" "lchown" "ac_cv_func_lchown"
17911if test "x$ac_cv_func_lchown" = xyes
17912then :
17913  printf "%s\n" "#define HAVE_LCHOWN 1" >>confdefs.h
17914
17915fi
17916ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
17917if test "x$ac_cv_func_memmove" = xyes
17918then :
17919  printf "%s\n" "#define HAVE_MEMMOVE 1" >>confdefs.h
17920
17921fi
17922ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp"
17923if test "x$ac_cv_func_mkstemp" = xyes
17924then :
17925  printf "%s\n" "#define HAVE_MKSTEMP 1" >>confdefs.h
17926
17927fi
17928ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
17929if test "x$ac_cv_func_mmap" = xyes
17930then :
17931  printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h
17932
17933fi
17934ac_fn_c_check_func "$LINENO" "nice" "ac_cv_func_nice"
17935if test "x$ac_cv_func_nice" = xyes
17936then :
17937  printf "%s\n" "#define HAVE_NICE 1" >>confdefs.h
17938
17939fi
17940ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo"
17941if test "x$ac_cv_func_nl_langinfo" = xyes
17942then :
17943  printf "%s\n" "#define HAVE_NL_LANGINFO 1" >>confdefs.h
17944
17945fi
17946ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll"
17947if test "x$ac_cv_func_poll" = xyes
17948then :
17949  printf "%s\n" "#define HAVE_POLL 1" >>confdefs.h
17950
17951fi
17952ac_fn_c_check_func "$LINENO" "putenv" "ac_cv_func_putenv"
17953if test "x$ac_cv_func_putenv" = xyes
17954then :
17955  printf "%s\n" "#define HAVE_PUTENV 1" >>confdefs.h
17956
17957fi
17958ac_fn_c_check_func "$LINENO" "scandir" "ac_cv_func_scandir"
17959if test "x$ac_cv_func_scandir" = xyes
17960then :
17961  printf "%s\n" "#define HAVE_SCANDIR 1" >>confdefs.h
17962
17963fi
17964ac_fn_c_check_func "$LINENO" "setitimer" "ac_cv_func_setitimer"
17965if test "x$ac_cv_func_setitimer" = xyes
17966then :
17967  printf "%s\n" "#define HAVE_SETITIMER 1" >>confdefs.h
17968
17969fi
17970ac_fn_c_check_func "$LINENO" "setenv" "ac_cv_func_setenv"
17971if test "x$ac_cv_func_setenv" = xyes
17972then :
17973  printf "%s\n" "#define HAVE_SETENV 1" >>confdefs.h
17974
17975fi
17976ac_fn_c_check_func "$LINENO" "shutdown" "ac_cv_func_shutdown"
17977if test "x$ac_cv_func_shutdown" = xyes
17978then :
17979  printf "%s\n" "#define HAVE_SHUTDOWN 1" >>confdefs.h
17980
17981fi
17982ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
17983if test "x$ac_cv_func_sigprocmask" = xyes
17984then :
17985  printf "%s\n" "#define HAVE_SIGPROCMASK 1" >>confdefs.h
17986
17987fi
17988ac_fn_c_check_func "$LINENO" "statfs" "ac_cv_func_statfs"
17989if test "x$ac_cv_func_statfs" = xyes
17990then :
17991  printf "%s\n" "#define HAVE_STATFS 1" >>confdefs.h
17992
17993fi
17994ac_fn_c_check_func "$LINENO" "statvfs" "ac_cv_func_statvfs"
17995if test "x$ac_cv_func_statvfs" = xyes
17996then :
17997  printf "%s\n" "#define HAVE_STATVFS 1" >>confdefs.h
17998
17999fi
18000ac_fn_c_check_func "$LINENO" "std_syslog" "ac_cv_func_std_syslog"
18001if test "x$ac_cv_func_std_syslog" = xyes
18002then :
18003  printf "%s\n" "#define HAVE_STD_SYSLOG 1" >>confdefs.h
18004
18005fi
18006ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
18007if test "x$ac_cv_func_strcasecmp" = xyes
18008then :
18009  printf "%s\n" "#define HAVE_STRCASECMP 1" >>confdefs.h
18010
18011fi
18012ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
18013if test "x$ac_cv_func_strnlen" = xyes
18014then :
18015  printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h
18016
18017fi
18018ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
18019if test "x$ac_cv_func_strptime" = xyes
18020then :
18021  printf "%s\n" "#define HAVE_STRPTIME 1" >>confdefs.h
18022
18023fi
18024ac_fn_c_check_func "$LINENO" "strtok_r" "ac_cv_func_strtok_r"
18025if test "x$ac_cv_func_strtok_r" = xyes
18026then :
18027  printf "%s\n" "#define HAVE_STRTOK_R 1" >>confdefs.h
18028
18029fi
18030ac_fn_c_check_func "$LINENO" "symlink" "ac_cv_func_symlink"
18031if test "x$ac_cv_func_symlink" = xyes
18032then :
18033  printf "%s\n" "#define HAVE_SYMLINK 1" >>confdefs.h
18034
18035fi
18036ac_fn_c_check_func "$LINENO" "tzset" "ac_cv_func_tzset"
18037if test "x$ac_cv_func_tzset" = xyes
18038then :
18039  printf "%s\n" "#define HAVE_TZSET 1" >>confdefs.h
18040
18041fi
18042ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
18043if test "x$ac_cv_func_unsetenv" = xyes
18044then :
18045  printf "%s\n" "#define HAVE_UNSETENV 1" >>confdefs.h
18046
18047fi
18048ac_fn_c_check_func "$LINENO" "usleep" "ac_cv_func_usleep"
18049if test "x$ac_cv_func_usleep" = xyes
18050then :
18051  printf "%s\n" "#define HAVE_USLEEP 1" >>confdefs.h
18052
18053fi
18054ac_fn_c_check_func "$LINENO" "utime" "ac_cv_func_utime"
18055if test "x$ac_cv_func_utime" = xyes
18056then :
18057  printf "%s\n" "#define HAVE_UTIME 1" >>confdefs.h
18058
18059fi
18060ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf"
18061if test "x$ac_cv_func_vasprintf" = xyes
18062then :
18063  printf "%s\n" "#define HAVE_VASPRINTF 1" >>confdefs.h
18064
18065fi
18066ac_fn_c_check_func "$LINENO" "asprintf" "ac_cv_func_asprintf"
18067if test "x$ac_cv_func_asprintf" = xyes
18068then :
18069  printf "%s\n" "#define HAVE_ASPRINTF 1" >>confdefs.h
18070
18071fi
18072ac_fn_c_check_func "$LINENO" "nanosleep" "ac_cv_func_nanosleep"
18073if test "x$ac_cv_func_nanosleep" = xyes
18074then :
18075  printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h
18076
18077fi
18078ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem"
18079if test "x$ac_cv_func_memmem" = xyes
18080then :
18081  printf "%s\n" "#define HAVE_MEMMEM 1" >>confdefs.h
18082
18083fi
18084
18085
18086
18087
18088    ac_ext=c
18089ac_cpp='$CPP $CPPFLAGS'
18090ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18091ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18092ac_compiler_gnu=$ac_cv_c_compiler_gnu
18093
18094    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how many arguments gethostbyname_r() takes" >&5
18095printf %s "checking how many arguments gethostbyname_r() takes... " >&6; }
18096
18097    if test ${ac_cv_func_which_gethostbyname_r+y}
18098then :
18099  printf %s "(cached) " >&6
18100else $as_nop
18101
18102
18103################################################################
18104
18105ac_cv_func_which_gethostbyname_r=unknown
18106
18107#
18108# ONE ARGUMENT (sanity check)
18109#
18110
18111# This should fail, as there is no variant of gethostbyname_r() that takes
18112# a single argument. If it actually compiles, then we can assume that
18113# netdb.h is not declaring the function, and the compiler is thereby
18114# assuming an implicit prototype. In which case, we're out of luck.
18115#
18116cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18117/* end confdefs.h.  */
18118#include <netdb.h>
18119int
18120main (void)
18121{
18122
18123            char *name = "www.gnu.org";
18124            (void)gethostbyname_r(name) /* ; */
18125
18126  ;
18127  return 0;
18128}
18129_ACEOF
18130if ac_fn_c_try_compile "$LINENO"
18131then :
18132  ac_cv_func_which_gethostbyname_r=no
18133fi
18134rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18135
18136#
18137# SIX ARGUMENTS
18138# (e.g. Linux)
18139#
18140
18141if test "$ac_cv_func_which_gethostbyname_r" = "unknown"; then
18142
18143cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18144/* end confdefs.h.  */
18145#include <netdb.h>
18146int
18147main (void)
18148{
18149
18150            char *name = "www.gnu.org";
18151            struct hostent ret, *retp;
18152            char buf[1024];
18153            int buflen = 1024;
18154            int my_h_errno;
18155            (void)gethostbyname_r(name, &ret, buf, buflen, &retp, &my_h_errno) /* ; */
18156
18157  ;
18158  return 0;
18159}
18160_ACEOF
18161if ac_fn_c_try_compile "$LINENO"
18162then :
18163  ac_cv_func_which_gethostbyname_r=six
18164fi
18165rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18166
18167fi
18168
18169#
18170# FIVE ARGUMENTS
18171# (e.g. Solaris)
18172#
18173
18174if test "$ac_cv_func_which_gethostbyname_r" = "unknown"; then
18175
18176cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18177/* end confdefs.h.  */
18178#include <netdb.h>
18179int
18180main (void)
18181{
18182
18183            char *name = "www.gnu.org";
18184            struct hostent ret;
18185            char buf[1024];
18186            int buflen = 1024;
18187            int my_h_errno;
18188            (void)gethostbyname_r(name, &ret, buf, buflen, &my_h_errno) /* ; */
18189
18190  ;
18191  return 0;
18192}
18193_ACEOF
18194if ac_fn_c_try_compile "$LINENO"
18195then :
18196  ac_cv_func_which_gethostbyname_r=five
18197fi
18198rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18199
18200fi
18201
18202#
18203# THREE ARGUMENTS
18204# (e.g. AIX, HP-UX, Tru64)
18205#
18206
18207if test "$ac_cv_func_which_gethostbyname_r" = "unknown"; then
18208
18209cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18210/* end confdefs.h.  */
18211#include <netdb.h>
18212int
18213main (void)
18214{
18215
18216            char *name = "www.gnu.org";
18217            struct hostent ret;
18218            struct hostent_data data;
18219            (void)gethostbyname_r(name, &ret, &data) /* ; */
18220
18221  ;
18222  return 0;
18223}
18224_ACEOF
18225if ac_fn_c_try_compile "$LINENO"
18226then :
18227  ac_cv_func_which_gethostbyname_r=three
18228fi
18229rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18230
18231fi
18232
18233################################################################
18234
18235
18236fi
18237
18238case "$ac_cv_func_which_gethostbyname_r" in
18239    three|five|six)
18240
18241printf "%s\n" "#define HAVE_GETHOSTBYNAME_R 1" >>confdefs.h
18242
18243    ;;
18244esac
18245
18246case "$ac_cv_func_which_gethostbyname_r" in
18247    three)
18248    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: three" >&5
18249printf "%s\n" "three" >&6; }
18250
18251printf "%s\n" "#define HAVE_FUNC_GETHOSTBYNAME_R_3 1" >>confdefs.h
18252
18253    ;;
18254
18255    five)
18256    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: five" >&5
18257printf "%s\n" "five" >&6; }
18258
18259printf "%s\n" "#define HAVE_FUNC_GETHOSTBYNAME_R_5 1" >>confdefs.h
18260
18261    ;;
18262
18263    six)
18264    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: six" >&5
18265printf "%s\n" "six" >&6; }
18266
18267printf "%s\n" "#define HAVE_FUNC_GETHOSTBYNAME_R_6 1" >>confdefs.h
18268
18269    ;;
18270
18271    no)
18272    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cannot find function declaration in netdb.h" >&5
18273printf "%s\n" "cannot find function declaration in netdb.h" >&6; }
18274    ;;
18275
18276    unknown)
18277    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: can't tell" >&5
18278printf "%s\n" "can't tell" >&6; }
18279    ;;
18280
18281    *)
18282    as_fn_error $? "internal error" "$LINENO" 5
18283    ;;
18284esac
18285
18286ac_ext=c
18287ac_cpp='$CPP $CPPFLAGS'
18288ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18289ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18290ac_compiler_gnu=$ac_cv_c_compiler_gnu
18291
18292
18293
18294
18295
18296
18297  unset ac_cv_lib_rt_nanosleep
18298  unset ac_cv_lib_rt___nanosleep
18299  unset found
18300  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for nanosleep in -lrt" >&5
18301printf %s "checking for nanosleep in -lrt... " >&6; }
18302if test ${ac_cv_lib_rt_nanosleep+y}
18303then :
18304  printf %s "(cached) " >&6
18305else $as_nop
18306  ac_check_lib_save_LIBS=$LIBS
18307LIBS="-lrt  $LIBS"
18308cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18309/* end confdefs.h.  */
18310
18311/* Override any GCC internal prototype to avoid an error.
18312   Use char because int might match the return type of a GCC
18313   builtin and then its argument prototype would still apply.  */
18314char nanosleep ();
18315int
18316main (void)
18317{
18318return nanosleep ();
18319  ;
18320  return 0;
18321}
18322_ACEOF
18323if ac_fn_c_try_link "$LINENO"
18324then :
18325  ac_cv_lib_rt_nanosleep=yes
18326else $as_nop
18327  ac_cv_lib_rt_nanosleep=no
18328fi
18329rm -f core conftest.err conftest.$ac_objext conftest.beam \
18330    conftest$ac_exeext conftest.$ac_ext
18331LIBS=$ac_check_lib_save_LIBS
18332fi
18333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_nanosleep" >&5
18334printf "%s\n" "$ac_cv_lib_rt_nanosleep" >&6; }
18335if test "x$ac_cv_lib_rt_nanosleep" = xyes
18336then :
18337  found=yes
18338else $as_nop
18339
18340    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __nanosleep in -lrt" >&5
18341printf %s "checking for __nanosleep in -lrt... " >&6; }
18342if test ${ac_cv_lib_rt___nanosleep+y}
18343then :
18344  printf %s "(cached) " >&6
18345else $as_nop
18346  ac_check_lib_save_LIBS=$LIBS
18347LIBS="-lrt  $LIBS"
18348cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18349/* end confdefs.h.  */
18350
18351/* Override any GCC internal prototype to avoid an error.
18352   Use char because int might match the return type of a GCC
18353   builtin and then its argument prototype would still apply.  */
18354char __nanosleep ();
18355int
18356main (void)
18357{
18358return __nanosleep ();
18359  ;
18360  return 0;
18361}
18362_ACEOF
18363if ac_fn_c_try_link "$LINENO"
18364then :
18365  ac_cv_lib_rt___nanosleep=yes
18366else $as_nop
18367  ac_cv_lib_rt___nanosleep=no
18368fi
18369rm -f core conftest.err conftest.$ac_objext conftest.beam \
18370    conftest$ac_exeext conftest.$ac_ext
18371LIBS=$ac_check_lib_save_LIBS
18372fi
18373{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt___nanosleep" >&5
18374printf "%s\n" "$ac_cv_lib_rt___nanosleep" >&6; }
18375if test "x$ac_cv_lib_rt___nanosleep" = xyes
18376then :
18377  found=yes
18378else $as_nop
18379  found=no
18380fi
18381
18382
18383fi
18384
18385
18386  if test "$found" = "yes"; then
18387    ac_libs=$LIBS
18388    LIBS="$LIBS -lrt"
18389    if test "$cross_compiling" = yes
18390then :
18391
18392            found=yes
18393
18394else $as_nop
18395  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18396/* end confdefs.h.  */
18397int main() { return (0); }
18398_ACEOF
18399if ac_fn_c_try_run "$LINENO"
18400then :
18401  found=yes
18402else $as_nop
18403  found=no
18404fi
18405rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18406  conftest.$ac_objext conftest.beam conftest.$ac_ext
18407fi
18408
18409    LIBS=$ac_libs
18410  fi
18411
18412  if test "$found" = "yes"; then
18413
18414
18415  case rt in
18416  c|c_r) ;;
18417  *)
18418      LIBS="-lrt $LIBS"
18419   ;;
18420  esac
18421
18422
18423
18424printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h
18425
18426
18427printf "%s\n" "#define HAVE_LIBRT 1" >>confdefs.h
18428
18429    ac_cv_func_nanosleep=yes
18430  else
18431
18432  :
18433
18434  fi
18435
18436
18437
18438
18439
18440  unset ac_cv_lib_network_setsockopt
18441  unset ac_cv_lib_network___setsockopt
18442  unset found
18443  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setsockopt in -lnetwork" >&5
18444printf %s "checking for setsockopt in -lnetwork... " >&6; }
18445if test ${ac_cv_lib_network_setsockopt+y}
18446then :
18447  printf %s "(cached) " >&6
18448else $as_nop
18449  ac_check_lib_save_LIBS=$LIBS
18450LIBS="-lnetwork  $LIBS"
18451cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18452/* end confdefs.h.  */
18453
18454/* Override any GCC internal prototype to avoid an error.
18455   Use char because int might match the return type of a GCC
18456   builtin and then its argument prototype would still apply.  */
18457char setsockopt ();
18458int
18459main (void)
18460{
18461return setsockopt ();
18462  ;
18463  return 0;
18464}
18465_ACEOF
18466if ac_fn_c_try_link "$LINENO"
18467then :
18468  ac_cv_lib_network_setsockopt=yes
18469else $as_nop
18470  ac_cv_lib_network_setsockopt=no
18471fi
18472rm -f core conftest.err conftest.$ac_objext conftest.beam \
18473    conftest$ac_exeext conftest.$ac_ext
18474LIBS=$ac_check_lib_save_LIBS
18475fi
18476{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_setsockopt" >&5
18477printf "%s\n" "$ac_cv_lib_network_setsockopt" >&6; }
18478if test "x$ac_cv_lib_network_setsockopt" = xyes
18479then :
18480  found=yes
18481else $as_nop
18482
18483    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __setsockopt in -lnetwork" >&5
18484printf %s "checking for __setsockopt in -lnetwork... " >&6; }
18485if test ${ac_cv_lib_network___setsockopt+y}
18486then :
18487  printf %s "(cached) " >&6
18488else $as_nop
18489  ac_check_lib_save_LIBS=$LIBS
18490LIBS="-lnetwork  $LIBS"
18491cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18492/* end confdefs.h.  */
18493
18494/* Override any GCC internal prototype to avoid an error.
18495   Use char because int might match the return type of a GCC
18496   builtin and then its argument prototype would still apply.  */
18497char __setsockopt ();
18498int
18499main (void)
18500{
18501return __setsockopt ();
18502  ;
18503  return 0;
18504}
18505_ACEOF
18506if ac_fn_c_try_link "$LINENO"
18507then :
18508  ac_cv_lib_network___setsockopt=yes
18509else $as_nop
18510  ac_cv_lib_network___setsockopt=no
18511fi
18512rm -f core conftest.err conftest.$ac_objext conftest.beam \
18513    conftest$ac_exeext conftest.$ac_ext
18514LIBS=$ac_check_lib_save_LIBS
18515fi
18516{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network___setsockopt" >&5
18517printf "%s\n" "$ac_cv_lib_network___setsockopt" >&6; }
18518if test "x$ac_cv_lib_network___setsockopt" = xyes
18519then :
18520  found=yes
18521else $as_nop
18522  found=no
18523fi
18524
18525
18526fi
18527
18528
18529  if test "$found" = "yes"; then
18530    ac_libs=$LIBS
18531    LIBS="$LIBS -lnetwork"
18532    if test "$cross_compiling" = yes
18533then :
18534
18535            found=yes
18536
18537else $as_nop
18538  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18539/* end confdefs.h.  */
18540int main() { return (0); }
18541_ACEOF
18542if ac_fn_c_try_run "$LINENO"
18543then :
18544  found=yes
18545else $as_nop
18546  found=no
18547fi
18548rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18549  conftest.$ac_objext conftest.beam conftest.$ac_ext
18550fi
18551
18552    LIBS=$ac_libs
18553  fi
18554
18555  if test "$found" = "yes"; then
18556
18557
18558  case network in
18559  c|c_r) ;;
18560  *)
18561      LIBS="-lnetwork $LIBS"
18562   ;;
18563  esac
18564
18565
18566
18567printf "%s\n" "#define HAVE_SETSOCKOPT 1" >>confdefs.h
18568
18569
18570printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h
18571
18572    ac_cv_func_setsockopt=yes
18573  else
18574
18575  :
18576
18577  fi
18578
18579
18580
18581{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
18582printf %s "checking for getaddrinfo... " >&6; }
18583if test ${ac_cv_func_getaddrinfo+y}
18584then :
18585  printf %s "(cached) " >&6
18586else $as_nop
18587  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18588/* end confdefs.h.  */
18589#include <netdb.h>
18590int
18591main (void)
18592{
18593struct addrinfo *g,h;g=&h;getaddrinfo("","",g,&g);
18594  ;
18595  return 0;
18596}
18597_ACEOF
18598if ac_fn_c_try_link "$LINENO"
18599then :
18600  if test "$cross_compiling" = yes
18601then :
18602
18603        case $host_alias in
18604      *linux*)
18605        ac_cv_func_getaddrinfo=yes
18606        ;;
18607      *)
18608        ac_cv_func_getaddrinfo=no
18609        ;;
18610    esac
18611
18612else $as_nop
18613  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18614/* end confdefs.h.  */
18615
18616#include <string.h>
18617#include <netdb.h>
18618#include <sys/types.h>
18619#include <string.h>
18620#include <stdlib.h>
18621#ifndef AF_INET
18622# include <sys/socket.h>
18623#endif
18624int main(void) {
18625  struct addrinfo *ai, *pai, hints;
18626
18627  memset(&hints, 0, sizeof(hints));
18628  hints.ai_flags = AI_NUMERICHOST;
18629
18630  if (getaddrinfo("127.0.0.1", 0, &hints, &ai) < 0) {
18631    return 1;
18632  }
18633
18634  if (ai == 0) {
18635    return 1;
18636  }
18637
18638  pai = ai;
18639
18640  while (pai) {
18641    if (pai->ai_family != AF_INET) {
18642      /* 127.0.0.1/NUMERICHOST should only resolve ONE way */
18643      return 1;
18644    }
18645    if (pai->ai_addr->sa_family != AF_INET) {
18646      /* 127.0.0.1/NUMERICHOST should only resolve ONE way */
18647      return 1;
18648    }
18649    pai = pai->ai_next;
18650  }
18651  freeaddrinfo(ai);
18652  return 0;
18653}
18654
18655_ACEOF
18656if ac_fn_c_try_run "$LINENO"
18657then :
18658  ac_cv_func_getaddrinfo=yes
18659else $as_nop
18660  ac_cv_func_getaddrinfo=no
18661fi
18662rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18663  conftest.$ac_objext conftest.beam conftest.$ac_ext
18664fi
18665
18666else $as_nop
18667  ac_cv_func_getaddrinfo=no
18668fi
18669rm -f core conftest.err conftest.$ac_objext conftest.beam \
18670    conftest$ac_exeext conftest.$ac_ext
18671fi
18672{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getaddrinfo" >&5
18673printf "%s\n" "$ac_cv_func_getaddrinfo" >&6; }
18674if test "$ac_cv_func_getaddrinfo" = yes; then
18675
18676printf "%s\n" "#define HAVE_GETADDRINFO 1" >>confdefs.h
18677
18678fi
18679
18680ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
18681if test "x$ac_cv_func_strlcat" = xyes
18682then :
18683  printf "%s\n" "#define HAVE_STRLCAT 1" >>confdefs.h
18684
18685else $as_nop
18686  case " $LIBOBJS " in
18687  *" strlcat.$ac_objext "* ) ;;
18688  *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
18689 ;;
18690esac
18691
18692fi
18693ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
18694if test "x$ac_cv_func_strlcpy" = xyes
18695then :
18696  printf "%s\n" "#define HAVE_STRLCPY 1" >>confdefs.h
18697
18698else $as_nop
18699  case " $LIBOBJS " in
18700  *" strlcpy.$ac_objext "* ) ;;
18701  *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
18702 ;;
18703esac
18704
18705fi
18706ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero"
18707if test "x$ac_cv_func_explicit_bzero" = xyes
18708then :
18709  printf "%s\n" "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h
18710
18711else $as_nop
18712  case " $LIBOBJS " in
18713  *" explicit_bzero.$ac_objext "* ) ;;
18714  *) LIBOBJS="$LIBOBJS explicit_bzero.$ac_objext"
18715 ;;
18716esac
18717
18718fi
18719ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt"
18720if test "x$ac_cv_func_getopt" = xyes
18721then :
18722  printf "%s\n" "#define HAVE_GETOPT 1" >>confdefs.h
18723
18724else $as_nop
18725  case " $LIBOBJS " in
18726  *" getopt.$ac_objext "* ) ;;
18727  *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
18728 ;;
18729esac
18730
18731fi
18732
18733# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
18734# for constant arguments.  Useless!
18735{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
18736printf %s "checking for working alloca.h... " >&6; }
18737if test ${ac_cv_working_alloca_h+y}
18738then :
18739  printf %s "(cached) " >&6
18740else $as_nop
18741  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18742/* end confdefs.h.  */
18743#include <alloca.h>
18744int
18745main (void)
18746{
18747char *p = (char *) alloca (2 * sizeof (int));
18748			  if (p) return 0;
18749  ;
18750  return 0;
18751}
18752_ACEOF
18753if ac_fn_c_try_link "$LINENO"
18754then :
18755  ac_cv_working_alloca_h=yes
18756else $as_nop
18757  ac_cv_working_alloca_h=no
18758fi
18759rm -f core conftest.err conftest.$ac_objext conftest.beam \
18760    conftest$ac_exeext conftest.$ac_ext
18761fi
18762{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
18763printf "%s\n" "$ac_cv_working_alloca_h" >&6; }
18764if test $ac_cv_working_alloca_h = yes; then
18765
18766printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
18767
18768fi
18769
18770{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
18771printf %s "checking for alloca... " >&6; }
18772if test ${ac_cv_func_alloca_works+y}
18773then :
18774  printf %s "(cached) " >&6
18775else $as_nop
18776  if test $ac_cv_working_alloca_h = yes; then
18777  ac_cv_func_alloca_works=yes
18778else
18779  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18780/* end confdefs.h.  */
18781#include <stdlib.h>
18782#include <stddef.h>
18783#ifndef alloca
18784# ifdef __GNUC__
18785#  define alloca __builtin_alloca
18786# elif defined _MSC_VER
18787#  include <malloc.h>
18788#  define alloca _alloca
18789# else
18790#  ifdef  __cplusplus
18791extern "C"
18792#  endif
18793void *alloca (size_t);
18794# endif
18795#endif
18796
18797int
18798main (void)
18799{
18800char *p = (char *) alloca (1);
18801				    if (p) return 0;
18802  ;
18803  return 0;
18804}
18805_ACEOF
18806if ac_fn_c_try_link "$LINENO"
18807then :
18808  ac_cv_func_alloca_works=yes
18809else $as_nop
18810  ac_cv_func_alloca_works=no
18811fi
18812rm -f core conftest.err conftest.$ac_objext conftest.beam \
18813    conftest$ac_exeext conftest.$ac_ext
18814fi
18815{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
18816printf "%s\n" "$ac_cv_func_alloca_works" >&6; }
18817fi
18818
18819if test $ac_cv_func_alloca_works = yes; then
18820
18821printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h
18822
18823else
18824  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
18825# that cause trouble.  Some versions do not even contain alloca or
18826# contain a buggy version.  If you still want to use their alloca,
18827# use ar to extract alloca.o from them instead of compiling alloca.c.
18828
18829ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
18830
18831printf "%s\n" "#define C_ALLOCA 1" >>confdefs.h
18832
18833
18834{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
18835printf %s "checking stack direction for C alloca... " >&6; }
18836if test ${ac_cv_c_stack_direction+y}
18837then :
18838  printf %s "(cached) " >&6
18839else $as_nop
18840  if test "$cross_compiling" = yes
18841then :
18842  ac_cv_c_stack_direction=0
18843else $as_nop
18844  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18845/* end confdefs.h.  */
18846$ac_includes_default
18847int
18848find_stack_direction (int *addr, int depth)
18849{
18850  int dir, dummy = 0;
18851  if (! addr)
18852    addr = &dummy;
18853  *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
18854  dir = depth ? find_stack_direction (addr, depth - 1) : 0;
18855  return dir + dummy;
18856}
18857
18858int
18859main (int argc, char **argv)
18860{
18861  return find_stack_direction (0, argc + !argv + 20) < 0;
18862}
18863_ACEOF
18864if ac_fn_c_try_run "$LINENO"
18865then :
18866  ac_cv_c_stack_direction=1
18867else $as_nop
18868  ac_cv_c_stack_direction=-1
18869fi
18870rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18871  conftest.$ac_objext conftest.beam conftest.$ac_ext
18872fi
18873
18874fi
18875{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
18876printf "%s\n" "$ac_cv_c_stack_direction" >&6; }
18877printf "%s\n" "#define STACK_DIRECTION $ac_cv_c_stack_direction" >>confdefs.h
18878
18879
18880fi
18881
18882
18883{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for type of reentrant time-related functions" >&5
18884printf %s "checking for type of reentrant time-related functions... " >&6; }
18885if test ${ac_cv_time_r_type+y}
18886then :
18887  printf %s "(cached) " >&6
18888else $as_nop
18889
18890if test "$cross_compiling" = yes
18891then :
18892
18893  ac_cv_time_r_type=POSIX
18894
18895else $as_nop
18896  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18897/* end confdefs.h.  */
18898
18899#include <time.h>
18900
18901int main() {
18902char buf[27];
18903struct tm t;
18904time_t old = 0;
18905int r, s;
18906
18907s = gmtime_r(&old, &t);
18908r = (int) asctime_r(&t, buf, 26);
18909if (r == s && s == 0) return (0);
18910return (1);
18911}
18912
18913_ACEOF
18914if ac_fn_c_try_run "$LINENO"
18915then :
18916
18917  ac_cv_time_r_type=hpux
18918
18919else $as_nop
18920
18921  if test "$cross_compiling" = yes
18922then :
18923
18924    ac_cv_time_r_type=POSIX
18925
18926else $as_nop
18927  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18928/* end confdefs.h.  */
18929
18930#include <time.h>
18931int main() {
18932  struct tm t, *s;
18933  time_t old = 0;
18934  char buf[27], *p;
18935
18936  s = gmtime_r(&old, &t);
18937  p = asctime_r(&t, buf, 26);
18938  if (p == buf && s == &t) return (0);
18939  return (1);
18940}
18941
18942_ACEOF
18943if ac_fn_c_try_run "$LINENO"
18944then :
18945
18946    ac_cv_time_r_type=irix
18947
18948else $as_nop
18949
18950    ac_cv_time_r_type=POSIX
18951
18952fi
18953rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18954  conftest.$ac_objext conftest.beam conftest.$ac_ext
18955fi
18956
18957
18958fi
18959rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18960  conftest.$ac_objext conftest.beam conftest.$ac_ext
18961fi
18962
18963
18964fi
18965{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_time_r_type" >&5
18966printf "%s\n" "$ac_cv_time_r_type" >&6; }
18967  case $ac_cv_time_r_type in
18968  hpux)
18969printf "%s\n" "#define PHP_HPUX_TIME_R 1" >>confdefs.h
18970 ;;
18971  irix)
18972printf "%s\n" "#define PHP_IRIX_TIME_R 1" >>confdefs.h
18973 ;;
18974  esac
18975
18976
18977{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for in_addr_t" >&5
18978printf %s "checking for in_addr_t... " >&6; }
18979if test ${ac_cv_type_in_addr_t+y}
18980then :
18981  printf %s "(cached) " >&6
18982else $as_nop
18983  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18984/* end confdefs.h.  */
18985#include <sys/types.h>
18986#include <stdlib.h>
18987#include <stddef.h>
18988#ifdef HAVE_NETINET_IN_H
18989#include <netinet/in.h>
18990#endif
18991_ACEOF
18992if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18993  $EGREP "in_addr_t[^a-zA-Z_0-9]" >/dev/null 2>&1
18994then :
18995  ac_cv_type_in_addr_t=yes
18996else $as_nop
18997  ac_cv_type_in_addr_t=no
18998fi
18999rm -rf conftest*
19000
19001fi
19002{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_in_addr_t" >&5
19003printf "%s\n" "$ac_cv_type_in_addr_t" >&6; }
19004if test $ac_cv_type_in_addr_t = no; then
19005
19006printf "%s\n" "#define in_addr_t u_int" >>confdefs.h
19007
19008fi
19009
19010
19011{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for aarch64 CRC32 API" >&5
19012printf %s "checking for aarch64 CRC32 API... " >&6; }
19013if test ${ac_cv_func___crc32d+y}
19014then :
19015  printf %s "(cached) " >&6
19016else $as_nop
19017  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19018/* end confdefs.h.  */
19019#include <arm_acle.h>
19020int
19021main (void)
19022{
19023__crc32d(0, 0);
19024  ;
19025  return 0;
19026}
19027_ACEOF
19028if ac_fn_c_try_link "$LINENO"
19029then :
19030  ac_cv_func___crc32d=yes
19031else $as_nop
19032  ac_cv_func___crc32d="no"
19033fi
19034rm -f core conftest.err conftest.$ac_objext conftest.beam \
19035    conftest$ac_exeext conftest.$ac_ext
19036fi
19037{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func___crc32d" >&5
19038printf "%s\n" "$ac_cv_func___crc32d" >&6; }
19039if test "$ac_cv_func___crc32d" = "yes"; then
19040
19041printf "%s\n" "#define HAVE_AARCH64_CRC32 1" >>confdefs.h
19042
19043fi
19044
19045{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for asm goto" >&5
19046printf %s "checking for asm goto... " >&6; }
19047if test ${ac_cv__asm_goto+y}
19048then :
19049  printf %s "(cached) " >&6
19050else $as_nop
19051  if test "$cross_compiling" = yes
19052then :
19053
19054    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19055/* end confdefs.h.  */
19056
19057int main(void) {
19058#if defined(__x86_64__) || defined(__i386__)
19059    __asm__ goto("jmp %l0\n" :::: end);
19060#elif defined(__aarch64__)
19061    __asm__ goto("b %l0\n" :::: end);
19062#endif
19063end:
19064    return 0;
19065}
19066
19067_ACEOF
19068if ac_fn_c_try_compile "$LINENO"
19069then :
19070  ac_cv__asm_goto=yes
19071else $as_nop
19072  ac_cv__asm_goto=no
19073fi
19074rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
19075
19076else $as_nop
19077  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19078/* end confdefs.h.  */
19079
19080int main(void) {
19081#if defined(__x86_64__) || defined(__i386__)
19082    __asm__ goto("jmp %l0\n" :::: end);
19083#elif defined(__aarch64__)
19084    __asm__ goto("b %l0\n" :::: end);
19085#endif
19086end:
19087    return 0;
19088}
19089
19090_ACEOF
19091if ac_fn_c_try_run "$LINENO"
19092then :
19093  ac_cv__asm_goto=yes
19094else $as_nop
19095  ac_cv__asm_goto=no
19096fi
19097rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19098  conftest.$ac_objext conftest.beam conftest.$ac_ext
19099fi
19100
19101fi
19102{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv__asm_goto" >&5
19103printf "%s\n" "$ac_cv__asm_goto" >&6; }
19104
19105if test "$ac_cv__asm_goto" = yes; then
19106
19107printf "%s\n" "#define HAVE_ASM_GOTO 1" >>confdefs.h
19108
19109fi
19110
19111
19112php_with_valgrind=yes
19113
19114{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable valgrind support" >&5
19115printf %s "checking whether to enable valgrind support... " >&6; }
19116
19117# Check whether --with-valgrind was given.
19118if test ${with_valgrind+y}
19119then :
19120  withval=$with_valgrind; PHP_VALGRIND=$withval
19121else $as_nop
19122
19123  PHP_VALGRIND=yes
19124
19125
19126fi
19127
19128
19129ext_output=$PHP_VALGRIND
19130{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19131printf "%s\n" "$ext_output" >&6; }
19132
19133
19134
19135
19136if test "$PHP_VALGRIND" != "no"; then
19137
19138pkg_failed=no
19139{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for valgrind" >&5
19140printf %s "checking for valgrind... " >&6; }
19141
19142if test -n "$VALGRIND_CFLAGS"; then
19143    pkg_cv_VALGRIND_CFLAGS="$VALGRIND_CFLAGS"
19144 elif test -n "$PKG_CONFIG"; then
19145    if test -n "$PKG_CONFIG" && \
19146    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"valgrind\""; } >&5
19147  ($PKG_CONFIG --exists --print-errors "valgrind") 2>&5
19148  ac_status=$?
19149  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
19150  test $ac_status = 0; }; then
19151  pkg_cv_VALGRIND_CFLAGS=`$PKG_CONFIG --cflags "valgrind" 2>/dev/null`
19152		      test "x$?" != "x0" && pkg_failed=yes
19153else
19154  pkg_failed=yes
19155fi
19156 else
19157    pkg_failed=untried
19158fi
19159if test -n "$VALGRIND_LIBS"; then
19160    pkg_cv_VALGRIND_LIBS="$VALGRIND_LIBS"
19161 elif test -n "$PKG_CONFIG"; then
19162    if test -n "$PKG_CONFIG" && \
19163    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"valgrind\""; } >&5
19164  ($PKG_CONFIG --exists --print-errors "valgrind") 2>&5
19165  ac_status=$?
19166  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
19167  test $ac_status = 0; }; then
19168  pkg_cv_VALGRIND_LIBS=`$PKG_CONFIG --libs "valgrind" 2>/dev/null`
19169		      test "x$?" != "x0" && pkg_failed=yes
19170else
19171  pkg_failed=yes
19172fi
19173 else
19174    pkg_failed=untried
19175fi
19176
19177
19178
19179if test $pkg_failed = yes; then
19180        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19181printf "%s\n" "no" >&6; }
19182
19183if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
19184        _pkg_short_errors_supported=yes
19185else
19186        _pkg_short_errors_supported=no
19187fi
19188        if test $_pkg_short_errors_supported = yes; then
19189	        VALGRIND_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "valgrind" 2>&1`
19190        else
19191	        VALGRIND_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "valgrind" 2>&1`
19192        fi
19193	# Put the nasty error message in config.log where it belongs
19194	echo "$VALGRIND_PKG_ERRORS" >&5
19195
19196	have_valgrind="no"
19197elif test $pkg_failed = untried; then
19198        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
19199printf "%s\n" "no" >&6; }
19200	have_valgrind="no"
19201else
19202	VALGRIND_CFLAGS=$pkg_cv_VALGRIND_CFLAGS
19203	VALGRIND_LIBS=$pkg_cv_VALGRIND_LIBS
19204        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19205printf "%s\n" "yes" >&6; }
19206	have_valgrind="yes"
19207fi
19208
19209  if test "$have_valgrind" = "yes"; then
19210
19211  for ac_i in $VALGRIND_CFLAGS; do
19212    case $ac_i in
19213    -I*)
19214      ac_ii=`echo $ac_i|cut -c 3-`
19215
19216  if test "$ac_ii" != "/usr/include"; then
19217
19218  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
19219    ai_p=$ac_ii
19220  else
19221
19222    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
19223
19224    ep_realdir=`(cd "$ep_dir" && pwd)`
19225    ai_p="$ep_realdir"/`basename "$ac_ii"`
19226  fi
19227
19228
19229
19230  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
19231
19232  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
19233  if test -n "$unique" && test "`eval $cmd`" = "" ; then
19234    eval "INCLUDEPATH$unique=set"
19235
19236      if test ""; then
19237        INCLUDES="-I$ai_p $INCLUDES"
19238      else
19239        INCLUDES="$INCLUDES -I$ai_p"
19240      fi
19241
19242  fi
19243
19244  fi
19245
19246    ;;
19247    esac
19248  done
19249
19250
19251printf "%s\n" "#define HAVE_VALGRIND 1" >>confdefs.h
19252
19253  else
19254    if test "$with_valgrind" = "yes"; then
19255      as_fn_error $? "Valgrind not found. Please install Valgrind." "$LINENO" 5
19256    fi
19257  fi
19258fi
19259
19260
19261  unset ac_cv_func_openpty
19262  unset ac_cv_func___openpty
19263  unset found
19264
19265  ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty"
19266if test "x$ac_cv_func_openpty" = xyes
19267then :
19268  found=yes
19269else $as_nop
19270   ac_fn_c_check_func "$LINENO" "__openpty" "ac_cv_func___openpty"
19271if test "x$ac_cv_func___openpty" = xyes
19272then :
19273  found=yes
19274else $as_nop
19275  found=no
19276fi
19277
19278fi
19279
19280
19281  case $found in
19282  yes)
19283
19284printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
19285
19286    ac_cv_func_openpty=yes
19287  ;;
19288
19289    *)
19290
19291  unset ac_cv_lib_util_openpty
19292  unset ac_cv_lib_util___openpty
19293  unset found
19294  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openpty in -lutil" >&5
19295printf %s "checking for openpty in -lutil... " >&6; }
19296if test ${ac_cv_lib_util_openpty+y}
19297then :
19298  printf %s "(cached) " >&6
19299else $as_nop
19300  ac_check_lib_save_LIBS=$LIBS
19301LIBS="-lutil  $LIBS"
19302cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19303/* end confdefs.h.  */
19304
19305/* Override any GCC internal prototype to avoid an error.
19306   Use char because int might match the return type of a GCC
19307   builtin and then its argument prototype would still apply.  */
19308char openpty ();
19309int
19310main (void)
19311{
19312return openpty ();
19313  ;
19314  return 0;
19315}
19316_ACEOF
19317if ac_fn_c_try_link "$LINENO"
19318then :
19319  ac_cv_lib_util_openpty=yes
19320else $as_nop
19321  ac_cv_lib_util_openpty=no
19322fi
19323rm -f core conftest.err conftest.$ac_objext conftest.beam \
19324    conftest$ac_exeext conftest.$ac_ext
19325LIBS=$ac_check_lib_save_LIBS
19326fi
19327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_openpty" >&5
19328printf "%s\n" "$ac_cv_lib_util_openpty" >&6; }
19329if test "x$ac_cv_lib_util_openpty" = xyes
19330then :
19331  found=yes
19332else $as_nop
19333
19334    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __openpty in -lutil" >&5
19335printf %s "checking for __openpty in -lutil... " >&6; }
19336if test ${ac_cv_lib_util___openpty+y}
19337then :
19338  printf %s "(cached) " >&6
19339else $as_nop
19340  ac_check_lib_save_LIBS=$LIBS
19341LIBS="-lutil  $LIBS"
19342cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19343/* end confdefs.h.  */
19344
19345/* Override any GCC internal prototype to avoid an error.
19346   Use char because int might match the return type of a GCC
19347   builtin and then its argument prototype would still apply.  */
19348char __openpty ();
19349int
19350main (void)
19351{
19352return __openpty ();
19353  ;
19354  return 0;
19355}
19356_ACEOF
19357if ac_fn_c_try_link "$LINENO"
19358then :
19359  ac_cv_lib_util___openpty=yes
19360else $as_nop
19361  ac_cv_lib_util___openpty=no
19362fi
19363rm -f core conftest.err conftest.$ac_objext conftest.beam \
19364    conftest$ac_exeext conftest.$ac_ext
19365LIBS=$ac_check_lib_save_LIBS
19366fi
19367{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util___openpty" >&5
19368printf "%s\n" "$ac_cv_lib_util___openpty" >&6; }
19369if test "x$ac_cv_lib_util___openpty" = xyes
19370then :
19371  found=yes
19372else $as_nop
19373  found=no
19374fi
19375
19376
19377fi
19378
19379
19380  if test "$found" = "yes"; then
19381    ac_libs=$LIBS
19382    LIBS="$LIBS -lutil"
19383    if test "$cross_compiling" = yes
19384then :
19385
19386            found=yes
19387
19388else $as_nop
19389  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19390/* end confdefs.h.  */
19391int main() { return (0); }
19392_ACEOF
19393if ac_fn_c_try_run "$LINENO"
19394then :
19395  found=yes
19396else $as_nop
19397  found=no
19398fi
19399rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19400  conftest.$ac_objext conftest.beam conftest.$ac_ext
19401fi
19402
19403    LIBS=$ac_libs
19404  fi
19405
19406  if test "$found" = "yes"; then
19407
19408
19409  case util in
19410  c|c_r) ;;
19411  *)
19412      LIBS="-lutil $LIBS"
19413   ;;
19414  esac
19415
19416
19417
19418printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
19419
19420
19421printf "%s\n" "#define HAVE_LIBUTIL 1" >>confdefs.h
19422
19423    ac_cv_func_openpty=yes
19424  else
19425
19426
19427  unset ac_cv_lib_bsd_openpty
19428  unset ac_cv_lib_bsd___openpty
19429  unset found
19430  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openpty in -lbsd" >&5
19431printf %s "checking for openpty in -lbsd... " >&6; }
19432if test ${ac_cv_lib_bsd_openpty+y}
19433then :
19434  printf %s "(cached) " >&6
19435else $as_nop
19436  ac_check_lib_save_LIBS=$LIBS
19437LIBS="-lbsd  $LIBS"
19438cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19439/* end confdefs.h.  */
19440
19441/* Override any GCC internal prototype to avoid an error.
19442   Use char because int might match the return type of a GCC
19443   builtin and then its argument prototype would still apply.  */
19444char openpty ();
19445int
19446main (void)
19447{
19448return openpty ();
19449  ;
19450  return 0;
19451}
19452_ACEOF
19453if ac_fn_c_try_link "$LINENO"
19454then :
19455  ac_cv_lib_bsd_openpty=yes
19456else $as_nop
19457  ac_cv_lib_bsd_openpty=no
19458fi
19459rm -f core conftest.err conftest.$ac_objext conftest.beam \
19460    conftest$ac_exeext conftest.$ac_ext
19461LIBS=$ac_check_lib_save_LIBS
19462fi
19463{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_openpty" >&5
19464printf "%s\n" "$ac_cv_lib_bsd_openpty" >&6; }
19465if test "x$ac_cv_lib_bsd_openpty" = xyes
19466then :
19467  found=yes
19468else $as_nop
19469
19470    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __openpty in -lbsd" >&5
19471printf %s "checking for __openpty in -lbsd... " >&6; }
19472if test ${ac_cv_lib_bsd___openpty+y}
19473then :
19474  printf %s "(cached) " >&6
19475else $as_nop
19476  ac_check_lib_save_LIBS=$LIBS
19477LIBS="-lbsd  $LIBS"
19478cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19479/* end confdefs.h.  */
19480
19481/* Override any GCC internal prototype to avoid an error.
19482   Use char because int might match the return type of a GCC
19483   builtin and then its argument prototype would still apply.  */
19484char __openpty ();
19485int
19486main (void)
19487{
19488return __openpty ();
19489  ;
19490  return 0;
19491}
19492_ACEOF
19493if ac_fn_c_try_link "$LINENO"
19494then :
19495  ac_cv_lib_bsd___openpty=yes
19496else $as_nop
19497  ac_cv_lib_bsd___openpty=no
19498fi
19499rm -f core conftest.err conftest.$ac_objext conftest.beam \
19500    conftest$ac_exeext conftest.$ac_ext
19501LIBS=$ac_check_lib_save_LIBS
19502fi
19503{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd___openpty" >&5
19504printf "%s\n" "$ac_cv_lib_bsd___openpty" >&6; }
19505if test "x$ac_cv_lib_bsd___openpty" = xyes
19506then :
19507  found=yes
19508else $as_nop
19509  found=no
19510fi
19511
19512
19513fi
19514
19515
19516  if test "$found" = "yes"; then
19517    ac_libs=$LIBS
19518    LIBS="$LIBS -lbsd"
19519    if test "$cross_compiling" = yes
19520then :
19521
19522            found=yes
19523
19524else $as_nop
19525  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19526/* end confdefs.h.  */
19527int main() { return (0); }
19528_ACEOF
19529if ac_fn_c_try_run "$LINENO"
19530then :
19531  found=yes
19532else $as_nop
19533  found=no
19534fi
19535rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19536  conftest.$ac_objext conftest.beam conftest.$ac_ext
19537fi
19538
19539    LIBS=$ac_libs
19540  fi
19541
19542  if test "$found" = "yes"; then
19543
19544
19545  case bsd in
19546  c|c_r) ;;
19547  *)
19548      LIBS="-lbsd $LIBS"
19549   ;;
19550  esac
19551
19552
19553
19554printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h
19555
19556
19557printf "%s\n" "#define HAVE_LIBBSD 1" >>confdefs.h
19558
19559    ac_cv_func_openpty=yes
19560  else
19561
19562  :
19563
19564  fi
19565
19566
19567  fi
19568
19569 ;;
19570
19571  esac
19572
19573
19574
19575  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
19576printf "%s\n" "" >&6; }
19577  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}General settings${T_ME}" >&5
19578printf "%s\n" "${T_MD}General settings${T_ME}" >&6; }
19579
19580
19581
19582# Check whether --enable- was given.
19583if test ${enable_+y}
19584then :
19585  enableval=$enable_;
19586fi
19587
19588
19589
19590
19591php_enable_gcov=no
19592
19593{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to include gcov symbols" >&5
19594printf %s "checking whether to include gcov symbols... " >&6; }
19595# Check whether --enable-gcov was given.
19596if test ${enable_gcov+y}
19597then :
19598  enableval=$enable_gcov; PHP_GCOV=$enableval
19599else $as_nop
19600
19601  PHP_GCOV=no
19602
19603
19604fi
19605
19606
19607ext_output=$PHP_GCOV
19608{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19609printf "%s\n" "$ext_output" >&6; }
19610
19611
19612
19613
19614if test "$PHP_GCOV" = "yes"; then
19615
19616  if test "$GCC" != "yes"; then
19617    as_fn_error $? "GCC is required for --enable-gcov" "$LINENO" 5
19618  fi
19619
19620    case `$php_shtool path $CC` in
19621    *ccache*) gcc_ccache=yes;;
19622    *) gcc_ccache=no;;
19623  esac
19624
19625  if test "$gcc_ccache" = "yes" && (test -z "$CCACHE_DISABLE" || test "$CCACHE_DISABLE" != "1"); then
19626    as_fn_error $? "ccache must be disabled when --enable-gcov option is used. You can disable ccache by setting environment variable CCACHE_DISABLE=1." "$LINENO" 5
19627  fi
19628
19629
19630printf "%s\n" "#define HAVE_GCOV 1" >>confdefs.h
19631
19632
19633  src=$abs_srcdir/build/Makefile.gcov
19634  ac_srcdir=$abs_srcdir
19635  ac_builddir=$ext_builddir
19636  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
19637
19638
19639
19640  CFLAGS=`echo "$CFLAGS" | "$SED" -e 's/-O[0-9s]*//g'`
19641  CXXFLAGS=`echo "$CXXFLAGS" | "$SED" -e 's/-O[0-9s]*//g'`
19642
19643
19644    CFLAGS="$CFLAGS -O0 -fprofile-arcs -ftest-coverage"
19645  CXXFLAGS="$CXXFLAGS -O0 -fprofile-arcs -ftest-coverage"
19646fi
19647
19648
19649php_enable_debug=no
19650
19651{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to include debugging symbols" >&5
19652printf %s "checking whether to include debugging symbols... " >&6; }
19653# Check whether --enable-debug was given.
19654if test ${enable_debug+y}
19655then :
19656  enableval=$enable_debug; PHP_DEBUG=$enableval
19657else $as_nop
19658
19659  PHP_DEBUG=no
19660
19661
19662fi
19663
19664
19665ext_output=$PHP_DEBUG
19666{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19667printf "%s\n" "$ext_output" >&6; }
19668
19669
19670
19671
19672if test "$PHP_DEBUG" = "yes"; then
19673  PHP_DEBUG=1
19674  ZEND_DEBUG=yes
19675
19676  CFLAGS=`echo "$CFLAGS" | "$SED" -e 's/-O[0-9s]*//g'`
19677  CXXFLAGS=`echo "$CXXFLAGS" | "$SED" -e 's/-O[0-9s]*//g'`
19678
19679    if test "$GCC" = "yes" || test "$ICC" = "yes"; then
19680    CFLAGS="$CFLAGS -O0"
19681    CXXFLAGS="$CXXFLAGS -g -O0"
19682  fi
19683  if test "$SUNCC" = "yes"; then
19684    if test -n "$auto_cflags"; then
19685      CFLAGS="-g"
19686      CXXFLAGS="-g"
19687    else
19688      CFLAGS="$CFLAGS -g"
19689      CXXFLAGS="$CFLAGS -g"
19690    fi
19691  fi
19692else
19693  PHP_DEBUG=0
19694  ZEND_DEBUG=no
19695fi
19696
19697
19698php_enable_debug_assertions=no
19699
19700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable debug assertions in release mode" >&5
19701printf %s "checking whether to enable debug assertions in release mode... " >&6; }
19702# Check whether --enable-debug-assertions was given.
19703if test ${enable_debug_assertions+y}
19704then :
19705  enableval=$enable_debug_assertions; PHP_DEBUG_ASSERTIONS=$enableval
19706else $as_nop
19707
19708  PHP_DEBUG_ASSERTIONS=no
19709
19710
19711fi
19712
19713
19714ext_output=$PHP_DEBUG_ASSERTIONS
19715{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19716printf "%s\n" "$ext_output" >&6; }
19717
19718
19719
19720
19721if test "$PHP_DEBUG_ASSERTIONS" = "yes"; then
19722  PHP_DEBUG=1
19723  ZEND_DEBUG=yes
19724fi
19725
19726# Check whether --enable-zts was given.
19727if test ${enable_zts+y}
19728then :
19729  enableval=$enable_zts; ZEND_ZTS=$enableval
19730else $as_nop
19731  ZEND_ZTS=no
19732fi
19733
19734
19735if test "$ZEND_ZTS" = "yes"; then
19736
19737printf "%s\n" "#define ZTS 1" >>confdefs.h
19738
19739  PHP_THREAD_SAFETY=yes
19740else
19741  PHP_THREAD_SAFETY=no
19742fi
19743
19744
19745php_enable_rtld_now=no
19746
19747{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to dlopen extensions with RTLD_NOW instead of RTLD_LAZY" >&5
19748printf %s "checking whether to dlopen extensions with RTLD_NOW instead of RTLD_LAZY... " >&6; }
19749# Check whether --enable-rtld-now was given.
19750if test ${enable_rtld_now+y}
19751then :
19752  enableval=$enable_rtld_now; PHP_RTLD_NOW=$enableval
19753else $as_nop
19754
19755  PHP_RTLD_NOW=no
19756
19757
19758fi
19759
19760
19761ext_output=$PHP_RTLD_NOW
19762{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19763printf "%s\n" "$ext_output" >&6; }
19764
19765
19766
19767
19768if test "$PHP_RTLD_NOW" = "yes"; then
19769
19770printf "%s\n" "#define PHP_USE_RTLD_NOW 1" >>confdefs.h
19771
19772fi
19773
19774
19775php_with_layout=PHP
19776
19777{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking layout of installed files" >&5
19778printf %s "checking layout of installed files... " >&6; }
19779
19780# Check whether --with-layout was given.
19781if test ${with_layout+y}
19782then :
19783  withval=$with_layout; PHP_LAYOUT=$withval
19784else $as_nop
19785
19786  PHP_LAYOUT=PHP
19787
19788
19789fi
19790
19791
19792ext_output=$PHP_LAYOUT
19793{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19794printf "%s\n" "$ext_output" >&6; }
19795
19796
19797
19798
19799case $PHP_LAYOUT in
19800  GNU)
19801    oldstyleextdir=no
19802    ;;
19803  *)
19804    oldstyleextdir=yes
19805    ;;
19806esac
19807
19808
19809php_with_config_file_path=DEFAULT
19810
19811{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking path to configuration file" >&5
19812printf %s "checking path to configuration file... " >&6; }
19813
19814# Check whether --with-config-file-path was given.
19815if test ${with_config_file_path+y}
19816then :
19817  withval=$with_config_file_path; PHP_CONFIG_FILE_PATH=$withval
19818else $as_nop
19819
19820  PHP_CONFIG_FILE_PATH=DEFAULT
19821
19822
19823fi
19824
19825
19826ext_output=$PHP_CONFIG_FILE_PATH
19827{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19828printf "%s\n" "$ext_output" >&6; }
19829
19830
19831
19832
19833if test "$PHP_CONFIG_FILE_PATH" = "DEFAULT"; then
19834  case $PHP_LAYOUT in
19835    GNU)
19836      PHP_CONFIG_FILE_PATH=$sysconfdir
19837      ;;
19838    *)
19839      PHP_CONFIG_FILE_PATH=$libdir
19840      ;;
19841  esac
19842fi
19843
19844{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking where to scan for configuration files" >&5
19845printf %s "checking where to scan for configuration files... " >&6; }
19846
19847php_with_config_file_scan_dir=DEFAULT
19848
19849
19850
19851# Check whether --with-config-file-scan-dir was given.
19852if test ${with_config_file_scan_dir+y}
19853then :
19854  withval=$with_config_file_scan_dir; PHP_CONFIG_FILE_SCAN_DIR=$withval
19855else $as_nop
19856
19857  PHP_CONFIG_FILE_SCAN_DIR=DEFAULT
19858
19859
19860fi
19861
19862
19863ext_output=$PHP_CONFIG_FILE_SCAN_DIR
19864
19865
19866
19867
19868
19869if test "$PHP_CONFIG_FILE_SCAN_DIR" = "DEFAULT"; then
19870  PHP_CONFIG_FILE_SCAN_DIR=
19871fi
19872{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_CONFIG_FILE_SCAN_DIR" >&5
19873printf "%s\n" "$PHP_CONFIG_FILE_SCAN_DIR" >&6; }
19874
19875test -n "$DEBUG_CFLAGS" && CFLAGS="$CFLAGS $DEBUG_CFLAGS"
19876
19877
19878php_enable_sigchild=no
19879
19880{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable PHP's own SIGCHLD handler" >&5
19881printf %s "checking whether to enable PHP's own SIGCHLD handler... " >&6; }
19882# Check whether --enable-sigchild was given.
19883if test ${enable_sigchild+y}
19884then :
19885  enableval=$enable_sigchild; PHP_SIGCHILD=$enableval
19886else $as_nop
19887
19888  PHP_SIGCHILD=no
19889
19890
19891fi
19892
19893
19894ext_output=$PHP_SIGCHILD
19895{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19896printf "%s\n" "$ext_output" >&6; }
19897
19898
19899
19900
19901if test "$PHP_SIGCHILD" = "yes"; then
19902
19903printf "%s\n" "#define PHP_SIGCHILD 1" >>confdefs.h
19904
19905else
19906
19907printf "%s\n" "#define PHP_SIGCHILD 0" >>confdefs.h
19908
19909fi
19910
19911
19912php_enable_libgcc=no
19913
19914{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to explicitly link against libgcc" >&5
19915printf %s "checking whether to explicitly link against libgcc... " >&6; }
19916# Check whether --enable-libgcc was given.
19917if test ${enable_libgcc+y}
19918then :
19919  enableval=$enable_libgcc; PHP_LIBGCC=$enableval
19920else $as_nop
19921
19922  PHP_LIBGCC=no
19923
19924
19925fi
19926
19927
19928ext_output=$PHP_LIBGCC
19929{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
19930printf "%s\n" "$ext_output" >&6; }
19931
19932
19933
19934
19935if test "$PHP_LIBGCC" = "yes"; then
19936
19937
19938  libgcc_libpath=`gcc --print-libgcc-file-name|$SED 's%/*[^/][^/]*$%%'`
19939
19940
19941  if test -z "$libgcc_libpath"; then
19942    as_fn_error $? "Cannot locate libgcc. Make sure that gcc is in your path" "$LINENO" 5
19943  fi
19944
19945  if test "$libgcc_libpath" != "/usr/$PHP_LIBDIR" && test "$libgcc_libpath" != "/usr/lib"; then
19946
19947  if test -z "$libgcc_libpath" || echo "$libgcc_libpath" | grep '^/' >/dev/null ; then
19948    ai_p=$libgcc_libpath
19949  else
19950
19951    ep_dir=`echo $libgcc_libpath|$SED 's%/*[^/][^/]*/*$%%'`
19952
19953    ep_realdir=`(cd "$ep_dir" && pwd)`
19954    ai_p="$ep_realdir"/`basename "$libgcc_libpath"`
19955  fi
19956
19957
19958
19959
19960
19961  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
19962
19963  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
19964  if test -n "$unique" && test "`eval $cmd`" = "" ; then
19965    eval "LIBPATH$unique=set"
19966
19967    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
19968    LDFLAGS="$LDFLAGS -L$ai_p"
19969    PHP_RPATHS="$PHP_RPATHS $ai_p"
19970
19971  fi
19972
19973
19974
19975  fi
19976
19977
19978
19979  case gcc in
19980  c|c_r) ;;
19981  *)
19982      LIBS="$LIBS -lgcc"
19983   ;;
19984  esac
19985
19986
19987fi
19988
19989
19990php_enable_short_tags=yes
19991
19992{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable short tags by default" >&5
19993printf %s "checking whether to enable short tags by default... " >&6; }
19994# Check whether --enable-short-tags was given.
19995if test ${enable_short_tags+y}
19996then :
19997  enableval=$enable_short_tags; PHP_SHORT_TAGS=$enableval
19998else $as_nop
19999
20000  PHP_SHORT_TAGS=yes
20001
20002
20003fi
20004
20005
20006ext_output=$PHP_SHORT_TAGS
20007{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
20008printf "%s\n" "$ext_output" >&6; }
20009
20010
20011
20012
20013if test "$PHP_SHORT_TAGS" = "yes"; then
20014
20015printf "%s\n" "#define DEFAULT_SHORT_OPEN_TAG \"1\"" >>confdefs.h
20016
20017else
20018
20019printf "%s\n" "#define DEFAULT_SHORT_OPEN_TAG \"0\"" >>confdefs.h
20020
20021fi
20022
20023
20024php_enable_dmalloc=no
20025
20026{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable dmalloc" >&5
20027printf %s "checking whether to enable dmalloc... " >&6; }
20028# Check whether --enable-dmalloc was given.
20029if test ${enable_dmalloc+y}
20030then :
20031  enableval=$enable_dmalloc; PHP_DMALLOC=$enableval
20032else $as_nop
20033
20034  PHP_DMALLOC=no
20035
20036
20037fi
20038
20039
20040ext_output=$PHP_DMALLOC
20041{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
20042printf "%s\n" "$ext_output" >&6; }
20043
20044
20045
20046
20047if test "$PHP_DMALLOC" = "yes"; then
20048  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dmalloc_error in -ldmalloc" >&5
20049printf %s "checking for dmalloc_error in -ldmalloc... " >&6; }
20050if test ${ac_cv_lib_dmalloc_dmalloc_error+y}
20051then :
20052  printf %s "(cached) " >&6
20053else $as_nop
20054  ac_check_lib_save_LIBS=$LIBS
20055LIBS="-ldmalloc  $LIBS"
20056cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20057/* end confdefs.h.  */
20058
20059/* Override any GCC internal prototype to avoid an error.
20060   Use char because int might match the return type of a GCC
20061   builtin and then its argument prototype would still apply.  */
20062char dmalloc_error ();
20063int
20064main (void)
20065{
20066return dmalloc_error ();
20067  ;
20068  return 0;
20069}
20070_ACEOF
20071if ac_fn_c_try_link "$LINENO"
20072then :
20073  ac_cv_lib_dmalloc_dmalloc_error=yes
20074else $as_nop
20075  ac_cv_lib_dmalloc_dmalloc_error=no
20076fi
20077rm -f core conftest.err conftest.$ac_objext conftest.beam \
20078    conftest$ac_exeext conftest.$ac_ext
20079LIBS=$ac_check_lib_save_LIBS
20080fi
20081{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dmalloc_dmalloc_error" >&5
20082printf "%s\n" "$ac_cv_lib_dmalloc_dmalloc_error" >&6; }
20083if test "x$ac_cv_lib_dmalloc_dmalloc_error" = xyes
20084then :
20085
20086
20087
20088  case dmalloc in
20089  c|c_r) ;;
20090  *)
20091      LIBS="-ldmalloc $LIBS"
20092   ;;
20093  esac
20094
20095
20096
20097printf "%s\n" "#define HAVE_DMALLOC 1" >>confdefs.h
20098
20099    CPPFLAGS="$CPPFLAGS -DDMALLOC_FUNC_CHECK"
20100
20101else $as_nop
20102
20103    as_fn_error $? "Problem with enabling dmalloc. Please check config.log for details." "$LINENO" 5
20104
20105fi
20106
20107fi
20108
20109
20110php_enable_ipv6=yes
20111
20112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable IPv6 support" >&5
20113printf %s "checking whether to enable IPv6 support... " >&6; }
20114# Check whether --enable-ipv6 was given.
20115if test ${enable_ipv6+y}
20116then :
20117  enableval=$enable_ipv6; PHP_IPV6=$enableval
20118else $as_nop
20119
20120  PHP_IPV6=yes
20121
20122
20123fi
20124
20125
20126ext_output=$PHP_IPV6
20127{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
20128printf "%s\n" "$ext_output" >&6; }
20129
20130
20131
20132
20133if test "$PHP_IPV6" != "no" && test "$ac_cv_ipv6_support" = yes; then
20134
20135printf "%s\n" "#define HAVE_IPV6 1" >>confdefs.h
20136
20137fi
20138
20139
20140php_enable_dtrace=no
20141
20142{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable DTrace support" >&5
20143printf %s "checking whether to enable DTrace support... " >&6; }
20144# Check whether --enable-dtrace was given.
20145if test ${enable_dtrace+y}
20146then :
20147  enableval=$enable_dtrace; PHP_DTRACE=$enableval
20148else $as_nop
20149
20150  PHP_DTRACE=no
20151
20152
20153fi
20154
20155
20156ext_output=$PHP_DTRACE
20157{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
20158printf "%s\n" "$ext_output" >&6; }
20159
20160
20161
20162
20163if test "$PHP_DTRACE" = "yes"; then
20164         for ac_header in sys/sdt.h
20165do :
20166  ac_fn_c_check_header_compile "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default"
20167if test "x$ac_cv_header_sys_sdt_h" = xyes
20168then :
20169  printf "%s\n" "#define HAVE_SYS_SDT_H 1" >>confdefs.h
20170
20171
20172  case "" in
20173    "") ac_srcdir="$abs_srcdir/"; unset ac_bdir;;
20174    /*) ac_srcdir=`echo ""|cut -c 2-`"/"; ac_bdir=$ac_srcdir;;
20175    *) ac_srcdir="$abs_srcdir/Zend/zend_dtrace.d/"; ac_bdir="/";;
20176  esac
20177
20178  ac_provsrc=Zend/zend_dtrace.d
20179  old_IFS=$IFS
20180  IFS=.
20181  set $ac_provsrc
20182  ac_provobj=$1
20183  IFS=$old_IFS
20184
20185  ac_hdrobj=Zend/zend_dtrace_gen.h
20186
20187  case $host_alias in
20188  *freebsd*)
20189    PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_provsrc.lo"
20190    PHP_LDFLAGS="$PHP_LDFLAGS -lelf"
20191    ;;
20192  *solaris*)
20193    PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_provsrc.lo"
20194    ;;
20195  *linux*)
20196    PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_provsrc.lo"
20197    ;;
20198  esac
20199
20200  old_IFS=$IFS
20201  for ac_src in main/main.c Zend/zend_API.c \
20202      Zend/zend_execute.c Zend/zend_exceptions.c \
20203      Zend/zend_dtrace.c Zend/zend.c; do
20204    IFS=.
20205    set $ac_src
20206    ac_obj=$1
20207    IFS=$old_IFS
20208
20209    PHP_DTRACE_OBJS="$PHP_DTRACE_OBJS $ac_bdir$ac_obj.lo"
20210  done;
20211
20212  case $php_sapi_module in
20213  shared)
20214    for ac_lo in $PHP_DTRACE_OBJS; do
20215      dtrace_objs="$dtrace_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
20216    done;
20217    ;;
20218  *)
20219    dtrace_objs='$(PHP_DTRACE_OBJS:.lo=.o)'
20220    ;;
20221  esac
20222
20223  cat>>Makefile.objects<<EOF
20224
20225$abs_srcdir/$ac_provsrc:;
20226
20227$ac_bdir$ac_hdrobj: $abs_srcdir/$ac_provsrc
20228	CFLAGS="\$(CFLAGS_CLEAN)" dtrace -h -C -s $ac_srcdir$ac_provsrc -o \$@.bak && \$(SED) -e 's,PHP_,DTRACE_,g' \$@.bak > \$@
20229
20230\$(PHP_DTRACE_OBJS): $ac_bdir$ac_hdrobj
20231
20232EOF
20233
20234  case $host_alias in
20235  *solaris*|*linux*|*freebsd*)
20236    dtrace_prov_name="`echo $ac_provsrc | $SED -e 's#\(.*\)\/##'`.o"
20237    dtrace_lib_dir="`echo $ac_bdir$ac_provsrc | $SED -e 's#\(.*\)/[^/]*#\1#'`/.libs"
20238    dtrace_d_obj="`echo $ac_bdir$ac_provsrc | $SED -e 's#\(.*\)/\([^/]*\)#\1/.libs/\2#'`.o"
20239    dtrace_nolib_objs='$(PHP_DTRACE_OBJS:.lo=.o)'
20240    for ac_lo in $PHP_DTRACE_OBJS; do
20241      dtrace_lib_objs="$dtrace_lib_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
20242    done;
20243        cat>>Makefile.objects<<EOF
20244$ac_bdir$ac_provsrc.lo: \$(PHP_DTRACE_OBJS)
20245	echo "# Generated by Makefile for libtool" > \$@
20246	@test -d "$dtrace_lib_dir" || mkdir $dtrace_lib_dir
20247	if CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o $dtrace_d_obj -s $abs_srcdir/$ac_provsrc $dtrace_lib_objs 2> /dev/null && test -f "$dtrace_d_obj"; then \\
20248	  echo "pic_object='.libs/$dtrace_prov_name'" >> \$@ ;\\
20249	else \\
20250	  echo "pic_object='none'" >> \$@ ;\\
20251	fi
20252	if CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o $ac_bdir$ac_provsrc.o -s $abs_srcdir/$ac_provsrc $dtrace_nolib_objs 2> /dev/null && test -f "$ac_bdir$ac_provsrc.o"; then \\
20253	  echo "non_pic_object='$dtrace_prov_name'" >> \$@ ;\\
20254	else \\
20255	  echo "non_pic_object='none'" >> \$@ ;\\
20256	fi
20257
20258EOF
20259
20260    ;;
20261  *)
20262cat>>Makefile.objects<<EOF
20263$ac_bdir$ac_provsrc.o: \$(PHP_DTRACE_OBJS)
20264	CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o \$@ -s $abs_srcdir/$ac_provsrc $dtrace_objs
20265
20266EOF
20267    ;;
20268  esac
20269
20270
20271printf "%s\n" "#define HAVE_DTRACE 1" >>confdefs.h
20272
20273
20274  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_DTRACE_OBJS"
20275
20276
20277else $as_nop
20278
20279    as_fn_error $? "Cannot find sys/sdt.h which is required for DTrace support" "$LINENO" 5
20280
20281fi
20282
20283done
20284fi
20285
20286{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how big to make fd sets" >&5
20287printf %s "checking how big to make fd sets... " >&6; }
20288
20289php_enable_fd_setsize=no
20290
20291
20292# Check whether --enable-fd-setsize was given.
20293if test ${enable_fd_setsize+y}
20294then :
20295  enableval=$enable_fd_setsize; PHP_FD_SETSIZE=$enableval
20296else $as_nop
20297
20298  PHP_FD_SETSIZE=no
20299
20300
20301fi
20302
20303
20304ext_output=$PHP_FD_SETSIZE
20305
20306
20307
20308
20309
20310if test "$PHP_FD_SETSIZE" != "no"; then
20311  if test "0$PHP_FD_SETSIZE" -gt 0 2>/dev/null; then
20312    CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=$PHP_FD_SETSIZE"
20313    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using $PHP_FD_SETSIZE" >&5
20314printf "%s\n" "using $PHP_FD_SETSIZE" >&6; }
20315  else
20316    as_fn_error $? "Invalid value passed to --enable-fd-setsize!" "$LINENO" 5
20317  fi
20318else
20319  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using system default" >&5
20320printf "%s\n" "using system default" >&6; }
20321fi
20322
20323
20324php_enable_werror=no
20325
20326
20327# Check whether --enable-werror was given.
20328if test ${enable_werror+y}
20329then :
20330  enableval=$enable_werror; PHP_WERROR=$enableval
20331else $as_nop
20332
20333  PHP_WERROR=no
20334
20335
20336fi
20337
20338
20339ext_output=$PHP_WERROR
20340
20341
20342
20343
20344
20345php_enable_memory_sanitizer=no
20346
20347
20348# Check whether --enable-memory-sanitizer was given.
20349if test ${enable_memory_sanitizer+y}
20350then :
20351  enableval=$enable_memory_sanitizer; PHP_MEMORY_SANITIZER=$enableval
20352else $as_nop
20353
20354  PHP_MEMORY_SANITIZER=no
20355
20356
20357fi
20358
20359
20360ext_output=$PHP_MEMORY_SANITIZER
20361
20362
20363
20364
20365
20366php_enable_address_sanitizer=no
20367
20368
20369# Check whether --enable-address-sanitizer was given.
20370if test ${enable_address_sanitizer+y}
20371then :
20372  enableval=$enable_address_sanitizer; PHP_ADDRESS_SANITIZER=$enableval
20373else $as_nop
20374
20375  PHP_ADDRESS_SANITIZER=no
20376
20377
20378fi
20379
20380
20381ext_output=$PHP_ADDRESS_SANITIZER
20382
20383
20384
20385
20386
20387php_enable_undefined_sanitizer=no
20388
20389
20390# Check whether --enable-undefined-sanitizer was given.
20391if test ${enable_undefined_sanitizer+y}
20392then :
20393  enableval=$enable_undefined_sanitizer; PHP_UNDEFINED_SANITIZER=$enableval
20394else $as_nop
20395
20396  PHP_UNDEFINED_SANITIZER=no
20397
20398
20399fi
20400
20401
20402ext_output=$PHP_UNDEFINED_SANITIZER
20403
20404
20405
20406
20407
20408
20409
20410# Check whether --enable- was given.
20411if test ${enable_+y}
20412then :
20413  enableval=$enable_;
20414fi
20415
20416
20417
20418
20419  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
20420printf "%s\n" "" >&6; }
20421  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring extensions${T_ME}" >&5
20422printf "%s\n" "${T_MD}Configuring extensions${T_ME}" >&6; }
20423
20424
20425# Check whether --enable-all was given.
20426if test ${enable_all+y}
20427then :
20428  enableval=$enable_all; PHP_ENABLE_ALL=$enableval
20429fi
20430
20431
20432
20433
20434
20435ac_fn_c_check_header_compile "$LINENO" "io.h" "ac_cv_header_io_h" "$ac_includes_default"
20436if test "x$ac_cv_header_io_h" = xyes
20437then :
20438  printf "%s\n" "#define HAVE_IO_H 1" >>confdefs.h
20439
20440fi
20441
20442
20443ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
20444if test "x$ac_cv_func_strtoll" = xyes
20445then :
20446  printf "%s\n" "#define HAVE_STRTOLL 1" >>confdefs.h
20447
20448fi
20449ac_fn_c_check_func "$LINENO" "atoll" "ac_cv_func_atoll"
20450if test "x$ac_cv_func_atoll" = xyes
20451then :
20452  printf "%s\n" "#define HAVE_ATOLL 1" >>confdefs.h
20453
20454fi
20455
20456
20457PHP_DATE_CFLAGS="-Wno-implicit-fallthrough -I@ext_builddir@/lib -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -DHAVE_TIMELIB_CONFIG_H=1"
20458timelib_sources="lib/astro.c lib/dow.c lib/parse_date.c lib/parse_tz.c lib/parse_posix.c
20459                 lib/timelib.c lib/tm2unixtime.c lib/unixtime2tm.c lib/parse_iso_intervals.c lib/interval.c"
20460
20461
20462  ext_builddir=ext/date
20463  ext_srcdir=$abs_srcdir/ext/date
20464  ext_dir=ext/date
20465
20466  ac_extra=`echo "$PHP_DATE_CFLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
20467
20468  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
20469    PHP_DATE_SHARED=no
20470
20471
20472  case $ext_dir in
20473  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
20474  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
20475  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
20476  esac
20477
20478
20479
20480  b_c_pre=$php_c_pre
20481  b_cxx_pre=$php_cxx_pre
20482  b_c_meta=$php_c_meta
20483  b_cxx_meta=$php_cxx_meta
20484  b_c_post=$php_c_post
20485  b_cxx_post=$php_cxx_post
20486  b_lo=$php_lo
20487
20488
20489  old_IFS=$IFS
20490  for ac_src in php_date.c $timelib_sources; do
20491
20492      IFS=.
20493      set $ac_src
20494      ac_obj=$1
20495      IFS=$old_IFS
20496
20497      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
20498
20499      case $ac_src in
20500        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20501        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20502        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20503        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
20504      esac
20505
20506      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
20507
20508    cat >>Makefile.objects<<EOF
20509-include $ac_bdir$ac_obj.dep
20510$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
20511	$ac_comp
20512EOF
20513  done
20514
20515
20516    EXT_STATIC="$EXT_STATIC date;$ext_dir"
20517    if test "no" != "nocli"; then
20518      EXT_CLI_STATIC="$EXT_CLI_STATIC date;$ext_dir"
20519    fi
20520  else
20521    if test "no" = "shared" || test "no" = "yes"; then
20522      PHP_DATE_SHARED=yes
20523
20524  case $ext_dir in
20525  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
20526  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
20527  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
20528  esac
20529
20530
20531
20532  b_c_pre=$shared_c_pre
20533  b_cxx_pre=$shared_cxx_pre
20534  b_c_meta=$shared_c_meta
20535  b_cxx_meta=$shared_cxx_meta
20536  b_c_post=$shared_c_post
20537  b_cxx_post=$shared_cxx_post
20538  b_lo=$shared_lo
20539
20540
20541  old_IFS=$IFS
20542  for ac_src in php_date.c $timelib_sources; do
20543
20544      IFS=.
20545      set $ac_src
20546      ac_obj=$1
20547      IFS=$old_IFS
20548
20549      shared_objects_date="$shared_objects_date $ac_bdir$ac_obj.lo"
20550
20551      case $ac_src in
20552        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20553        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20554        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20555        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
20556      esac
20557
20558      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
20559
20560    cat >>Makefile.objects<<EOF
20561-include $ac_bdir$ac_obj.dep
20562$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
20563	$ac_comp
20564EOF
20565  done
20566
20567
20568  install_modules="install-modules"
20569  suffix=la
20570
20571  case $host_alias in
20572    *aix*)
20573      additional_flags="-Wl,-G"
20574      ;;
20575  esac
20576
20577  if test "x" = "xyes"; then
20578    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/date.$suffix"
20579  else
20580    PHP_MODULES="$PHP_MODULES \$(phplibdir)/date.$suffix"
20581  fi
20582
20583  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_date"
20584
20585  cat >>Makefile.objects<<EOF
20586\$(phplibdir)/date.$suffix: $ext_builddir/date.$suffix
20587	\$(LIBTOOL) --mode=install cp $ext_builddir/date.$suffix \$(phplibdir)
20588
20589$ext_builddir/date.$suffix: \$(shared_objects_date) \$(DATE_SHARED_DEPENDENCIES)
20590	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_date) \$(DATE_SHARED_LIBADD)
20591
20592EOF
20593
20594
20595printf "%s\n" "#define COMPILE_DL_DATE 1" >>confdefs.h
20596
20597    fi
20598  fi
20599
20600  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
20601    PHP_DATE_SHARED=no
20602    case "$PHP_SAPI" in
20603      cgi|embed|phpdbg)
20604
20605
20606  case $ext_dir in
20607  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
20608  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
20609  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
20610  esac
20611
20612
20613
20614  b_c_pre=$php_c_pre
20615  b_cxx_pre=$php_cxx_pre
20616  b_c_meta=$php_c_meta
20617  b_cxx_meta=$php_cxx_meta
20618  b_c_post=$php_c_post
20619  b_cxx_post=$php_cxx_post
20620  b_lo=$php_lo
20621
20622
20623  old_IFS=$IFS
20624  for ac_src in php_date.c $timelib_sources; do
20625
20626      IFS=.
20627      set $ac_src
20628      ac_obj=$1
20629      IFS=$old_IFS
20630
20631      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
20632
20633      case $ac_src in
20634        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20635        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20636        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20637        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
20638      esac
20639
20640      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
20641
20642    cat >>Makefile.objects<<EOF
20643-include $ac_bdir$ac_obj.dep
20644$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
20645	$ac_comp
20646EOF
20647  done
20648
20649
20650        EXT_STATIC="$EXT_STATIC date;$ext_dir"
20651        ;;
20652      *)
20653
20654
20655  case $ext_dir in
20656  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
20657  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
20658  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
20659  esac
20660
20661
20662
20663  b_c_pre=$php_c_pre
20664  b_cxx_pre=$php_cxx_pre
20665  b_c_meta=$php_c_meta
20666  b_cxx_meta=$php_cxx_meta
20667  b_c_post=$php_c_post
20668  b_cxx_post=$php_cxx_post
20669  b_lo=$php_lo
20670
20671
20672  old_IFS=$IFS
20673  for ac_src in php_date.c $timelib_sources; do
20674
20675      IFS=.
20676      set $ac_src
20677      ac_obj=$1
20678      IFS=$old_IFS
20679
20680      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
20681
20682      case $ac_src in
20683        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20684        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20685        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
20686        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
20687      esac
20688
20689      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
20690
20691    cat >>Makefile.objects<<EOF
20692-include $ac_bdir$ac_obj.dep
20693$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
20694	$ac_comp
20695EOF
20696  done
20697
20698
20699        ;;
20700    esac
20701    EXT_CLI_STATIC="$EXT_CLI_STATIC date;$ext_dir"
20702  fi
20703
20704
20705    BUILD_DIR="$BUILD_DIR $ext_builddir"
20706
20707
20708
20709  if test "$ext_builddir" = "."; then
20710    PHP_PECL_EXTENSION=date
20711
20712  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
20713
20714  fi
20715
20716
20717
20718
20719    $php_shtool mkdir -p $ext_builddir/lib
20720
20721
20722
20723  if test "$ext_builddir/lib" != "/usr/include"; then
20724
20725  if test -z "$ext_builddir/lib" || echo "$ext_builddir/lib" | grep '^/' >/dev/null ; then
20726    ai_p=$ext_builddir/lib
20727  else
20728
20729    ep_dir=`echo $ext_builddir/lib|$SED 's%/*[^/][^/]*/*$%%'`
20730
20731    ep_realdir=`(cd "$ep_dir" && pwd)`
20732    ai_p="$ep_realdir"/`basename "$ext_builddir/lib"`
20733  fi
20734
20735
20736
20737  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
20738
20739  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
20740  if test -n "$unique" && test "`eval $cmd`" = "" ; then
20741    eval "INCLUDEPATH$unique=set"
20742
20743      if test ""; then
20744        INCLUDES="-I$ai_p $INCLUDES"
20745      else
20746        INCLUDES="$INCLUDES -I$ai_p"
20747      fi
20748
20749  fi
20750
20751  fi
20752
20753
20754  if test "$ext_srcdir/lib" != "/usr/include"; then
20755
20756  if test -z "$ext_srcdir/lib" || echo "$ext_srcdir/lib" | grep '^/' >/dev/null ; then
20757    ai_p=$ext_srcdir/lib
20758  else
20759
20760    ep_dir=`echo $ext_srcdir/lib|$SED 's%/*[^/][^/]*/*$%%'`
20761
20762    ep_realdir=`(cd "$ep_dir" && pwd)`
20763    ai_p="$ep_realdir"/`basename "$ext_srcdir/lib"`
20764  fi
20765
20766
20767
20768  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
20769
20770  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
20771  if test -n "$unique" && test "`eval $cmd`" = "" ; then
20772    eval "INCLUDEPATH$unique=set"
20773
20774      if test ""; then
20775        INCLUDES="-I$ai_p $INCLUDES"
20776      else
20777        INCLUDES="$INCLUDES -I$ai_p"
20778      fi
20779
20780  fi
20781
20782  fi
20783
20784
20785
20786
20787    header_path=ext/date
20788    for header_file in php_date.h lib/timelib.h lib/timelib_config.h; do
20789      hp_hf="$header_path/$header_file"
20790
20791
20792  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
20793
20794  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
20795  if test -n "$unique" && test "`eval $cmd`" = "" ; then
20796    eval "INSTALLHEADERS$unique=set"
20797
20798        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
20799
20800  fi
20801
20802    done
20803
20804
20805
20806printf "%s\n" "#define HAVE_TIMELIB_CONFIG_H 1" >>confdefs.h
20807
20808
20809cat > $ext_builddir/lib/timelib_config.h <<EOF
20810#ifdef PHP_WIN32
20811# include "config.w32.h"
20812#else
20813# include <php_config.h>
20814#endif
20815#include <php_stdint.h>
20816
20817#include "zend.h"
20818
20819#define timelib_malloc  emalloc
20820#define timelib_realloc erealloc
20821#define timelib_calloc  ecalloc
20822#define timelib_strdup  estrdup
20823#define timelib_strndup estrndup
20824#define timelib_free    efree
20825EOF
20826
20827
20828
20829
20830
20831php_with_libxml=yes
20832
20833{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with LIBXML support" >&5
20834printf %s "checking whether to build with LIBXML support... " >&6; }
20835
20836# Check whether --with-libxml was given.
20837if test ${with_libxml+y}
20838then :
20839  withval=$with_libxml; PHP_LIBXML=$withval
20840else $as_nop
20841
20842  PHP_LIBXML=yes
20843  test "$PHP_ENABLE_ALL" && PHP_LIBXML=$PHP_ENABLE_ALL
20844
20845fi
20846
20847
20848
20849ext_output="yes, shared"
20850ext_shared=yes
20851case $PHP_LIBXML in
20852shared,*)
20853  PHP_LIBXML=`echo "$PHP_LIBXML"|$SED 's/^shared,//'`
20854  ;;
20855shared)
20856  PHP_LIBXML=yes
20857  ;;
20858no)
20859  ext_output=no
20860  ext_shared=no
20861  ;;
20862*)
20863  ext_output=yes
20864  ext_shared=no
20865  ;;
20866esac
20867
20868
20869
20870{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
20871printf "%s\n" "$ext_output" >&6; }
20872
20873
20874
20875
20876if test "$PHP_LIBXML" != "no"; then
20877
20878    ext_shared=no
20879
20880
20881
20882pkg_failed=no
20883{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
20884printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
20885
20886if test -n "$LIBXML_CFLAGS"; then
20887    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
20888 elif test -n "$PKG_CONFIG"; then
20889    if test -n "$PKG_CONFIG" && \
20890    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
20891  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
20892  ac_status=$?
20893  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
20894  test $ac_status = 0; }; then
20895  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
20896		      test "x$?" != "x0" && pkg_failed=yes
20897else
20898  pkg_failed=yes
20899fi
20900 else
20901    pkg_failed=untried
20902fi
20903if test -n "$LIBXML_LIBS"; then
20904    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
20905 elif test -n "$PKG_CONFIG"; then
20906    if test -n "$PKG_CONFIG" && \
20907    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
20908  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
20909  ac_status=$?
20910  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
20911  test $ac_status = 0; }; then
20912  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
20913		      test "x$?" != "x0" && pkg_failed=yes
20914else
20915  pkg_failed=yes
20916fi
20917 else
20918    pkg_failed=untried
20919fi
20920
20921
20922
20923if test $pkg_failed = yes; then
20924        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20925printf "%s\n" "no" >&6; }
20926
20927if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
20928        _pkg_short_errors_supported=yes
20929else
20930        _pkg_short_errors_supported=no
20931fi
20932        if test $_pkg_short_errors_supported = yes; then
20933	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
20934        else
20935	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
20936        fi
20937	# Put the nasty error message in config.log where it belongs
20938	echo "$LIBXML_PKG_ERRORS" >&5
20939
20940	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
20941
20942$LIBXML_PKG_ERRORS
20943
20944Consider adjusting the PKG_CONFIG_PATH environment variable if you
20945installed software in a non-standard prefix.
20946
20947Alternatively, you may set the environment variables LIBXML_CFLAGS
20948and LIBXML_LIBS to avoid the need to call pkg-config.
20949See the pkg-config man page for more details." "$LINENO" 5
20950elif test $pkg_failed = untried; then
20951        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
20952printf "%s\n" "no" >&6; }
20953	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20954printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
20955as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
20956is in your PATH or set the PKG_CONFIG environment variable to the full
20957path to pkg-config.
20958
20959Alternatively, you may set the environment variables LIBXML_CFLAGS
20960and LIBXML_LIBS to avoid the need to call pkg-config.
20961See the pkg-config man page for more details.
20962
20963To get pkg-config, see <http://pkg-config.freedesktop.org/>.
20964See \`config.log' for more details" "$LINENO" 5; }
20965else
20966	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
20967	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
20968        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20969printf "%s\n" "yes" >&6; }
20970
20971fi
20972
20973
20974  for ac_i in $LIBXML_CFLAGS; do
20975    case $ac_i in
20976    -I*)
20977      ac_ii=`echo $ac_i|cut -c 3-`
20978
20979  if test "$ac_ii" != "/usr/include"; then
20980
20981  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
20982    ai_p=$ac_ii
20983  else
20984
20985    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
20986
20987    ep_realdir=`(cd "$ep_dir" && pwd)`
20988    ai_p="$ep_realdir"/`basename "$ac_ii"`
20989  fi
20990
20991
20992
20993  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
20994
20995  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
20996  if test -n "$unique" && test "`eval $cmd`" = "" ; then
20997    eval "INCLUDEPATH$unique=set"
20998
20999      if test ""; then
21000        INCLUDES="-I$ai_p $INCLUDES"
21001      else
21002        INCLUDES="$INCLUDES -I$ai_p"
21003      fi
21004
21005  fi
21006
21007  fi
21008
21009    ;;
21010    esac
21011  done
21012
21013
21014  for ac_i in $LIBXML_LIBS; do
21015    case $ac_i in
21016    -pthread)
21017      if test "$ext_shared" = "yes"; then
21018        LIBXML_SHARED_LIBADD="$LIBXML_SHARED_LIBADD -pthread"
21019      else
21020
21021
21022  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
21023
21024  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
21025  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21026    eval "EXTRA_LDFLAGS$unique=set"
21027    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
21028  fi
21029
21030
21031
21032  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
21033
21034  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
21035  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21036    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
21037    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
21038  fi
21039
21040      fi
21041    ;;
21042    -l*)
21043      ac_ii=`echo $ac_i|cut -c 3-`
21044
21045
21046  case $ac_ii in
21047  c|c_r) ;;
21048  *)
21049    if test "$ext_shared" = "yes"; then
21050        LIBXML_SHARED_LIBADD="$LIBXML_SHARED_LIBADD -l$ac_ii"
21051    else
21052
21053
21054  case $ac_ii in
21055  c|c_r) ;;
21056  *)
21057      LIBS="$LIBS -l$ac_ii"
21058   ;;
21059  esac
21060
21061
21062    fi
21063   ;;
21064  esac
21065
21066
21067    ;;
21068    -L*)
21069      ac_ii=`echo $ac_i|cut -c 3-`
21070
21071  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
21072
21073  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
21074    ai_p=$ac_ii
21075  else
21076
21077    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
21078
21079    ep_realdir=`(cd "$ep_dir" && pwd)`
21080    ai_p="$ep_realdir"/`basename "$ac_ii"`
21081  fi
21082
21083
21084      if test "$ext_shared" = "yes"; then
21085        LIBXML_SHARED_LIBADD="-L$ai_p $LIBXML_SHARED_LIBADD"
21086        test -n "$ld_runpath_switch" && LIBXML_SHARED_LIBADD="$ld_runpath_switch$ai_p $LIBXML_SHARED_LIBADD"
21087      else
21088
21089
21090
21091  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
21092
21093  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
21094  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21095    eval "LIBPATH$unique=set"
21096
21097    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
21098    LDFLAGS="$LDFLAGS -L$ai_p"
21099    PHP_RPATHS="$PHP_RPATHS $ai_p"
21100
21101  fi
21102
21103
21104      fi
21105
21106  fi
21107
21108    ;;
21109    esac
21110  done
21111
21112
21113
21114printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
21115
21116
21117
21118
21119printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
21120
21121
21122  ext_builddir=ext/libxml
21123  ext_srcdir=$abs_srcdir/ext/libxml
21124  ext_dir=ext/libxml
21125
21126  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
21127
21128  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
21129    PHP_LIBXML_SHARED=no
21130
21131
21132  case $ext_dir in
21133  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21134  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21135  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21136  esac
21137
21138
21139
21140  b_c_pre=$php_c_pre
21141  b_cxx_pre=$php_cxx_pre
21142  b_c_meta=$php_c_meta
21143  b_cxx_meta=$php_cxx_meta
21144  b_c_post=$php_c_post
21145  b_cxx_post=$php_cxx_post
21146  b_lo=$php_lo
21147
21148
21149  old_IFS=$IFS
21150  for ac_src in libxml.c; do
21151
21152      IFS=.
21153      set $ac_src
21154      ac_obj=$1
21155      IFS=$old_IFS
21156
21157      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21158
21159      case $ac_src in
21160        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21161        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21162        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21163        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21164      esac
21165
21166      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21167
21168    cat >>Makefile.objects<<EOF
21169-include $ac_bdir$ac_obj.dep
21170$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21171	$ac_comp
21172EOF
21173  done
21174
21175
21176    EXT_STATIC="$EXT_STATIC libxml;$ext_dir"
21177    if test "$ext_shared" != "nocli"; then
21178      EXT_CLI_STATIC="$EXT_CLI_STATIC libxml;$ext_dir"
21179    fi
21180  else
21181    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
21182      PHP_LIBXML_SHARED=yes
21183
21184  case $ext_dir in
21185  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21186  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21187  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21188  esac
21189
21190
21191
21192  b_c_pre=$shared_c_pre
21193  b_cxx_pre=$shared_cxx_pre
21194  b_c_meta=$shared_c_meta
21195  b_cxx_meta=$shared_cxx_meta
21196  b_c_post=$shared_c_post
21197  b_cxx_post=$shared_cxx_post
21198  b_lo=$shared_lo
21199
21200
21201  old_IFS=$IFS
21202  for ac_src in libxml.c; do
21203
21204      IFS=.
21205      set $ac_src
21206      ac_obj=$1
21207      IFS=$old_IFS
21208
21209      shared_objects_libxml="$shared_objects_libxml $ac_bdir$ac_obj.lo"
21210
21211      case $ac_src in
21212        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21213        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21214        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21215        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21216      esac
21217
21218      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21219
21220    cat >>Makefile.objects<<EOF
21221-include $ac_bdir$ac_obj.dep
21222$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21223	$ac_comp
21224EOF
21225  done
21226
21227
21228  install_modules="install-modules"
21229  suffix=la
21230
21231  case $host_alias in
21232    *aix*)
21233      additional_flags="-Wl,-G"
21234      ;;
21235  esac
21236
21237  if test "x" = "xyes"; then
21238    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/libxml.$suffix"
21239  else
21240    PHP_MODULES="$PHP_MODULES \$(phplibdir)/libxml.$suffix"
21241  fi
21242
21243  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_libxml"
21244
21245  cat >>Makefile.objects<<EOF
21246\$(phplibdir)/libxml.$suffix: $ext_builddir/libxml.$suffix
21247	\$(LIBTOOL) --mode=install cp $ext_builddir/libxml.$suffix \$(phplibdir)
21248
21249$ext_builddir/libxml.$suffix: \$(shared_objects_libxml) \$(LIBXML_SHARED_DEPENDENCIES)
21250	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_libxml) \$(LIBXML_SHARED_LIBADD)
21251
21252EOF
21253
21254
21255printf "%s\n" "#define COMPILE_DL_LIBXML 1" >>confdefs.h
21256
21257    fi
21258  fi
21259
21260  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
21261    PHP_LIBXML_SHARED=no
21262    case "$PHP_SAPI" in
21263      cgi|embed|phpdbg)
21264
21265
21266  case $ext_dir in
21267  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21268  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21269  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21270  esac
21271
21272
21273
21274  b_c_pre=$php_c_pre
21275  b_cxx_pre=$php_cxx_pre
21276  b_c_meta=$php_c_meta
21277  b_cxx_meta=$php_cxx_meta
21278  b_c_post=$php_c_post
21279  b_cxx_post=$php_cxx_post
21280  b_lo=$php_lo
21281
21282
21283  old_IFS=$IFS
21284  for ac_src in libxml.c; do
21285
21286      IFS=.
21287      set $ac_src
21288      ac_obj=$1
21289      IFS=$old_IFS
21290
21291      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21292
21293      case $ac_src in
21294        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21295        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21296        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21297        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21298      esac
21299
21300      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21301
21302    cat >>Makefile.objects<<EOF
21303-include $ac_bdir$ac_obj.dep
21304$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21305	$ac_comp
21306EOF
21307  done
21308
21309
21310        EXT_STATIC="$EXT_STATIC libxml;$ext_dir"
21311        ;;
21312      *)
21313
21314
21315  case $ext_dir in
21316  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21317  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21318  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21319  esac
21320
21321
21322
21323  b_c_pre=$php_c_pre
21324  b_cxx_pre=$php_cxx_pre
21325  b_c_meta=$php_c_meta
21326  b_cxx_meta=$php_cxx_meta
21327  b_c_post=$php_c_post
21328  b_cxx_post=$php_cxx_post
21329  b_lo=$php_lo
21330
21331
21332  old_IFS=$IFS
21333  for ac_src in libxml.c; do
21334
21335      IFS=.
21336      set $ac_src
21337      ac_obj=$1
21338      IFS=$old_IFS
21339
21340      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21341
21342      case $ac_src in
21343        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21344        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21345        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21346        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21347      esac
21348
21349      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21350
21351    cat >>Makefile.objects<<EOF
21352-include $ac_bdir$ac_obj.dep
21353$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21354	$ac_comp
21355EOF
21356  done
21357
21358
21359        ;;
21360    esac
21361    EXT_CLI_STATIC="$EXT_CLI_STATIC libxml;$ext_dir"
21362  fi
21363
21364
21365    BUILD_DIR="$BUILD_DIR $ext_builddir"
21366
21367
21368
21369  if test "$ext_builddir" = "."; then
21370    PHP_PECL_EXTENSION=libxml
21371
21372  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
21373
21374  fi
21375
21376
21377
21378    for header_file in ext/libxml/php_libxml.h; do
21379
21380
21381  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
21382
21383  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
21384  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21385    eval "INSTALLHEADERS$unique=set"
21386
21387        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
21388
21389  fi
21390
21391    done
21392
21393
21394
21395
21396fi
21397
21398
21399
21400
21401
21402php_with_openssl=no
21403
21404{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL support" >&5
21405printf %s "checking for OpenSSL support... " >&6; }
21406
21407# Check whether --with-openssl was given.
21408if test ${with_openssl+y}
21409then :
21410  withval=$with_openssl; PHP_OPENSSL=$withval
21411else $as_nop
21412
21413  PHP_OPENSSL=no
21414  test "$PHP_ENABLE_ALL" && PHP_OPENSSL=$PHP_ENABLE_ALL
21415
21416fi
21417
21418
21419
21420ext_output="yes, shared"
21421ext_shared=yes
21422case $PHP_OPENSSL in
21423shared,*)
21424  PHP_OPENSSL=`echo "$PHP_OPENSSL"|$SED 's/^shared,//'`
21425  ;;
21426shared)
21427  PHP_OPENSSL=yes
21428  ;;
21429no)
21430  ext_output=no
21431  ext_shared=no
21432  ;;
21433*)
21434  ext_output=yes
21435  ext_shared=no
21436  ;;
21437esac
21438
21439
21440
21441{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
21442printf "%s\n" "$ext_output" >&6; }
21443
21444
21445
21446
21447
21448php_with_kerberos=no
21449
21450{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Kerberos support" >&5
21451printf %s "checking for Kerberos support... " >&6; }
21452
21453# Check whether --with-kerberos was given.
21454if test ${with_kerberos+y}
21455then :
21456  withval=$with_kerberos; PHP_KERBEROS=$withval
21457else $as_nop
21458
21459  PHP_KERBEROS=no
21460
21461
21462fi
21463
21464
21465ext_output=$PHP_KERBEROS
21466{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
21467printf "%s\n" "$ext_output" >&6; }
21468
21469
21470
21471
21472
21473php_with_system_ciphers=no
21474
21475{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use system default cipher list instead of hardcoded value" >&5
21476printf %s "checking whether to use system default cipher list instead of hardcoded value... " >&6; }
21477
21478# Check whether --with-system-ciphers was given.
21479if test ${with_system_ciphers+y}
21480then :
21481  withval=$with_system_ciphers; PHP_SYSTEM_CIPHERS=$withval
21482else $as_nop
21483
21484  PHP_SYSTEM_CIPHERS=no
21485
21486
21487fi
21488
21489
21490ext_output=$PHP_SYSTEM_CIPHERS
21491{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
21492printf "%s\n" "$ext_output" >&6; }
21493
21494
21495
21496
21497if test "$PHP_OPENSSL" != "no"; then
21498
21499  ext_builddir=ext/openssl
21500  ext_srcdir=$abs_srcdir/ext/openssl
21501  ext_dir=ext/openssl
21502
21503  ac_extra=
21504
21505  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
21506    PHP_OPENSSL_SHARED=no
21507
21508
21509  case $ext_dir in
21510  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21511  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21512  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21513  esac
21514
21515
21516
21517  b_c_pre=$php_c_pre
21518  b_cxx_pre=$php_cxx_pre
21519  b_c_meta=$php_c_meta
21520  b_cxx_meta=$php_cxx_meta
21521  b_c_post=$php_c_post
21522  b_cxx_post=$php_cxx_post
21523  b_lo=$php_lo
21524
21525
21526  old_IFS=$IFS
21527  for ac_src in openssl.c xp_ssl.c; do
21528
21529      IFS=.
21530      set $ac_src
21531      ac_obj=$1
21532      IFS=$old_IFS
21533
21534      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21535
21536      case $ac_src in
21537        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21538        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21539        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21540        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21541      esac
21542
21543      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21544
21545    cat >>Makefile.objects<<EOF
21546-include $ac_bdir$ac_obj.dep
21547$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21548	$ac_comp
21549EOF
21550  done
21551
21552
21553    EXT_STATIC="$EXT_STATIC openssl;$ext_dir"
21554    if test "$ext_shared" != "nocli"; then
21555      EXT_CLI_STATIC="$EXT_CLI_STATIC openssl;$ext_dir"
21556    fi
21557  else
21558    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
21559      PHP_OPENSSL_SHARED=yes
21560
21561  case $ext_dir in
21562  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21563  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21564  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21565  esac
21566
21567
21568
21569  b_c_pre=$shared_c_pre
21570  b_cxx_pre=$shared_cxx_pre
21571  b_c_meta=$shared_c_meta
21572  b_cxx_meta=$shared_cxx_meta
21573  b_c_post=$shared_c_post
21574  b_cxx_post=$shared_cxx_post
21575  b_lo=$shared_lo
21576
21577
21578  old_IFS=$IFS
21579  for ac_src in openssl.c xp_ssl.c; do
21580
21581      IFS=.
21582      set $ac_src
21583      ac_obj=$1
21584      IFS=$old_IFS
21585
21586      shared_objects_openssl="$shared_objects_openssl $ac_bdir$ac_obj.lo"
21587
21588      case $ac_src in
21589        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21590        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21591        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21592        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21593      esac
21594
21595      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21596
21597    cat >>Makefile.objects<<EOF
21598-include $ac_bdir$ac_obj.dep
21599$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21600	$ac_comp
21601EOF
21602  done
21603
21604
21605  install_modules="install-modules"
21606  suffix=la
21607
21608  case $host_alias in
21609    *aix*)
21610      additional_flags="-Wl,-G"
21611      ;;
21612  esac
21613
21614  if test "x" = "xyes"; then
21615    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/openssl.$suffix"
21616  else
21617    PHP_MODULES="$PHP_MODULES \$(phplibdir)/openssl.$suffix"
21618  fi
21619
21620  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_openssl"
21621
21622  cat >>Makefile.objects<<EOF
21623\$(phplibdir)/openssl.$suffix: $ext_builddir/openssl.$suffix
21624	\$(LIBTOOL) --mode=install cp $ext_builddir/openssl.$suffix \$(phplibdir)
21625
21626$ext_builddir/openssl.$suffix: \$(shared_objects_openssl) \$(OPENSSL_SHARED_DEPENDENCIES)
21627	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_openssl) \$(OPENSSL_SHARED_LIBADD)
21628
21629EOF
21630
21631
21632printf "%s\n" "#define COMPILE_DL_OPENSSL 1" >>confdefs.h
21633
21634    fi
21635  fi
21636
21637  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
21638    PHP_OPENSSL_SHARED=no
21639    case "$PHP_SAPI" in
21640      cgi|embed|phpdbg)
21641
21642
21643  case $ext_dir in
21644  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21645  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21646  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21647  esac
21648
21649
21650
21651  b_c_pre=$php_c_pre
21652  b_cxx_pre=$php_cxx_pre
21653  b_c_meta=$php_c_meta
21654  b_cxx_meta=$php_cxx_meta
21655  b_c_post=$php_c_post
21656  b_cxx_post=$php_cxx_post
21657  b_lo=$php_lo
21658
21659
21660  old_IFS=$IFS
21661  for ac_src in openssl.c xp_ssl.c; do
21662
21663      IFS=.
21664      set $ac_src
21665      ac_obj=$1
21666      IFS=$old_IFS
21667
21668      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21669
21670      case $ac_src in
21671        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21672        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21673        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21674        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21675      esac
21676
21677      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21678
21679    cat >>Makefile.objects<<EOF
21680-include $ac_bdir$ac_obj.dep
21681$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21682	$ac_comp
21683EOF
21684  done
21685
21686
21687        EXT_STATIC="$EXT_STATIC openssl;$ext_dir"
21688        ;;
21689      *)
21690
21691
21692  case $ext_dir in
21693  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
21694  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
21695  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
21696  esac
21697
21698
21699
21700  b_c_pre=$php_c_pre
21701  b_cxx_pre=$php_cxx_pre
21702  b_c_meta=$php_c_meta
21703  b_cxx_meta=$php_cxx_meta
21704  b_c_post=$php_c_post
21705  b_cxx_post=$php_cxx_post
21706  b_lo=$php_lo
21707
21708
21709  old_IFS=$IFS
21710  for ac_src in openssl.c xp_ssl.c; do
21711
21712      IFS=.
21713      set $ac_src
21714      ac_obj=$1
21715      IFS=$old_IFS
21716
21717      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
21718
21719      case $ac_src in
21720        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21721        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21722        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
21723        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
21724      esac
21725
21726      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
21727
21728    cat >>Makefile.objects<<EOF
21729-include $ac_bdir$ac_obj.dep
21730$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
21731	$ac_comp
21732EOF
21733  done
21734
21735
21736        ;;
21737    esac
21738    EXT_CLI_STATIC="$EXT_CLI_STATIC openssl;$ext_dir"
21739  fi
21740
21741
21742    BUILD_DIR="$BUILD_DIR $ext_builddir"
21743
21744
21745
21746  if test "$ext_builddir" = "."; then
21747    PHP_PECL_EXTENSION=openssl
21748
21749  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
21750
21751  fi
21752
21753
21754  PHP_VAR_SUBST="$PHP_VAR_SUBST OPENSSL_SHARED_LIBADD"
21755
21756
21757  if test "$PHP_KERBEROS" != "no"; then
21758
21759pkg_failed=no
21760{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for krb5-gssapi krb5" >&5
21761printf %s "checking for krb5-gssapi krb5... " >&6; }
21762
21763if test -n "$KERBEROS_CFLAGS"; then
21764    pkg_cv_KERBEROS_CFLAGS="$KERBEROS_CFLAGS"
21765 elif test -n "$PKG_CONFIG"; then
21766    if test -n "$PKG_CONFIG" && \
21767    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"krb5-gssapi krb5\""; } >&5
21768  ($PKG_CONFIG --exists --print-errors "krb5-gssapi krb5") 2>&5
21769  ac_status=$?
21770  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21771  test $ac_status = 0; }; then
21772  pkg_cv_KERBEROS_CFLAGS=`$PKG_CONFIG --cflags "krb5-gssapi krb5" 2>/dev/null`
21773		      test "x$?" != "x0" && pkg_failed=yes
21774else
21775  pkg_failed=yes
21776fi
21777 else
21778    pkg_failed=untried
21779fi
21780if test -n "$KERBEROS_LIBS"; then
21781    pkg_cv_KERBEROS_LIBS="$KERBEROS_LIBS"
21782 elif test -n "$PKG_CONFIG"; then
21783    if test -n "$PKG_CONFIG" && \
21784    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"krb5-gssapi krb5\""; } >&5
21785  ($PKG_CONFIG --exists --print-errors "krb5-gssapi krb5") 2>&5
21786  ac_status=$?
21787  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21788  test $ac_status = 0; }; then
21789  pkg_cv_KERBEROS_LIBS=`$PKG_CONFIG --libs "krb5-gssapi krb5" 2>/dev/null`
21790		      test "x$?" != "x0" && pkg_failed=yes
21791else
21792  pkg_failed=yes
21793fi
21794 else
21795    pkg_failed=untried
21796fi
21797
21798
21799
21800if test $pkg_failed = yes; then
21801        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
21802printf "%s\n" "no" >&6; }
21803
21804if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
21805        _pkg_short_errors_supported=yes
21806else
21807        _pkg_short_errors_supported=no
21808fi
21809        if test $_pkg_short_errors_supported = yes; then
21810	        KERBEROS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "krb5-gssapi krb5" 2>&1`
21811        else
21812	        KERBEROS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "krb5-gssapi krb5" 2>&1`
21813        fi
21814	# Put the nasty error message in config.log where it belongs
21815	echo "$KERBEROS_PKG_ERRORS" >&5
21816
21817	as_fn_error $? "Package requirements (krb5-gssapi krb5) were not met:
21818
21819$KERBEROS_PKG_ERRORS
21820
21821Consider adjusting the PKG_CONFIG_PATH environment variable if you
21822installed software in a non-standard prefix.
21823
21824Alternatively, you may set the environment variables KERBEROS_CFLAGS
21825and KERBEROS_LIBS to avoid the need to call pkg-config.
21826See the pkg-config man page for more details." "$LINENO" 5
21827elif test $pkg_failed = untried; then
21828        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
21829printf "%s\n" "no" >&6; }
21830	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
21831printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
21832as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
21833is in your PATH or set the PKG_CONFIG environment variable to the full
21834path to pkg-config.
21835
21836Alternatively, you may set the environment variables KERBEROS_CFLAGS
21837and KERBEROS_LIBS to avoid the need to call pkg-config.
21838See the pkg-config man page for more details.
21839
21840To get pkg-config, see <http://pkg-config.freedesktop.org/>.
21841See \`config.log' for more details" "$LINENO" 5; }
21842else
21843	KERBEROS_CFLAGS=$pkg_cv_KERBEROS_CFLAGS
21844	KERBEROS_LIBS=$pkg_cv_KERBEROS_LIBS
21845        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21846printf "%s\n" "yes" >&6; }
21847
21848fi
21849
21850
21851  for ac_i in $KERBEROS_CFLAGS; do
21852    case $ac_i in
21853    -I*)
21854      ac_ii=`echo $ac_i|cut -c 3-`
21855
21856  if test "$ac_ii" != "/usr/include"; then
21857
21858  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
21859    ai_p=$ac_ii
21860  else
21861
21862    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
21863
21864    ep_realdir=`(cd "$ep_dir" && pwd)`
21865    ai_p="$ep_realdir"/`basename "$ac_ii"`
21866  fi
21867
21868
21869
21870  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
21871
21872  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
21873  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21874    eval "INCLUDEPATH$unique=set"
21875
21876      if test ""; then
21877        INCLUDES="-I$ai_p $INCLUDES"
21878      else
21879        INCLUDES="$INCLUDES -I$ai_p"
21880      fi
21881
21882  fi
21883
21884  fi
21885
21886    ;;
21887    esac
21888  done
21889
21890
21891  for ac_i in $KERBEROS_LIBS; do
21892    case $ac_i in
21893    -pthread)
21894      if test "$ext_shared" = "yes"; then
21895        OPENSSL_SHARED_LIBADD="$OPENSSL_SHARED_LIBADD -pthread"
21896      else
21897
21898
21899  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
21900
21901  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
21902  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21903    eval "EXTRA_LDFLAGS$unique=set"
21904    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
21905  fi
21906
21907
21908
21909  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
21910
21911  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
21912  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21913    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
21914    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
21915  fi
21916
21917      fi
21918    ;;
21919    -l*)
21920      ac_ii=`echo $ac_i|cut -c 3-`
21921
21922
21923  case $ac_ii in
21924  c|c_r) ;;
21925  *)
21926    if test "$ext_shared" = "yes"; then
21927        OPENSSL_SHARED_LIBADD="$OPENSSL_SHARED_LIBADD -l$ac_ii"
21928    else
21929
21930
21931  case $ac_ii in
21932  c|c_r) ;;
21933  *)
21934      LIBS="$LIBS -l$ac_ii"
21935   ;;
21936  esac
21937
21938
21939    fi
21940   ;;
21941  esac
21942
21943
21944    ;;
21945    -L*)
21946      ac_ii=`echo $ac_i|cut -c 3-`
21947
21948  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
21949
21950  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
21951    ai_p=$ac_ii
21952  else
21953
21954    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
21955
21956    ep_realdir=`(cd "$ep_dir" && pwd)`
21957    ai_p="$ep_realdir"/`basename "$ac_ii"`
21958  fi
21959
21960
21961      if test "$ext_shared" = "yes"; then
21962        OPENSSL_SHARED_LIBADD="-L$ai_p $OPENSSL_SHARED_LIBADD"
21963        test -n "$ld_runpath_switch" && OPENSSL_SHARED_LIBADD="$ld_runpath_switch$ai_p $OPENSSL_SHARED_LIBADD"
21964      else
21965
21966
21967
21968  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
21969
21970  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
21971  if test -n "$unique" && test "`eval $cmd`" = "" ; then
21972    eval "LIBPATH$unique=set"
21973
21974    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
21975    LDFLAGS="$LDFLAGS -L$ai_p"
21976    PHP_RPATHS="$PHP_RPATHS $ai_p"
21977
21978  fi
21979
21980
21981      fi
21982
21983  fi
21984
21985    ;;
21986    esac
21987  done
21988
21989  fi
21990
21991
21992  found_openssl=no
21993
21994
21995pkg_failed=no
21996{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl >= 1.0.2" >&5
21997printf %s "checking for openssl >= 1.0.2... " >&6; }
21998
21999if test -n "$OPENSSL_CFLAGS"; then
22000    pkg_cv_OPENSSL_CFLAGS="$OPENSSL_CFLAGS"
22001 elif test -n "$PKG_CONFIG"; then
22002    if test -n "$PKG_CONFIG" && \
22003    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
22004  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
22005  ac_status=$?
22006  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22007  test $ac_status = 0; }; then
22008  pkg_cv_OPENSSL_CFLAGS=`$PKG_CONFIG --cflags "openssl >= 1.0.2" 2>/dev/null`
22009		      test "x$?" != "x0" && pkg_failed=yes
22010else
22011  pkg_failed=yes
22012fi
22013 else
22014    pkg_failed=untried
22015fi
22016if test -n "$OPENSSL_LIBS"; then
22017    pkg_cv_OPENSSL_LIBS="$OPENSSL_LIBS"
22018 elif test -n "$PKG_CONFIG"; then
22019    if test -n "$PKG_CONFIG" && \
22020    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
22021  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
22022  ac_status=$?
22023  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22024  test $ac_status = 0; }; then
22025  pkg_cv_OPENSSL_LIBS=`$PKG_CONFIG --libs "openssl >= 1.0.2" 2>/dev/null`
22026		      test "x$?" != "x0" && pkg_failed=yes
22027else
22028  pkg_failed=yes
22029fi
22030 else
22031    pkg_failed=untried
22032fi
22033
22034
22035
22036if test $pkg_failed = yes; then
22037        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
22038printf "%s\n" "no" >&6; }
22039
22040if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
22041        _pkg_short_errors_supported=yes
22042else
22043        _pkg_short_errors_supported=no
22044fi
22045        if test $_pkg_short_errors_supported = yes; then
22046	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
22047        else
22048	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
22049        fi
22050	# Put the nasty error message in config.log where it belongs
22051	echo "$OPENSSL_PKG_ERRORS" >&5
22052
22053	as_fn_error $? "Package requirements (openssl >= 1.0.2) were not met:
22054
22055$OPENSSL_PKG_ERRORS
22056
22057Consider adjusting the PKG_CONFIG_PATH environment variable if you
22058installed software in a non-standard prefix.
22059
22060Alternatively, you may set the environment variables OPENSSL_CFLAGS
22061and OPENSSL_LIBS to avoid the need to call pkg-config.
22062See the pkg-config man page for more details." "$LINENO" 5
22063elif test $pkg_failed = untried; then
22064        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
22065printf "%s\n" "no" >&6; }
22066	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22067printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
22068as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
22069is in your PATH or set the PKG_CONFIG environment variable to the full
22070path to pkg-config.
22071
22072Alternatively, you may set the environment variables OPENSSL_CFLAGS
22073and OPENSSL_LIBS to avoid the need to call pkg-config.
22074See the pkg-config man page for more details.
22075
22076To get pkg-config, see <http://pkg-config.freedesktop.org/>.
22077See \`config.log' for more details" "$LINENO" 5; }
22078else
22079	OPENSSL_CFLAGS=$pkg_cv_OPENSSL_CFLAGS
22080	OPENSSL_LIBS=$pkg_cv_OPENSSL_LIBS
22081        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22082printf "%s\n" "yes" >&6; }
22083	found_openssl=yes
22084fi
22085
22086  if test "$found_openssl" = "yes"; then
22087
22088  for ac_i in $OPENSSL_LIBS; do
22089    case $ac_i in
22090    -pthread)
22091      if test "$ext_shared" = "yes"; then
22092        OPENSSL_SHARED_LIBADD="$OPENSSL_SHARED_LIBADD -pthread"
22093      else
22094
22095
22096  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
22097
22098  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
22099  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22100    eval "EXTRA_LDFLAGS$unique=set"
22101    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
22102  fi
22103
22104
22105
22106  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
22107
22108  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
22109  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22110    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
22111    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
22112  fi
22113
22114      fi
22115    ;;
22116    -l*)
22117      ac_ii=`echo $ac_i|cut -c 3-`
22118
22119
22120  case $ac_ii in
22121  c|c_r) ;;
22122  *)
22123    if test "$ext_shared" = "yes"; then
22124        OPENSSL_SHARED_LIBADD="$OPENSSL_SHARED_LIBADD -l$ac_ii"
22125    else
22126
22127
22128  case $ac_ii in
22129  c|c_r) ;;
22130  *)
22131      LIBS="$LIBS -l$ac_ii"
22132   ;;
22133  esac
22134
22135
22136    fi
22137   ;;
22138  esac
22139
22140
22141    ;;
22142    -L*)
22143      ac_ii=`echo $ac_i|cut -c 3-`
22144
22145  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
22146
22147  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
22148    ai_p=$ac_ii
22149  else
22150
22151    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
22152
22153    ep_realdir=`(cd "$ep_dir" && pwd)`
22154    ai_p="$ep_realdir"/`basename "$ac_ii"`
22155  fi
22156
22157
22158      if test "$ext_shared" = "yes"; then
22159        OPENSSL_SHARED_LIBADD="-L$ai_p $OPENSSL_SHARED_LIBADD"
22160        test -n "$ld_runpath_switch" && OPENSSL_SHARED_LIBADD="$ld_runpath_switch$ai_p $OPENSSL_SHARED_LIBADD"
22161      else
22162
22163
22164
22165  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
22166
22167  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
22168  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22169    eval "LIBPATH$unique=set"
22170
22171    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
22172    LDFLAGS="$LDFLAGS -L$ai_p"
22173    PHP_RPATHS="$PHP_RPATHS $ai_p"
22174
22175  fi
22176
22177
22178      fi
22179
22180  fi
22181
22182    ;;
22183    esac
22184  done
22185
22186
22187  for ac_i in $OPENSSL_CFLAGS; do
22188    case $ac_i in
22189    -I*)
22190      ac_ii=`echo $ac_i|cut -c 3-`
22191
22192  if test "$ac_ii" != "/usr/include"; then
22193
22194  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
22195    ai_p=$ac_ii
22196  else
22197
22198    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
22199
22200    ep_realdir=`(cd "$ep_dir" && pwd)`
22201    ai_p="$ep_realdir"/`basename "$ac_ii"`
22202  fi
22203
22204
22205
22206  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
22207
22208  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
22209  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22210    eval "INCLUDEPATH$unique=set"
22211
22212      if test ""; then
22213        INCLUDES="-I$ai_p $INCLUDES"
22214      else
22215        INCLUDES="$INCLUDES -I$ai_p"
22216      fi
22217
22218  fi
22219
22220  fi
22221
22222    ;;
22223    esac
22224  done
22225
22226
22227
22228printf "%s\n" "#define HAVE_OPENSSL_EXT 1" >>confdefs.h
22229
22230
22231else
22232    as_fn_error $? "OpenSSL check failed. Please check config.log for more information." "$LINENO" 5
22233
22234  fi
22235
22236
22237  ac_fn_c_check_func "$LINENO" "RAND_egd" "ac_cv_func_RAND_egd"
22238if test "x$ac_cv_func_RAND_egd" = xyes
22239then :
22240  printf "%s\n" "#define HAVE_RAND_EGD 1" >>confdefs.h
22241
22242fi
22243
22244
22245  if test "$PHP_SYSTEM_CIPHERS" != "no"; then
22246
22247printf "%s\n" "#define USE_OPENSSL_SYSTEM_CIPHERS 1" >>confdefs.h
22248
22249  fi
22250fi
22251
22252
22253
22254
22255
22256php_with_external_pcre=no
22257
22258
22259
22260# Check whether --with-external-pcre was given.
22261if test ${with_external_pcre+y}
22262then :
22263  withval=$with_external_pcre; PHP_EXTERNAL_PCRE=$withval
22264else $as_nop
22265
22266  PHP_EXTERNAL_PCRE=no
22267
22268
22269fi
22270
22271
22272ext_output=$PHP_EXTERNAL_PCRE
22273
22274
22275
22276
22277
22278
22279php_with_pcre_jit=yes
22280
22281
22282
22283# Check whether --with-pcre-jit was given.
22284if test ${with_pcre_jit+y}
22285then :
22286  withval=$with_pcre_jit; PHP_PCRE_JIT=$withval
22287else $as_nop
22288
22289  PHP_PCRE_JIT=yes
22290
22291
22292fi
22293
22294
22295ext_output=$PHP_PCRE_JIT
22296
22297
22298
22299
22300
22301if test "$PHP_EXTERNAL_PCRE" != "no"; then
22302
22303
22304pkg_failed=no
22305{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libpcre2-8 >= 10.30" >&5
22306printf %s "checking for libpcre2-8 >= 10.30... " >&6; }
22307
22308if test -n "$PCRE2_CFLAGS"; then
22309    pkg_cv_PCRE2_CFLAGS="$PCRE2_CFLAGS"
22310 elif test -n "$PKG_CONFIG"; then
22311    if test -n "$PKG_CONFIG" && \
22312    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.30\""; } >&5
22313  ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.30") 2>&5
22314  ac_status=$?
22315  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22316  test $ac_status = 0; }; then
22317  pkg_cv_PCRE2_CFLAGS=`$PKG_CONFIG --cflags "libpcre2-8 >= 10.30" 2>/dev/null`
22318		      test "x$?" != "x0" && pkg_failed=yes
22319else
22320  pkg_failed=yes
22321fi
22322 else
22323    pkg_failed=untried
22324fi
22325if test -n "$PCRE2_LIBS"; then
22326    pkg_cv_PCRE2_LIBS="$PCRE2_LIBS"
22327 elif test -n "$PKG_CONFIG"; then
22328    if test -n "$PKG_CONFIG" && \
22329    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpcre2-8 >= 10.30\""; } >&5
22330  ($PKG_CONFIG --exists --print-errors "libpcre2-8 >= 10.30") 2>&5
22331  ac_status=$?
22332  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22333  test $ac_status = 0; }; then
22334  pkg_cv_PCRE2_LIBS=`$PKG_CONFIG --libs "libpcre2-8 >= 10.30" 2>/dev/null`
22335		      test "x$?" != "x0" && pkg_failed=yes
22336else
22337  pkg_failed=yes
22338fi
22339 else
22340    pkg_failed=untried
22341fi
22342
22343
22344
22345if test $pkg_failed = yes; then
22346        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
22347printf "%s\n" "no" >&6; }
22348
22349if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
22350        _pkg_short_errors_supported=yes
22351else
22352        _pkg_short_errors_supported=no
22353fi
22354        if test $_pkg_short_errors_supported = yes; then
22355	        PCRE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpcre2-8 >= 10.30" 2>&1`
22356        else
22357	        PCRE2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpcre2-8 >= 10.30" 2>&1`
22358        fi
22359	# Put the nasty error message in config.log where it belongs
22360	echo "$PCRE2_PKG_ERRORS" >&5
22361
22362	as_fn_error $? "Package requirements (libpcre2-8 >= 10.30) were not met:
22363
22364$PCRE2_PKG_ERRORS
22365
22366Consider adjusting the PKG_CONFIG_PATH environment variable if you
22367installed software in a non-standard prefix.
22368
22369Alternatively, you may set the environment variables PCRE2_CFLAGS
22370and PCRE2_LIBS to avoid the need to call pkg-config.
22371See the pkg-config man page for more details." "$LINENO" 5
22372elif test $pkg_failed = untried; then
22373        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
22374printf "%s\n" "no" >&6; }
22375	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
22376printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
22377as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
22378is in your PATH or set the PKG_CONFIG environment variable to the full
22379path to pkg-config.
22380
22381Alternatively, you may set the environment variables PCRE2_CFLAGS
22382and PCRE2_LIBS to avoid the need to call pkg-config.
22383See the pkg-config man page for more details.
22384
22385To get pkg-config, see <http://pkg-config.freedesktop.org/>.
22386See \`config.log' for more details" "$LINENO" 5; }
22387else
22388	PCRE2_CFLAGS=$pkg_cv_PCRE2_CFLAGS
22389	PCRE2_LIBS=$pkg_cv_PCRE2_LIBS
22390        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22391printf "%s\n" "yes" >&6; }
22392
22393fi
22394
22395
22396  for ac_i in $PCRE2_CFLAGS; do
22397    case $ac_i in
22398    -I*)
22399      ac_ii=`echo $ac_i|cut -c 3-`
22400
22401  if test "$ac_ii" != "/usr/include"; then
22402
22403  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
22404    ai_p=$ac_ii
22405  else
22406
22407    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
22408
22409    ep_realdir=`(cd "$ep_dir" && pwd)`
22410    ai_p="$ep_realdir"/`basename "$ac_ii"`
22411  fi
22412
22413
22414
22415  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
22416
22417  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
22418  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22419    eval "INCLUDEPATH$unique=set"
22420
22421      if test ""; then
22422        INCLUDES="-I$ai_p $INCLUDES"
22423      else
22424        INCLUDES="$INCLUDES -I$ai_p"
22425      fi
22426
22427  fi
22428
22429  fi
22430
22431    ;;
22432    esac
22433  done
22434
22435
22436  for ac_i in $PCRE2_LIBS; do
22437    case $ac_i in
22438    -pthread)
22439      if test "$ext_shared" = "yes"; then
22440        ="$ -pthread"
22441      else
22442
22443
22444  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
22445
22446  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
22447  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22448    eval "EXTRA_LDFLAGS$unique=set"
22449    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
22450  fi
22451
22452
22453
22454  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
22455
22456  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
22457  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22458    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
22459    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
22460  fi
22461
22462      fi
22463    ;;
22464    -l*)
22465      ac_ii=`echo $ac_i|cut -c 3-`
22466
22467
22468  case $ac_ii in
22469  c|c_r) ;;
22470  *)
22471      LIBS="$LIBS -l$ac_ii"
22472   ;;
22473  esac
22474
22475
22476    ;;
22477    -L*)
22478      ac_ii=`echo $ac_i|cut -c 3-`
22479
22480  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
22481
22482  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
22483    ai_p=$ac_ii
22484  else
22485
22486    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
22487
22488    ep_realdir=`(cd "$ep_dir" && pwd)`
22489    ai_p="$ep_realdir"/`basename "$ac_ii"`
22490  fi
22491
22492
22493
22494
22495
22496  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
22497
22498  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
22499  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22500    eval "LIBPATH$unique=set"
22501
22502    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
22503    LDFLAGS="$LDFLAGS -L$ai_p"
22504    PHP_RPATHS="$PHP_RPATHS $ai_p"
22505
22506  fi
22507
22508
22509
22510  fi
22511
22512    ;;
22513    esac
22514  done
22515
22516
22517printf "%s\n" "#define PCRE2_CODE_UNIT_WIDTH 8" >>confdefs.h
22518
22519
22520  if test "$PHP_PCRE_JIT" != "no"; then
22521    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for JIT support in PCRE2" >&5
22522printf %s "checking for JIT support in PCRE2... " >&6; }
22523if test ${ac_cv_have_pcre2_jit+y}
22524then :
22525  printf %s "(cached) " >&6
22526else $as_nop
22527
22528      if test "$cross_compiling" = yes
22529then :
22530
22531
22532          case $host_cpu in
22533          arm*|i[34567]86|x86_64|mips*|powerpc*|sparc)
22534            ac_cv_have_pcre2_jit=yes
22535            ;;
22536          *)
22537            ac_cv_have_pcre2_jit=no
22538            ;;
22539          esac
22540
22541else $as_nop
22542  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22543/* end confdefs.h.  */
22544
22545
22546              #include <pcre2.h>
22547              #include <stdlib.h>
22548              int main(void) {
22549                uint32_t have_jit;
22550                pcre2_config_8(PCRE2_CONFIG_JIT, &have_jit);
22551                return !have_jit;
22552              }
22553
22554_ACEOF
22555if ac_fn_c_try_run "$LINENO"
22556then :
22557
22558          ac_cv_have_pcre2_jit=yes
22559
22560else $as_nop
22561
22562          ac_cv_have_pcre2_jit=no
22563
22564fi
22565rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22566  conftest.$ac_objext conftest.beam conftest.$ac_ext
22567fi
22568
22569
22570fi
22571{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pcre2_jit" >&5
22572printf "%s\n" "$ac_cv_have_pcre2_jit" >&6; }
22573      if test $ac_cv_have_pcre2_jit = yes; then
22574        printf "%s\n" "#define HAVE_PCRE_JIT_SUPPORT 1" >>confdefs.h
22575
22576      fi
22577  fi
22578
22579
22580  ext_builddir=ext/pcre
22581  ext_srcdir=$abs_srcdir/ext/pcre
22582  ext_dir=ext/pcre
22583
22584  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
22585
22586  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
22587    PHP_PCRE_SHARED=no
22588
22589
22590  case $ext_dir in
22591  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22592  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22593  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22594  esac
22595
22596
22597
22598  b_c_pre=$php_c_pre
22599  b_cxx_pre=$php_cxx_pre
22600  b_c_meta=$php_c_meta
22601  b_cxx_meta=$php_cxx_meta
22602  b_c_post=$php_c_post
22603  b_cxx_post=$php_cxx_post
22604  b_lo=$php_lo
22605
22606
22607  old_IFS=$IFS
22608  for ac_src in php_pcre.c; do
22609
22610      IFS=.
22611      set $ac_src
22612      ac_obj=$1
22613      IFS=$old_IFS
22614
22615      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
22616
22617      case $ac_src in
22618        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22619        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22620        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22621        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
22622      esac
22623
22624      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
22625
22626    cat >>Makefile.objects<<EOF
22627-include $ac_bdir$ac_obj.dep
22628$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
22629	$ac_comp
22630EOF
22631  done
22632
22633
22634    EXT_STATIC="$EXT_STATIC pcre;$ext_dir"
22635    if test "no" != "nocli"; then
22636      EXT_CLI_STATIC="$EXT_CLI_STATIC pcre;$ext_dir"
22637    fi
22638  else
22639    if test "no" = "shared" || test "no" = "yes"; then
22640      PHP_PCRE_SHARED=yes
22641
22642  case $ext_dir in
22643  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22644  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22645  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22646  esac
22647
22648
22649
22650  b_c_pre=$shared_c_pre
22651  b_cxx_pre=$shared_cxx_pre
22652  b_c_meta=$shared_c_meta
22653  b_cxx_meta=$shared_cxx_meta
22654  b_c_post=$shared_c_post
22655  b_cxx_post=$shared_cxx_post
22656  b_lo=$shared_lo
22657
22658
22659  old_IFS=$IFS
22660  for ac_src in php_pcre.c; do
22661
22662      IFS=.
22663      set $ac_src
22664      ac_obj=$1
22665      IFS=$old_IFS
22666
22667      shared_objects_pcre="$shared_objects_pcre $ac_bdir$ac_obj.lo"
22668
22669      case $ac_src in
22670        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22671        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22672        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22673        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
22674      esac
22675
22676      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
22677
22678    cat >>Makefile.objects<<EOF
22679-include $ac_bdir$ac_obj.dep
22680$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
22681	$ac_comp
22682EOF
22683  done
22684
22685
22686  install_modules="install-modules"
22687  suffix=la
22688
22689  case $host_alias in
22690    *aix*)
22691      additional_flags="-Wl,-G"
22692      ;;
22693  esac
22694
22695  if test "x" = "xyes"; then
22696    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pcre.$suffix"
22697  else
22698    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pcre.$suffix"
22699  fi
22700
22701  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pcre"
22702
22703  cat >>Makefile.objects<<EOF
22704\$(phplibdir)/pcre.$suffix: $ext_builddir/pcre.$suffix
22705	\$(LIBTOOL) --mode=install cp $ext_builddir/pcre.$suffix \$(phplibdir)
22706
22707$ext_builddir/pcre.$suffix: \$(shared_objects_pcre) \$(PCRE_SHARED_DEPENDENCIES)
22708	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pcre) \$(PCRE_SHARED_LIBADD)
22709
22710EOF
22711
22712
22713printf "%s\n" "#define COMPILE_DL_PCRE 1" >>confdefs.h
22714
22715    fi
22716  fi
22717
22718  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
22719    PHP_PCRE_SHARED=no
22720    case "$PHP_SAPI" in
22721      cgi|embed|phpdbg)
22722
22723
22724  case $ext_dir in
22725  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22726  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22727  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22728  esac
22729
22730
22731
22732  b_c_pre=$php_c_pre
22733  b_cxx_pre=$php_cxx_pre
22734  b_c_meta=$php_c_meta
22735  b_cxx_meta=$php_cxx_meta
22736  b_c_post=$php_c_post
22737  b_cxx_post=$php_cxx_post
22738  b_lo=$php_lo
22739
22740
22741  old_IFS=$IFS
22742  for ac_src in php_pcre.c; do
22743
22744      IFS=.
22745      set $ac_src
22746      ac_obj=$1
22747      IFS=$old_IFS
22748
22749      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
22750
22751      case $ac_src in
22752        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22753        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22754        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22755        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
22756      esac
22757
22758      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
22759
22760    cat >>Makefile.objects<<EOF
22761-include $ac_bdir$ac_obj.dep
22762$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
22763	$ac_comp
22764EOF
22765  done
22766
22767
22768        EXT_STATIC="$EXT_STATIC pcre;$ext_dir"
22769        ;;
22770      *)
22771
22772
22773  case $ext_dir in
22774  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22775  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22776  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22777  esac
22778
22779
22780
22781  b_c_pre=$php_c_pre
22782  b_cxx_pre=$php_cxx_pre
22783  b_c_meta=$php_c_meta
22784  b_cxx_meta=$php_cxx_meta
22785  b_c_post=$php_c_post
22786  b_cxx_post=$php_cxx_post
22787  b_lo=$php_lo
22788
22789
22790  old_IFS=$IFS
22791  for ac_src in php_pcre.c; do
22792
22793      IFS=.
22794      set $ac_src
22795      ac_obj=$1
22796      IFS=$old_IFS
22797
22798      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
22799
22800      case $ac_src in
22801        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22802        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22803        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22804        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
22805      esac
22806
22807      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
22808
22809    cat >>Makefile.objects<<EOF
22810-include $ac_bdir$ac_obj.dep
22811$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
22812	$ac_comp
22813EOF
22814  done
22815
22816
22817        ;;
22818    esac
22819    EXT_CLI_STATIC="$EXT_CLI_STATIC pcre;$ext_dir"
22820  fi
22821
22822
22823    BUILD_DIR="$BUILD_DIR $ext_builddir"
22824
22825
22826
22827  if test "$ext_builddir" = "."; then
22828    PHP_PECL_EXTENSION=pcre
22829
22830  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
22831
22832  fi
22833
22834
22835
22836    header_path=ext/pcre
22837    for header_file in php_pcre.h; do
22838      hp_hf="$header_path/$header_file"
22839
22840
22841  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
22842
22843  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
22844  if test -n "$unique" && test "`eval $cmd`" = "" ; then
22845    eval "INSTALLHEADERS$unique=set"
22846
22847        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
22848
22849  fi
22850
22851    done
22852
22853
22854else
22855  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PCRE library to use" >&5
22856printf %s "checking for PCRE library to use... " >&6; }
22857  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
22858printf "%s\n" "bundled" >&6; }
22859  pcrelib_sources="pcre2lib/pcre2_auto_possess.c pcre2lib/pcre2_chartables.c pcre2lib/pcre2_compile.c \
22860      pcre2lib/pcre2_config.c pcre2lib/pcre2_context.c pcre2lib/pcre2_dfa_match.c pcre2lib/pcre2_error.c \
22861  pcre2lib/pcre2_jit_compile.c pcre2lib/pcre2_maketables.c pcre2lib/pcre2_match.c pcre2lib/pcre2_match_data.c \
22862  pcre2lib/pcre2_newline.c pcre2lib/pcre2_ord2utf.c pcre2lib/pcre2_pattern_info.c pcre2lib/pcre2_serialize.c \
22863  pcre2lib/pcre2_string_utils.c pcre2lib/pcre2_study.c pcre2lib/pcre2_substitute.c  pcre2lib/pcre2_substring.c \
22864  pcre2lib/pcre2_tables.c pcre2lib/pcre2_ucd.c pcre2lib/pcre2_valid_utf.c pcre2lib/pcre2_xclass.c \
22865  pcre2lib/pcre2_find_bracket.c pcre2lib/pcre2_convert.c pcre2lib/pcre2_extuni.c pcre2lib/pcre2_script_run.c"
22866  PHP_PCRE_CFLAGS="-Wno-implicit-fallthrough -DHAVE_CONFIG_H -I@ext_srcdir@/pcre2lib -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
22867
22868printf "%s\n" "#define HAVE_BUNDLED_PCRE 1" >>confdefs.h
22869
22870
22871printf "%s\n" "#define PCRE2_CODE_UNIT_WIDTH 8" >>confdefs.h
22872
22873
22874  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable PCRE JIT functionality" >&5
22875printf %s "checking whether to enable PCRE JIT functionality... " >&6; }
22876  if test "$PHP_PCRE_JIT" != "no"; then
22877
22878printf "%s\n" "#define HAVE_PCRE_JIT_SUPPORT 1" >>confdefs.h
22879
22880    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22881printf "%s\n" "yes" >&6; }
22882
22883    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether Intel CET is enabled" >&5
22884printf %s "checking whether Intel CET is enabled... " >&6; }
22885if test ${ac_cv_have_pcre2_intel_cet+y}
22886then :
22887  printf %s "(cached) " >&6
22888else $as_nop
22889
22890      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22891/* end confdefs.h.  */
22892
22893
22894          #ifndef __CET__
22895          # error CET is not enabled
22896          #endif
22897
22898_ACEOF
22899if ac_fn_c_try_compile "$LINENO"
22900then :
22901
22902          ac_cv_have_pcre2_intel_cet=yes
22903
22904else $as_nop
22905
22906          ac_cv_have_pcre2_intel_cet=no
22907
22908fi
22909rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
22910      if test "$ac_cv_have_pcre2_intel_cet" = yes; then
22911        PHP_PCRE_CFLAGS="-mshstk $PHP_PCRE_CFLAGS"
22912      fi
22913
22914fi
22915{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pcre2_intel_cet" >&5
22916printf "%s\n" "$ac_cv_have_pcre2_intel_cet" >&6; }
22917
22918  else
22919    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
22920printf "%s\n" "no" >&6; }
22921  fi
22922
22923
22924  ext_builddir=ext/pcre
22925  ext_srcdir=$abs_srcdir/ext/pcre
22926  ext_dir=ext/pcre
22927
22928  ac_extra=`echo "$PHP_PCRE_CFLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
22929
22930  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
22931    PHP_PCRE_SHARED=no
22932
22933
22934  case $ext_dir in
22935  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22936  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22937  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22938  esac
22939
22940
22941
22942  b_c_pre=$php_c_pre
22943  b_cxx_pre=$php_cxx_pre
22944  b_c_meta=$php_c_meta
22945  b_cxx_meta=$php_cxx_meta
22946  b_c_post=$php_c_post
22947  b_cxx_post=$php_cxx_post
22948  b_lo=$php_lo
22949
22950
22951  old_IFS=$IFS
22952  for ac_src in $pcrelib_sources php_pcre.c; do
22953
22954      IFS=.
22955      set $ac_src
22956      ac_obj=$1
22957      IFS=$old_IFS
22958
22959      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
22960
22961      case $ac_src in
22962        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22963        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22964        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
22965        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
22966      esac
22967
22968      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
22969
22970    cat >>Makefile.objects<<EOF
22971-include $ac_bdir$ac_obj.dep
22972$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
22973	$ac_comp
22974EOF
22975  done
22976
22977
22978    EXT_STATIC="$EXT_STATIC pcre;$ext_dir"
22979    if test "no" != "nocli"; then
22980      EXT_CLI_STATIC="$EXT_CLI_STATIC pcre;$ext_dir"
22981    fi
22982  else
22983    if test "no" = "shared" || test "no" = "yes"; then
22984      PHP_PCRE_SHARED=yes
22985
22986  case $ext_dir in
22987  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
22988  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
22989  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
22990  esac
22991
22992
22993
22994  b_c_pre=$shared_c_pre
22995  b_cxx_pre=$shared_cxx_pre
22996  b_c_meta=$shared_c_meta
22997  b_cxx_meta=$shared_cxx_meta
22998  b_c_post=$shared_c_post
22999  b_cxx_post=$shared_cxx_post
23000  b_lo=$shared_lo
23001
23002
23003  old_IFS=$IFS
23004  for ac_src in $pcrelib_sources php_pcre.c; do
23005
23006      IFS=.
23007      set $ac_src
23008      ac_obj=$1
23009      IFS=$old_IFS
23010
23011      shared_objects_pcre="$shared_objects_pcre $ac_bdir$ac_obj.lo"
23012
23013      case $ac_src in
23014        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23015        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23016        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23017        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
23018      esac
23019
23020      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
23021
23022    cat >>Makefile.objects<<EOF
23023-include $ac_bdir$ac_obj.dep
23024$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
23025	$ac_comp
23026EOF
23027  done
23028
23029
23030  install_modules="install-modules"
23031  suffix=la
23032
23033  case $host_alias in
23034    *aix*)
23035      additional_flags="-Wl,-G"
23036      ;;
23037  esac
23038
23039  if test "x" = "xyes"; then
23040    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pcre.$suffix"
23041  else
23042    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pcre.$suffix"
23043  fi
23044
23045  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pcre"
23046
23047  cat >>Makefile.objects<<EOF
23048\$(phplibdir)/pcre.$suffix: $ext_builddir/pcre.$suffix
23049	\$(LIBTOOL) --mode=install cp $ext_builddir/pcre.$suffix \$(phplibdir)
23050
23051$ext_builddir/pcre.$suffix: \$(shared_objects_pcre) \$(PCRE_SHARED_DEPENDENCIES)
23052	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pcre) \$(PCRE_SHARED_LIBADD)
23053
23054EOF
23055
23056
23057printf "%s\n" "#define COMPILE_DL_PCRE 1" >>confdefs.h
23058
23059    fi
23060  fi
23061
23062  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
23063    PHP_PCRE_SHARED=no
23064    case "$PHP_SAPI" in
23065      cgi|embed|phpdbg)
23066
23067
23068  case $ext_dir in
23069  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
23070  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
23071  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
23072  esac
23073
23074
23075
23076  b_c_pre=$php_c_pre
23077  b_cxx_pre=$php_cxx_pre
23078  b_c_meta=$php_c_meta
23079  b_cxx_meta=$php_cxx_meta
23080  b_c_post=$php_c_post
23081  b_cxx_post=$php_cxx_post
23082  b_lo=$php_lo
23083
23084
23085  old_IFS=$IFS
23086  for ac_src in $pcrelib_sources php_pcre.c; do
23087
23088      IFS=.
23089      set $ac_src
23090      ac_obj=$1
23091      IFS=$old_IFS
23092
23093      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
23094
23095      case $ac_src in
23096        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23097        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23098        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23099        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
23100      esac
23101
23102      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
23103
23104    cat >>Makefile.objects<<EOF
23105-include $ac_bdir$ac_obj.dep
23106$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
23107	$ac_comp
23108EOF
23109  done
23110
23111
23112        EXT_STATIC="$EXT_STATIC pcre;$ext_dir"
23113        ;;
23114      *)
23115
23116
23117  case $ext_dir in
23118  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
23119  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
23120  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
23121  esac
23122
23123
23124
23125  b_c_pre=$php_c_pre
23126  b_cxx_pre=$php_cxx_pre
23127  b_c_meta=$php_c_meta
23128  b_cxx_meta=$php_cxx_meta
23129  b_c_post=$php_c_post
23130  b_cxx_post=$php_cxx_post
23131  b_lo=$php_lo
23132
23133
23134  old_IFS=$IFS
23135  for ac_src in $pcrelib_sources php_pcre.c; do
23136
23137      IFS=.
23138      set $ac_src
23139      ac_obj=$1
23140      IFS=$old_IFS
23141
23142      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
23143
23144      case $ac_src in
23145        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23146        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23147        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
23148        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
23149      esac
23150
23151      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
23152
23153    cat >>Makefile.objects<<EOF
23154-include $ac_bdir$ac_obj.dep
23155$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
23156	$ac_comp
23157EOF
23158  done
23159
23160
23161        ;;
23162    esac
23163    EXT_CLI_STATIC="$EXT_CLI_STATIC pcre;$ext_dir"
23164  fi
23165
23166
23167    BUILD_DIR="$BUILD_DIR $ext_builddir"
23168
23169
23170
23171  if test "$ext_builddir" = "."; then
23172    PHP_PECL_EXTENSION=pcre
23173
23174  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
23175
23176  fi
23177
23178
23179
23180    BUILD_DIR="$BUILD_DIR $ext_builddir/pcre2lib"
23181
23182
23183
23184
23185    header_path=ext/pcre
23186    for header_file in php_pcre.h pcre2lib/; do
23187      hp_hf="$header_path/$header_file"
23188
23189
23190  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
23191
23192  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
23193  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23194    eval "INSTALLHEADERS$unique=set"
23195
23196        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
23197
23198  fi
23199
23200    done
23201
23202
23203
23204  if test "$PHP_VALGRIND" != "no" && test "$have_valgrind" = "yes"; then
23205            if test "$ZEND_DEBUG" = "yes"; then
23206
23207printf "%s\n" "#define HAVE_PCRE_VALGRIND_SUPPORT 1" >>confdefs.h
23208
23209      fi
23210  fi
23211fi
23212
23213
23214
23215
23216
23217php_with_sqlite3=yes
23218
23219{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable the SQLite3 extension" >&5
23220printf %s "checking whether to enable the SQLite3 extension... " >&6; }
23221
23222# Check whether --with-sqlite3 was given.
23223if test ${with_sqlite3+y}
23224then :
23225  withval=$with_sqlite3; PHP_SQLITE3=$withval
23226else $as_nop
23227
23228  PHP_SQLITE3=yes
23229  test "$PHP_ENABLE_ALL" && PHP_SQLITE3=$PHP_ENABLE_ALL
23230
23231fi
23232
23233
23234
23235ext_output="yes, shared"
23236ext_shared=yes
23237case $PHP_SQLITE3 in
23238shared,*)
23239  PHP_SQLITE3=`echo "$PHP_SQLITE3"|$SED 's/^shared,//'`
23240  ;;
23241shared)
23242  PHP_SQLITE3=yes
23243  ;;
23244no)
23245  ext_output=no
23246  ext_shared=no
23247  ;;
23248*)
23249  ext_output=yes
23250  ext_shared=no
23251  ;;
23252esac
23253
23254
23255
23256{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
23257printf "%s\n" "$ext_output" >&6; }
23258
23259
23260
23261
23262if test $PHP_SQLITE3 != "no"; then
23263
23264pkg_failed=no
23265{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3 >= 3.7.7" >&5
23266printf %s "checking for sqlite3 >= 3.7.7... " >&6; }
23267
23268if test -n "$SQLITE_CFLAGS"; then
23269    pkg_cv_SQLITE_CFLAGS="$SQLITE_CFLAGS"
23270 elif test -n "$PKG_CONFIG"; then
23271    if test -n "$PKG_CONFIG" && \
23272    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3 >= 3.7.7\""; } >&5
23273  ($PKG_CONFIG --exists --print-errors "sqlite3 >= 3.7.7") 2>&5
23274  ac_status=$?
23275  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
23276  test $ac_status = 0; }; then
23277  pkg_cv_SQLITE_CFLAGS=`$PKG_CONFIG --cflags "sqlite3 >= 3.7.7" 2>/dev/null`
23278		      test "x$?" != "x0" && pkg_failed=yes
23279else
23280  pkg_failed=yes
23281fi
23282 else
23283    pkg_failed=untried
23284fi
23285if test -n "$SQLITE_LIBS"; then
23286    pkg_cv_SQLITE_LIBS="$SQLITE_LIBS"
23287 elif test -n "$PKG_CONFIG"; then
23288    if test -n "$PKG_CONFIG" && \
23289    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3 >= 3.7.7\""; } >&5
23290  ($PKG_CONFIG --exists --print-errors "sqlite3 >= 3.7.7") 2>&5
23291  ac_status=$?
23292  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
23293  test $ac_status = 0; }; then
23294  pkg_cv_SQLITE_LIBS=`$PKG_CONFIG --libs "sqlite3 >= 3.7.7" 2>/dev/null`
23295		      test "x$?" != "x0" && pkg_failed=yes
23296else
23297  pkg_failed=yes
23298fi
23299 else
23300    pkg_failed=untried
23301fi
23302
23303
23304
23305if test $pkg_failed = yes; then
23306        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
23307printf "%s\n" "no" >&6; }
23308
23309if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
23310        _pkg_short_errors_supported=yes
23311else
23312        _pkg_short_errors_supported=no
23313fi
23314        if test $_pkg_short_errors_supported = yes; then
23315	        SQLITE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "sqlite3 >= 3.7.7" 2>&1`
23316        else
23317	        SQLITE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "sqlite3 >= 3.7.7" 2>&1`
23318        fi
23319	# Put the nasty error message in config.log where it belongs
23320	echo "$SQLITE_PKG_ERRORS" >&5
23321
23322	as_fn_error $? "Package requirements (sqlite3 >= 3.7.7) were not met:
23323
23324$SQLITE_PKG_ERRORS
23325
23326Consider adjusting the PKG_CONFIG_PATH environment variable if you
23327installed software in a non-standard prefix.
23328
23329Alternatively, you may set the environment variables SQLITE_CFLAGS
23330and SQLITE_LIBS to avoid the need to call pkg-config.
23331See the pkg-config man page for more details." "$LINENO" 5
23332elif test $pkg_failed = untried; then
23333        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
23334printf "%s\n" "no" >&6; }
23335	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23336printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
23337as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
23338is in your PATH or set the PKG_CONFIG environment variable to the full
23339path to pkg-config.
23340
23341Alternatively, you may set the environment variables SQLITE_CFLAGS
23342and SQLITE_LIBS to avoid the need to call pkg-config.
23343See the pkg-config man page for more details.
23344
23345To get pkg-config, see <http://pkg-config.freedesktop.org/>.
23346See \`config.log' for more details" "$LINENO" 5; }
23347else
23348	SQLITE_CFLAGS=$pkg_cv_SQLITE_CFLAGS
23349	SQLITE_LIBS=$pkg_cv_SQLITE_LIBS
23350        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
23351printf "%s\n" "yes" >&6; }
23352
23353fi
23354
23355
23356  for ac_i in $SQLITE_CFLAGS; do
23357    case $ac_i in
23358    -I*)
23359      ac_ii=`echo $ac_i|cut -c 3-`
23360
23361  if test "$ac_ii" != "/usr/include"; then
23362
23363  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
23364    ai_p=$ac_ii
23365  else
23366
23367    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
23368
23369    ep_realdir=`(cd "$ep_dir" && pwd)`
23370    ai_p="$ep_realdir"/`basename "$ac_ii"`
23371  fi
23372
23373
23374
23375  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
23376
23377  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
23378  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23379    eval "INCLUDEPATH$unique=set"
23380
23381      if test ""; then
23382        INCLUDES="-I$ai_p $INCLUDES"
23383      else
23384        INCLUDES="$INCLUDES -I$ai_p"
23385      fi
23386
23387  fi
23388
23389  fi
23390
23391    ;;
23392    esac
23393  done
23394
23395
23396  for ac_i in $SQLITE_LIBS; do
23397    case $ac_i in
23398    -pthread)
23399      if test "$ext_shared" = "yes"; then
23400        SQLITE3_SHARED_LIBADD="$SQLITE3_SHARED_LIBADD -pthread"
23401      else
23402
23403
23404  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23405
23406  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
23407  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23408    eval "EXTRA_LDFLAGS$unique=set"
23409    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
23410  fi
23411
23412
23413
23414  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23415
23416  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
23417  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23418    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
23419    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
23420  fi
23421
23422      fi
23423    ;;
23424    -l*)
23425      ac_ii=`echo $ac_i|cut -c 3-`
23426
23427
23428  case $ac_ii in
23429  c|c_r) ;;
23430  *)
23431    if test "$ext_shared" = "yes"; then
23432        SQLITE3_SHARED_LIBADD="$SQLITE3_SHARED_LIBADD -l$ac_ii"
23433    else
23434
23435
23436  case $ac_ii in
23437  c|c_r) ;;
23438  *)
23439      LIBS="$LIBS -l$ac_ii"
23440   ;;
23441  esac
23442
23443
23444    fi
23445   ;;
23446  esac
23447
23448
23449    ;;
23450    -L*)
23451      ac_ii=`echo $ac_i|cut -c 3-`
23452
23453  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
23454
23455  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
23456    ai_p=$ac_ii
23457  else
23458
23459    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
23460
23461    ep_realdir=`(cd "$ep_dir" && pwd)`
23462    ai_p="$ep_realdir"/`basename "$ac_ii"`
23463  fi
23464
23465
23466      if test "$ext_shared" = "yes"; then
23467        SQLITE3_SHARED_LIBADD="-L$ai_p $SQLITE3_SHARED_LIBADD"
23468        test -n "$ld_runpath_switch" && SQLITE3_SHARED_LIBADD="$ld_runpath_switch$ai_p $SQLITE3_SHARED_LIBADD"
23469      else
23470
23471
23472
23473  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
23474
23475  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
23476  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23477    eval "LIBPATH$unique=set"
23478
23479    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
23480    LDFLAGS="$LDFLAGS -L$ai_p"
23481    PHP_RPATHS="$PHP_RPATHS $ai_p"
23482
23483  fi
23484
23485
23486      fi
23487
23488  fi
23489
23490    ;;
23491    esac
23492  done
23493
23494
23495printf "%s\n" "#define HAVE_SQLITE3 1" >>confdefs.h
23496
23497
23498
23499  save_old_LDFLAGS=$LDFLAGS
23500  ac_stuff="$SQLITE3_SHARED_LIBADD"
23501
23502  save_ext_shared=$ext_shared
23503  ext_shared=yes
23504
23505  for ac_i in $ac_stuff; do
23506    case $ac_i in
23507    -pthread)
23508      if test "$ext_shared" = "yes"; then
23509        LDFLAGS="$LDFLAGS -pthread"
23510      else
23511
23512
23513  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23514
23515  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
23516  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23517    eval "EXTRA_LDFLAGS$unique=set"
23518    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
23519  fi
23520
23521
23522
23523  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23524
23525  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
23526  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23527    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
23528    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
23529  fi
23530
23531      fi
23532    ;;
23533    -l*)
23534      ac_ii=`echo $ac_i|cut -c 3-`
23535
23536
23537  case $ac_ii in
23538  c|c_r) ;;
23539  *)
23540    if test "$ext_shared" = "yes"; then
23541        LDFLAGS="$LDFLAGS -l$ac_ii"
23542    else
23543
23544
23545  case $ac_ii in
23546  c|c_r) ;;
23547  *)
23548      LIBS="$LIBS -l$ac_ii"
23549   ;;
23550  esac
23551
23552
23553    fi
23554   ;;
23555  esac
23556
23557
23558    ;;
23559    -L*)
23560      ac_ii=`echo $ac_i|cut -c 3-`
23561
23562  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
23563
23564  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
23565    ai_p=$ac_ii
23566  else
23567
23568    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
23569
23570    ep_realdir=`(cd "$ep_dir" && pwd)`
23571    ai_p="$ep_realdir"/`basename "$ac_ii"`
23572  fi
23573
23574
23575      if test "$ext_shared" = "yes"; then
23576        LDFLAGS="-L$ai_p $LDFLAGS"
23577        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
23578      else
23579
23580
23581
23582  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
23583
23584  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
23585  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23586    eval "LIBPATH$unique=set"
23587
23588    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
23589    LDFLAGS="$LDFLAGS -L$ai_p"
23590    PHP_RPATHS="$PHP_RPATHS $ai_p"
23591
23592  fi
23593
23594
23595      fi
23596
23597  fi
23598
23599    ;;
23600    esac
23601  done
23602
23603  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3_errstr in -lsqlite3" >&5
23604printf %s "checking for sqlite3_errstr in -lsqlite3... " >&6; }
23605if test ${ac_cv_lib_sqlite3_sqlite3_errstr+y}
23606then :
23607  printf %s "(cached) " >&6
23608else $as_nop
23609  ac_check_lib_save_LIBS=$LIBS
23610LIBS="-lsqlite3  $LIBS"
23611cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23612/* end confdefs.h.  */
23613
23614/* Override any GCC internal prototype to avoid an error.
23615   Use char because int might match the return type of a GCC
23616   builtin and then its argument prototype would still apply.  */
23617char sqlite3_errstr ();
23618int
23619main (void)
23620{
23621return sqlite3_errstr ();
23622  ;
23623  return 0;
23624}
23625_ACEOF
23626if ac_fn_c_try_link "$LINENO"
23627then :
23628  ac_cv_lib_sqlite3_sqlite3_errstr=yes
23629else $as_nop
23630  ac_cv_lib_sqlite3_sqlite3_errstr=no
23631fi
23632rm -f core conftest.err conftest.$ac_objext conftest.beam \
23633    conftest$ac_exeext conftest.$ac_ext
23634LIBS=$ac_check_lib_save_LIBS
23635fi
23636{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_errstr" >&5
23637printf "%s\n" "$ac_cv_lib_sqlite3_sqlite3_errstr" >&6; }
23638if test "x$ac_cv_lib_sqlite3_sqlite3_errstr" = xyes
23639then :
23640
23641    LDFLAGS=$save_old_LDFLAGS
23642    ext_shared=$save_ext_shared
23643
23644
23645printf "%s\n" "#define HAVE_SQLITE3_ERRSTR 1" >>confdefs.h
23646
23647
23648
23649else $as_nop
23650
23651    LDFLAGS=$save_old_LDFLAGS
23652    ext_shared=$save_ext_shared
23653    unset ac_cv_lib_sqlite3_sqlite3_errstr
23654
23655
23656fi
23657
23658
23659
23660  save_old_LDFLAGS=$LDFLAGS
23661  ac_stuff="$SQLITE3_SHARED_LIBADD"
23662
23663  save_ext_shared=$ext_shared
23664  ext_shared=yes
23665
23666  for ac_i in $ac_stuff; do
23667    case $ac_i in
23668    -pthread)
23669      if test "$ext_shared" = "yes"; then
23670        LDFLAGS="$LDFLAGS -pthread"
23671      else
23672
23673
23674  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23675
23676  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
23677  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23678    eval "EXTRA_LDFLAGS$unique=set"
23679    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
23680  fi
23681
23682
23683
23684  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23685
23686  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
23687  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23688    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
23689    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
23690  fi
23691
23692      fi
23693    ;;
23694    -l*)
23695      ac_ii=`echo $ac_i|cut -c 3-`
23696
23697
23698  case $ac_ii in
23699  c|c_r) ;;
23700  *)
23701    if test "$ext_shared" = "yes"; then
23702        LDFLAGS="$LDFLAGS -l$ac_ii"
23703    else
23704
23705
23706  case $ac_ii in
23707  c|c_r) ;;
23708  *)
23709      LIBS="$LIBS -l$ac_ii"
23710   ;;
23711  esac
23712
23713
23714    fi
23715   ;;
23716  esac
23717
23718
23719    ;;
23720    -L*)
23721      ac_ii=`echo $ac_i|cut -c 3-`
23722
23723  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
23724
23725  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
23726    ai_p=$ac_ii
23727  else
23728
23729    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
23730
23731    ep_realdir=`(cd "$ep_dir" && pwd)`
23732    ai_p="$ep_realdir"/`basename "$ac_ii"`
23733  fi
23734
23735
23736      if test "$ext_shared" = "yes"; then
23737        LDFLAGS="-L$ai_p $LDFLAGS"
23738        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
23739      else
23740
23741
23742
23743  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
23744
23745  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
23746  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23747    eval "LIBPATH$unique=set"
23748
23749    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
23750    LDFLAGS="$LDFLAGS -L$ai_p"
23751    PHP_RPATHS="$PHP_RPATHS $ai_p"
23752
23753  fi
23754
23755
23756      fi
23757
23758  fi
23759
23760    ;;
23761    esac
23762  done
23763
23764  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3_expanded_sql in -lsqlite3" >&5
23765printf %s "checking for sqlite3_expanded_sql in -lsqlite3... " >&6; }
23766if test ${ac_cv_lib_sqlite3_sqlite3_expanded_sql+y}
23767then :
23768  printf %s "(cached) " >&6
23769else $as_nop
23770  ac_check_lib_save_LIBS=$LIBS
23771LIBS="-lsqlite3  $LIBS"
23772cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23773/* end confdefs.h.  */
23774
23775/* Override any GCC internal prototype to avoid an error.
23776   Use char because int might match the return type of a GCC
23777   builtin and then its argument prototype would still apply.  */
23778char sqlite3_expanded_sql ();
23779int
23780main (void)
23781{
23782return sqlite3_expanded_sql ();
23783  ;
23784  return 0;
23785}
23786_ACEOF
23787if ac_fn_c_try_link "$LINENO"
23788then :
23789  ac_cv_lib_sqlite3_sqlite3_expanded_sql=yes
23790else $as_nop
23791  ac_cv_lib_sqlite3_sqlite3_expanded_sql=no
23792fi
23793rm -f core conftest.err conftest.$ac_objext conftest.beam \
23794    conftest$ac_exeext conftest.$ac_ext
23795LIBS=$ac_check_lib_save_LIBS
23796fi
23797{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_expanded_sql" >&5
23798printf "%s\n" "$ac_cv_lib_sqlite3_sqlite3_expanded_sql" >&6; }
23799if test "x$ac_cv_lib_sqlite3_sqlite3_expanded_sql" = xyes
23800then :
23801
23802    LDFLAGS=$save_old_LDFLAGS
23803    ext_shared=$save_ext_shared
23804
23805
23806printf "%s\n" "#define HAVE_SQLITE3_EXPANDED_SQL 1" >>confdefs.h
23807
23808
23809
23810else $as_nop
23811
23812    LDFLAGS=$save_old_LDFLAGS
23813    ext_shared=$save_ext_shared
23814    unset ac_cv_lib_sqlite3_sqlite3_expanded_sql
23815
23816
23817fi
23818
23819
23820
23821  save_old_LDFLAGS=$LDFLAGS
23822  ac_stuff="$SQLITE3_SHARED_LIBADD
23823  "
23824
23825  save_ext_shared=$ext_shared
23826  ext_shared=yes
23827
23828  for ac_i in $ac_stuff; do
23829    case $ac_i in
23830    -pthread)
23831      if test "$ext_shared" = "yes"; then
23832        LDFLAGS="$LDFLAGS -pthread"
23833      else
23834
23835
23836  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23837
23838  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
23839  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23840    eval "EXTRA_LDFLAGS$unique=set"
23841    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
23842  fi
23843
23844
23845
23846  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
23847
23848  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
23849  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23850    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
23851    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
23852  fi
23853
23854      fi
23855    ;;
23856    -l*)
23857      ac_ii=`echo $ac_i|cut -c 3-`
23858
23859
23860  case $ac_ii in
23861  c|c_r) ;;
23862  *)
23863    if test "$ext_shared" = "yes"; then
23864        LDFLAGS="$LDFLAGS -l$ac_ii"
23865    else
23866
23867
23868  case $ac_ii in
23869  c|c_r) ;;
23870  *)
23871      LIBS="$LIBS -l$ac_ii"
23872   ;;
23873  esac
23874
23875
23876    fi
23877   ;;
23878  esac
23879
23880
23881    ;;
23882    -L*)
23883      ac_ii=`echo $ac_i|cut -c 3-`
23884
23885  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
23886
23887  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
23888    ai_p=$ac_ii
23889  else
23890
23891    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
23892
23893    ep_realdir=`(cd "$ep_dir" && pwd)`
23894    ai_p="$ep_realdir"/`basename "$ac_ii"`
23895  fi
23896
23897
23898      if test "$ext_shared" = "yes"; then
23899        LDFLAGS="-L$ai_p $LDFLAGS"
23900        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
23901      else
23902
23903
23904
23905  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
23906
23907  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
23908  if test -n "$unique" && test "`eval $cmd`" = "" ; then
23909    eval "LIBPATH$unique=set"
23910
23911    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
23912    LDFLAGS="$LDFLAGS -L$ai_p"
23913    PHP_RPATHS="$PHP_RPATHS $ai_p"
23914
23915  fi
23916
23917
23918      fi
23919
23920  fi
23921
23922    ;;
23923    esac
23924  done
23925
23926  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3_load_extension in -lsqlite3" >&5
23927printf %s "checking for sqlite3_load_extension in -lsqlite3... " >&6; }
23928if test ${ac_cv_lib_sqlite3_sqlite3_load_extension+y}
23929then :
23930  printf %s "(cached) " >&6
23931else $as_nop
23932  ac_check_lib_save_LIBS=$LIBS
23933LIBS="-lsqlite3  $LIBS"
23934cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23935/* end confdefs.h.  */
23936
23937/* Override any GCC internal prototype to avoid an error.
23938   Use char because int might match the return type of a GCC
23939   builtin and then its argument prototype would still apply.  */
23940char sqlite3_load_extension ();
23941int
23942main (void)
23943{
23944return sqlite3_load_extension ();
23945  ;
23946  return 0;
23947}
23948_ACEOF
23949if ac_fn_c_try_link "$LINENO"
23950then :
23951  ac_cv_lib_sqlite3_sqlite3_load_extension=yes
23952else $as_nop
23953  ac_cv_lib_sqlite3_sqlite3_load_extension=no
23954fi
23955rm -f core conftest.err conftest.$ac_objext conftest.beam \
23956    conftest$ac_exeext conftest.$ac_ext
23957LIBS=$ac_check_lib_save_LIBS
23958fi
23959{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_load_extension" >&5
23960printf "%s\n" "$ac_cv_lib_sqlite3_sqlite3_load_extension" >&6; }
23961if test "x$ac_cv_lib_sqlite3_sqlite3_load_extension" = xyes
23962then :
23963
23964    LDFLAGS=$save_old_LDFLAGS
23965    ext_shared=$save_ext_shared
23966
23967
23968else $as_nop
23969
23970    LDFLAGS=$save_old_LDFLAGS
23971    ext_shared=$save_ext_shared
23972    unset ac_cv_lib_sqlite3_sqlite3_load_extension
23973
23974printf "%s\n" "#define SQLITE_OMIT_LOAD_EXTENSION 1" >>confdefs.h
23975
23976
23977fi
23978
23979
23980
23981  ext_builddir=ext/sqlite3
23982  ext_srcdir=$abs_srcdir/ext/sqlite3
23983  ext_dir=ext/sqlite3
23984
23985  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
23986
23987  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
23988    PHP_SQLITE3_SHARED=no
23989
23990
23991  case $ext_dir in
23992  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
23993  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
23994  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
23995  esac
23996
23997
23998
23999  b_c_pre=$php_c_pre
24000  b_cxx_pre=$php_cxx_pre
24001  b_c_meta=$php_c_meta
24002  b_cxx_meta=$php_cxx_meta
24003  b_c_post=$php_c_post
24004  b_cxx_post=$php_cxx_post
24005  b_lo=$php_lo
24006
24007
24008  old_IFS=$IFS
24009  for ac_src in sqlite3.c; do
24010
24011      IFS=.
24012      set $ac_src
24013      ac_obj=$1
24014      IFS=$old_IFS
24015
24016      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24017
24018      case $ac_src in
24019        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24020        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24021        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24022        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24023      esac
24024
24025      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24026
24027    cat >>Makefile.objects<<EOF
24028-include $ac_bdir$ac_obj.dep
24029$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24030	$ac_comp
24031EOF
24032  done
24033
24034
24035    EXT_STATIC="$EXT_STATIC sqlite3;$ext_dir"
24036    if test "$ext_shared" != "nocli"; then
24037      EXT_CLI_STATIC="$EXT_CLI_STATIC sqlite3;$ext_dir"
24038    fi
24039  else
24040    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
24041      PHP_SQLITE3_SHARED=yes
24042
24043  case $ext_dir in
24044  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24045  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24046  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24047  esac
24048
24049
24050
24051  b_c_pre=$shared_c_pre
24052  b_cxx_pre=$shared_cxx_pre
24053  b_c_meta=$shared_c_meta
24054  b_cxx_meta=$shared_cxx_meta
24055  b_c_post=$shared_c_post
24056  b_cxx_post=$shared_cxx_post
24057  b_lo=$shared_lo
24058
24059
24060  old_IFS=$IFS
24061  for ac_src in sqlite3.c; do
24062
24063      IFS=.
24064      set $ac_src
24065      ac_obj=$1
24066      IFS=$old_IFS
24067
24068      shared_objects_sqlite3="$shared_objects_sqlite3 $ac_bdir$ac_obj.lo"
24069
24070      case $ac_src in
24071        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24072        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24073        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24074        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24075      esac
24076
24077      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24078
24079    cat >>Makefile.objects<<EOF
24080-include $ac_bdir$ac_obj.dep
24081$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24082	$ac_comp
24083EOF
24084  done
24085
24086
24087  install_modules="install-modules"
24088  suffix=la
24089
24090  case $host_alias in
24091    *aix*)
24092      additional_flags="-Wl,-G"
24093      ;;
24094  esac
24095
24096  if test "x" = "xyes"; then
24097    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sqlite3.$suffix"
24098  else
24099    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sqlite3.$suffix"
24100  fi
24101
24102  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sqlite3"
24103
24104  cat >>Makefile.objects<<EOF
24105\$(phplibdir)/sqlite3.$suffix: $ext_builddir/sqlite3.$suffix
24106	\$(LIBTOOL) --mode=install cp $ext_builddir/sqlite3.$suffix \$(phplibdir)
24107
24108$ext_builddir/sqlite3.$suffix: \$(shared_objects_sqlite3) \$(SQLITE3_SHARED_DEPENDENCIES)
24109	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sqlite3) \$(SQLITE3_SHARED_LIBADD)
24110
24111EOF
24112
24113
24114printf "%s\n" "#define COMPILE_DL_SQLITE3 1" >>confdefs.h
24115
24116    fi
24117  fi
24118
24119  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
24120    PHP_SQLITE3_SHARED=no
24121    case "$PHP_SAPI" in
24122      cgi|embed|phpdbg)
24123
24124
24125  case $ext_dir in
24126  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24127  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24128  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24129  esac
24130
24131
24132
24133  b_c_pre=$php_c_pre
24134  b_cxx_pre=$php_cxx_pre
24135  b_c_meta=$php_c_meta
24136  b_cxx_meta=$php_cxx_meta
24137  b_c_post=$php_c_post
24138  b_cxx_post=$php_cxx_post
24139  b_lo=$php_lo
24140
24141
24142  old_IFS=$IFS
24143  for ac_src in sqlite3.c; do
24144
24145      IFS=.
24146      set $ac_src
24147      ac_obj=$1
24148      IFS=$old_IFS
24149
24150      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24151
24152      case $ac_src in
24153        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24154        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24155        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24156        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24157      esac
24158
24159      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24160
24161    cat >>Makefile.objects<<EOF
24162-include $ac_bdir$ac_obj.dep
24163$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24164	$ac_comp
24165EOF
24166  done
24167
24168
24169        EXT_STATIC="$EXT_STATIC sqlite3;$ext_dir"
24170        ;;
24171      *)
24172
24173
24174  case $ext_dir in
24175  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24176  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24177  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24178  esac
24179
24180
24181
24182  b_c_pre=$php_c_pre
24183  b_cxx_pre=$php_cxx_pre
24184  b_c_meta=$php_c_meta
24185  b_cxx_meta=$php_cxx_meta
24186  b_c_post=$php_c_post
24187  b_cxx_post=$php_cxx_post
24188  b_lo=$php_lo
24189
24190
24191  old_IFS=$IFS
24192  for ac_src in sqlite3.c; do
24193
24194      IFS=.
24195      set $ac_src
24196      ac_obj=$1
24197      IFS=$old_IFS
24198
24199      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24200
24201      case $ac_src in
24202        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24203        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24204        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24205        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24206      esac
24207
24208      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24209
24210    cat >>Makefile.objects<<EOF
24211-include $ac_bdir$ac_obj.dep
24212$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24213	$ac_comp
24214EOF
24215  done
24216
24217
24218        ;;
24219    esac
24220    EXT_CLI_STATIC="$EXT_CLI_STATIC sqlite3;$ext_dir"
24221  fi
24222
24223
24224    BUILD_DIR="$BUILD_DIR $ext_builddir"
24225
24226
24227
24228  if test "$ext_builddir" = "."; then
24229    PHP_PECL_EXTENSION=sqlite3
24230
24231  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
24232
24233  fi
24234
24235
24236  PHP_VAR_SUBST="$PHP_VAR_SUBST SQLITE3_SHARED_LIBADD"
24237
24238fi
24239
24240
24241
24242
24243
24244php_with_zlib=no
24245
24246{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ZLIB support" >&5
24247printf %s "checking for ZLIB support... " >&6; }
24248
24249# Check whether --with-zlib was given.
24250if test ${with_zlib+y}
24251then :
24252  withval=$with_zlib; PHP_ZLIB=$withval
24253else $as_nop
24254
24255  PHP_ZLIB=no
24256  test "$PHP_ENABLE_ALL" && PHP_ZLIB=$PHP_ENABLE_ALL
24257
24258fi
24259
24260
24261
24262ext_output="yes, shared"
24263ext_shared=yes
24264case $PHP_ZLIB in
24265shared,*)
24266  PHP_ZLIB=`echo "$PHP_ZLIB"|$SED 's/^shared,//'`
24267  ;;
24268shared)
24269  PHP_ZLIB=yes
24270  ;;
24271no)
24272  ext_output=no
24273  ext_shared=no
24274  ;;
24275*)
24276  ext_output=yes
24277  ext_shared=no
24278  ;;
24279esac
24280
24281
24282
24283{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
24284printf "%s\n" "$ext_output" >&6; }
24285
24286
24287
24288
24289if test "$PHP_ZLIB" != "no"; then
24290
24291pkg_failed=no
24292{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zlib >= 1.2.0.4" >&5
24293printf %s "checking for zlib >= 1.2.0.4... " >&6; }
24294
24295if test -n "$ZLIB_CFLAGS"; then
24296    pkg_cv_ZLIB_CFLAGS="$ZLIB_CFLAGS"
24297 elif test -n "$PKG_CONFIG"; then
24298    if test -n "$PKG_CONFIG" && \
24299    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib >= 1.2.0.4\""; } >&5
24300  ($PKG_CONFIG --exists --print-errors "zlib >= 1.2.0.4") 2>&5
24301  ac_status=$?
24302  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
24303  test $ac_status = 0; }; then
24304  pkg_cv_ZLIB_CFLAGS=`$PKG_CONFIG --cflags "zlib >= 1.2.0.4" 2>/dev/null`
24305		      test "x$?" != "x0" && pkg_failed=yes
24306else
24307  pkg_failed=yes
24308fi
24309 else
24310    pkg_failed=untried
24311fi
24312if test -n "$ZLIB_LIBS"; then
24313    pkg_cv_ZLIB_LIBS="$ZLIB_LIBS"
24314 elif test -n "$PKG_CONFIG"; then
24315    if test -n "$PKG_CONFIG" && \
24316    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib >= 1.2.0.4\""; } >&5
24317  ($PKG_CONFIG --exists --print-errors "zlib >= 1.2.0.4") 2>&5
24318  ac_status=$?
24319  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
24320  test $ac_status = 0; }; then
24321  pkg_cv_ZLIB_LIBS=`$PKG_CONFIG --libs "zlib >= 1.2.0.4" 2>/dev/null`
24322		      test "x$?" != "x0" && pkg_failed=yes
24323else
24324  pkg_failed=yes
24325fi
24326 else
24327    pkg_failed=untried
24328fi
24329
24330
24331
24332if test $pkg_failed = yes; then
24333        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
24334printf "%s\n" "no" >&6; }
24335
24336if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
24337        _pkg_short_errors_supported=yes
24338else
24339        _pkg_short_errors_supported=no
24340fi
24341        if test $_pkg_short_errors_supported = yes; then
24342	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "zlib >= 1.2.0.4" 2>&1`
24343        else
24344	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "zlib >= 1.2.0.4" 2>&1`
24345        fi
24346	# Put the nasty error message in config.log where it belongs
24347	echo "$ZLIB_PKG_ERRORS" >&5
24348
24349	as_fn_error $? "Package requirements (zlib >= 1.2.0.4) were not met:
24350
24351$ZLIB_PKG_ERRORS
24352
24353Consider adjusting the PKG_CONFIG_PATH environment variable if you
24354installed software in a non-standard prefix.
24355
24356Alternatively, you may set the environment variables ZLIB_CFLAGS
24357and ZLIB_LIBS to avoid the need to call pkg-config.
24358See the pkg-config man page for more details." "$LINENO" 5
24359elif test $pkg_failed = untried; then
24360        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
24361printf "%s\n" "no" >&6; }
24362	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
24363printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
24364as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
24365is in your PATH or set the PKG_CONFIG environment variable to the full
24366path to pkg-config.
24367
24368Alternatively, you may set the environment variables ZLIB_CFLAGS
24369and ZLIB_LIBS to avoid the need to call pkg-config.
24370See the pkg-config man page for more details.
24371
24372To get pkg-config, see <http://pkg-config.freedesktop.org/>.
24373See \`config.log' for more details" "$LINENO" 5; }
24374else
24375	ZLIB_CFLAGS=$pkg_cv_ZLIB_CFLAGS
24376	ZLIB_LIBS=$pkg_cv_ZLIB_LIBS
24377        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24378printf "%s\n" "yes" >&6; }
24379
24380fi
24381
24382
24383  for ac_i in $ZLIB_LIBS; do
24384    case $ac_i in
24385    -pthread)
24386      if test "$ext_shared" = "yes"; then
24387        ZLIB_SHARED_LIBADD="$ZLIB_SHARED_LIBADD -pthread"
24388      else
24389
24390
24391  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
24392
24393  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
24394  if test -n "$unique" && test "`eval $cmd`" = "" ; then
24395    eval "EXTRA_LDFLAGS$unique=set"
24396    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
24397  fi
24398
24399
24400
24401  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
24402
24403  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
24404  if test -n "$unique" && test "`eval $cmd`" = "" ; then
24405    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
24406    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
24407  fi
24408
24409      fi
24410    ;;
24411    -l*)
24412      ac_ii=`echo $ac_i|cut -c 3-`
24413
24414
24415  case $ac_ii in
24416  c|c_r) ;;
24417  *)
24418    if test "$ext_shared" = "yes"; then
24419        ZLIB_SHARED_LIBADD="$ZLIB_SHARED_LIBADD -l$ac_ii"
24420    else
24421
24422
24423  case $ac_ii in
24424  c|c_r) ;;
24425  *)
24426      LIBS="$LIBS -l$ac_ii"
24427   ;;
24428  esac
24429
24430
24431    fi
24432   ;;
24433  esac
24434
24435
24436    ;;
24437    -L*)
24438      ac_ii=`echo $ac_i|cut -c 3-`
24439
24440  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
24441
24442  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
24443    ai_p=$ac_ii
24444  else
24445
24446    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
24447
24448    ep_realdir=`(cd "$ep_dir" && pwd)`
24449    ai_p="$ep_realdir"/`basename "$ac_ii"`
24450  fi
24451
24452
24453      if test "$ext_shared" = "yes"; then
24454        ZLIB_SHARED_LIBADD="-L$ai_p $ZLIB_SHARED_LIBADD"
24455        test -n "$ld_runpath_switch" && ZLIB_SHARED_LIBADD="$ld_runpath_switch$ai_p $ZLIB_SHARED_LIBADD"
24456      else
24457
24458
24459
24460  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
24461
24462  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
24463  if test -n "$unique" && test "`eval $cmd`" = "" ; then
24464    eval "LIBPATH$unique=set"
24465
24466    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
24467    LDFLAGS="$LDFLAGS -L$ai_p"
24468    PHP_RPATHS="$PHP_RPATHS $ai_p"
24469
24470  fi
24471
24472
24473      fi
24474
24475  fi
24476
24477    ;;
24478    esac
24479  done
24480
24481
24482  for ac_i in $ZLIB_CFLAGS; do
24483    case $ac_i in
24484    -I*)
24485      ac_ii=`echo $ac_i|cut -c 3-`
24486
24487  if test "$ac_ii" != "/usr/include"; then
24488
24489  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
24490    ai_p=$ac_ii
24491  else
24492
24493    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
24494
24495    ep_realdir=`(cd "$ep_dir" && pwd)`
24496    ai_p="$ep_realdir"/`basename "$ac_ii"`
24497  fi
24498
24499
24500
24501  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
24502
24503  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
24504  if test -n "$unique" && test "`eval $cmd`" = "" ; then
24505    eval "INCLUDEPATH$unique=set"
24506
24507      if test ""; then
24508        INCLUDES="-I$ai_p $INCLUDES"
24509      else
24510        INCLUDES="$INCLUDES -I$ai_p"
24511      fi
24512
24513  fi
24514
24515  fi
24516
24517    ;;
24518    esac
24519  done
24520
24521
24522
24523printf "%s\n" "#define HAVE_ZLIB 1" >>confdefs.h
24524
24525
24526
24527  ext_builddir=ext/zlib
24528  ext_srcdir=$abs_srcdir/ext/zlib
24529  ext_dir=ext/zlib
24530
24531  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
24532
24533  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
24534    PHP_ZLIB_SHARED=no
24535
24536
24537  case $ext_dir in
24538  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24539  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24540  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24541  esac
24542
24543
24544
24545  b_c_pre=$php_c_pre
24546  b_cxx_pre=$php_cxx_pre
24547  b_c_meta=$php_c_meta
24548  b_cxx_meta=$php_cxx_meta
24549  b_c_post=$php_c_post
24550  b_cxx_post=$php_cxx_post
24551  b_lo=$php_lo
24552
24553
24554  old_IFS=$IFS
24555  for ac_src in zlib.c zlib_fopen_wrapper.c zlib_filter.c; do
24556
24557      IFS=.
24558      set $ac_src
24559      ac_obj=$1
24560      IFS=$old_IFS
24561
24562      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24563
24564      case $ac_src in
24565        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24566        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24567        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24568        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24569      esac
24570
24571      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24572
24573    cat >>Makefile.objects<<EOF
24574-include $ac_bdir$ac_obj.dep
24575$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24576	$ac_comp
24577EOF
24578  done
24579
24580
24581    EXT_STATIC="$EXT_STATIC zlib;$ext_dir"
24582    if test "$ext_shared" != "nocli"; then
24583      EXT_CLI_STATIC="$EXT_CLI_STATIC zlib;$ext_dir"
24584    fi
24585  else
24586    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
24587      PHP_ZLIB_SHARED=yes
24588
24589  case $ext_dir in
24590  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24591  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24592  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24593  esac
24594
24595
24596
24597  b_c_pre=$shared_c_pre
24598  b_cxx_pre=$shared_cxx_pre
24599  b_c_meta=$shared_c_meta
24600  b_cxx_meta=$shared_cxx_meta
24601  b_c_post=$shared_c_post
24602  b_cxx_post=$shared_cxx_post
24603  b_lo=$shared_lo
24604
24605
24606  old_IFS=$IFS
24607  for ac_src in zlib.c zlib_fopen_wrapper.c zlib_filter.c; do
24608
24609      IFS=.
24610      set $ac_src
24611      ac_obj=$1
24612      IFS=$old_IFS
24613
24614      shared_objects_zlib="$shared_objects_zlib $ac_bdir$ac_obj.lo"
24615
24616      case $ac_src in
24617        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24618        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24619        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24620        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24621      esac
24622
24623      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24624
24625    cat >>Makefile.objects<<EOF
24626-include $ac_bdir$ac_obj.dep
24627$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24628	$ac_comp
24629EOF
24630  done
24631
24632
24633  install_modules="install-modules"
24634  suffix=la
24635
24636  case $host_alias in
24637    *aix*)
24638      additional_flags="-Wl,-G"
24639      ;;
24640  esac
24641
24642  if test "x" = "xyes"; then
24643    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/zlib.$suffix"
24644  else
24645    PHP_MODULES="$PHP_MODULES \$(phplibdir)/zlib.$suffix"
24646  fi
24647
24648  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_zlib"
24649
24650  cat >>Makefile.objects<<EOF
24651\$(phplibdir)/zlib.$suffix: $ext_builddir/zlib.$suffix
24652	\$(LIBTOOL) --mode=install cp $ext_builddir/zlib.$suffix \$(phplibdir)
24653
24654$ext_builddir/zlib.$suffix: \$(shared_objects_zlib) \$(ZLIB_SHARED_DEPENDENCIES)
24655	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_zlib) \$(ZLIB_SHARED_LIBADD)
24656
24657EOF
24658
24659
24660printf "%s\n" "#define COMPILE_DL_ZLIB 1" >>confdefs.h
24661
24662    fi
24663  fi
24664
24665  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
24666    PHP_ZLIB_SHARED=no
24667    case "$PHP_SAPI" in
24668      cgi|embed|phpdbg)
24669
24670
24671  case $ext_dir in
24672  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24673  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24674  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24675  esac
24676
24677
24678
24679  b_c_pre=$php_c_pre
24680  b_cxx_pre=$php_cxx_pre
24681  b_c_meta=$php_c_meta
24682  b_cxx_meta=$php_cxx_meta
24683  b_c_post=$php_c_post
24684  b_cxx_post=$php_cxx_post
24685  b_lo=$php_lo
24686
24687
24688  old_IFS=$IFS
24689  for ac_src in zlib.c zlib_fopen_wrapper.c zlib_filter.c; do
24690
24691      IFS=.
24692      set $ac_src
24693      ac_obj=$1
24694      IFS=$old_IFS
24695
24696      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24697
24698      case $ac_src in
24699        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24700        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24701        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24702        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24703      esac
24704
24705      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24706
24707    cat >>Makefile.objects<<EOF
24708-include $ac_bdir$ac_obj.dep
24709$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24710	$ac_comp
24711EOF
24712  done
24713
24714
24715        EXT_STATIC="$EXT_STATIC zlib;$ext_dir"
24716        ;;
24717      *)
24718
24719
24720  case $ext_dir in
24721  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24722  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24723  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24724  esac
24725
24726
24727
24728  b_c_pre=$php_c_pre
24729  b_cxx_pre=$php_cxx_pre
24730  b_c_meta=$php_c_meta
24731  b_cxx_meta=$php_cxx_meta
24732  b_c_post=$php_c_post
24733  b_cxx_post=$php_cxx_post
24734  b_lo=$php_lo
24735
24736
24737  old_IFS=$IFS
24738  for ac_src in zlib.c zlib_fopen_wrapper.c zlib_filter.c; do
24739
24740      IFS=.
24741      set $ac_src
24742      ac_obj=$1
24743      IFS=$old_IFS
24744
24745      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24746
24747      case $ac_src in
24748        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24749        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24750        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24751        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24752      esac
24753
24754      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24755
24756    cat >>Makefile.objects<<EOF
24757-include $ac_bdir$ac_obj.dep
24758$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24759	$ac_comp
24760EOF
24761  done
24762
24763
24764        ;;
24765    esac
24766    EXT_CLI_STATIC="$EXT_CLI_STATIC zlib;$ext_dir"
24767  fi
24768
24769
24770    BUILD_DIR="$BUILD_DIR $ext_builddir"
24771
24772
24773
24774  if test "$ext_builddir" = "."; then
24775    PHP_PECL_EXTENSION=zlib
24776
24777  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
24778
24779  fi
24780
24781
24782  PHP_VAR_SUBST="$PHP_VAR_SUBST ZLIB_SHARED_LIBADD"
24783
24784fi
24785
24786
24787
24788
24789
24790php_enable_bcmath=no
24791
24792{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable bc style precision math functions" >&5
24793printf %s "checking whether to enable bc style precision math functions... " >&6; }
24794# Check whether --enable-bcmath was given.
24795if test ${enable_bcmath+y}
24796then :
24797  enableval=$enable_bcmath; PHP_BCMATH=$enableval
24798else $as_nop
24799
24800  PHP_BCMATH=no
24801  test "$PHP_ENABLE_ALL" && PHP_BCMATH=$PHP_ENABLE_ALL
24802
24803fi
24804
24805
24806
24807ext_output="yes, shared"
24808ext_shared=yes
24809case $PHP_BCMATH in
24810shared,*)
24811  PHP_BCMATH=`echo "$PHP_BCMATH"|$SED 's/^shared,//'`
24812  ;;
24813shared)
24814  PHP_BCMATH=yes
24815  ;;
24816no)
24817  ext_output=no
24818  ext_shared=no
24819  ;;
24820*)
24821  ext_output=yes
24822  ext_shared=no
24823  ;;
24824esac
24825
24826
24827
24828{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
24829printf "%s\n" "$ext_output" >&6; }
24830
24831
24832
24833
24834if test "$PHP_BCMATH" != "no"; then
24835
24836  ext_builddir=ext/bcmath
24837  ext_srcdir=$abs_srcdir/ext/bcmath
24838  ext_dir=ext/bcmath
24839
24840  ac_extra=`echo "-I@ext_srcdir@/libbcmath/src -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
24841
24842  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
24843    PHP_BCMATH_SHARED=no
24844
24845
24846  case $ext_dir in
24847  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24848  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24849  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24850  esac
24851
24852
24853
24854  b_c_pre=$php_c_pre
24855  b_cxx_pre=$php_cxx_pre
24856  b_c_meta=$php_c_meta
24857  b_cxx_meta=$php_cxx_meta
24858  b_c_post=$php_c_post
24859  b_cxx_post=$php_cxx_post
24860  b_lo=$php_lo
24861
24862
24863  old_IFS=$IFS
24864  for ac_src in bcmath.c \
24865libbcmath/src/add.c libbcmath/src/div.c libbcmath/src/init.c libbcmath/src/neg.c libbcmath/src/raisemod.c libbcmath/src/sub.c \
24866libbcmath/src/compare.c libbcmath/src/divmod.c libbcmath/src/int2num.c libbcmath/src/num2long.c libbcmath/src/output.c libbcmath/src/recmul.c \
24867libbcmath/src/sqrt.c libbcmath/src/zero.c libbcmath/src/debug.c libbcmath/src/doaddsub.c libbcmath/src/nearzero.c libbcmath/src/num2str.c libbcmath/src/raise.c \
24868libbcmath/src/rmzero.c libbcmath/src/str2num.c; do
24869
24870      IFS=.
24871      set $ac_src
24872      ac_obj=$1
24873      IFS=$old_IFS
24874
24875      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
24876
24877      case $ac_src in
24878        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24879        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24880        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24881        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24882      esac
24883
24884      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24885
24886    cat >>Makefile.objects<<EOF
24887-include $ac_bdir$ac_obj.dep
24888$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24889	$ac_comp
24890EOF
24891  done
24892
24893
24894    EXT_STATIC="$EXT_STATIC bcmath;$ext_dir"
24895    if test "$ext_shared" != "nocli"; then
24896      EXT_CLI_STATIC="$EXT_CLI_STATIC bcmath;$ext_dir"
24897    fi
24898  else
24899    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
24900      PHP_BCMATH_SHARED=yes
24901
24902  case $ext_dir in
24903  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24904  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24905  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24906  esac
24907
24908
24909
24910  b_c_pre=$shared_c_pre
24911  b_cxx_pre=$shared_cxx_pre
24912  b_c_meta=$shared_c_meta
24913  b_cxx_meta=$shared_cxx_meta
24914  b_c_post=$shared_c_post
24915  b_cxx_post=$shared_cxx_post
24916  b_lo=$shared_lo
24917
24918
24919  old_IFS=$IFS
24920  for ac_src in bcmath.c \
24921libbcmath/src/add.c libbcmath/src/div.c libbcmath/src/init.c libbcmath/src/neg.c libbcmath/src/raisemod.c libbcmath/src/sub.c \
24922libbcmath/src/compare.c libbcmath/src/divmod.c libbcmath/src/int2num.c libbcmath/src/num2long.c libbcmath/src/output.c libbcmath/src/recmul.c \
24923libbcmath/src/sqrt.c libbcmath/src/zero.c libbcmath/src/debug.c libbcmath/src/doaddsub.c libbcmath/src/nearzero.c libbcmath/src/num2str.c libbcmath/src/raise.c \
24924libbcmath/src/rmzero.c libbcmath/src/str2num.c; do
24925
24926      IFS=.
24927      set $ac_src
24928      ac_obj=$1
24929      IFS=$old_IFS
24930
24931      shared_objects_bcmath="$shared_objects_bcmath $ac_bdir$ac_obj.lo"
24932
24933      case $ac_src in
24934        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24935        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24936        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
24937        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
24938      esac
24939
24940      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
24941
24942    cat >>Makefile.objects<<EOF
24943-include $ac_bdir$ac_obj.dep
24944$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
24945	$ac_comp
24946EOF
24947  done
24948
24949
24950  install_modules="install-modules"
24951  suffix=la
24952
24953  case $host_alias in
24954    *aix*)
24955      additional_flags="-Wl,-G"
24956      ;;
24957  esac
24958
24959  if test "x" = "xyes"; then
24960    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/bcmath.$suffix"
24961  else
24962    PHP_MODULES="$PHP_MODULES \$(phplibdir)/bcmath.$suffix"
24963  fi
24964
24965  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_bcmath"
24966
24967  cat >>Makefile.objects<<EOF
24968\$(phplibdir)/bcmath.$suffix: $ext_builddir/bcmath.$suffix
24969	\$(LIBTOOL) --mode=install cp $ext_builddir/bcmath.$suffix \$(phplibdir)
24970
24971$ext_builddir/bcmath.$suffix: \$(shared_objects_bcmath) \$(BCMATH_SHARED_DEPENDENCIES)
24972	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_bcmath) \$(BCMATH_SHARED_LIBADD)
24973
24974EOF
24975
24976
24977printf "%s\n" "#define COMPILE_DL_BCMATH 1" >>confdefs.h
24978
24979    fi
24980  fi
24981
24982  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
24983    PHP_BCMATH_SHARED=no
24984    case "$PHP_SAPI" in
24985      cgi|embed|phpdbg)
24986
24987
24988  case $ext_dir in
24989  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
24990  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
24991  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
24992  esac
24993
24994
24995
24996  b_c_pre=$php_c_pre
24997  b_cxx_pre=$php_cxx_pre
24998  b_c_meta=$php_c_meta
24999  b_cxx_meta=$php_cxx_meta
25000  b_c_post=$php_c_post
25001  b_cxx_post=$php_cxx_post
25002  b_lo=$php_lo
25003
25004
25005  old_IFS=$IFS
25006  for ac_src in bcmath.c \
25007libbcmath/src/add.c libbcmath/src/div.c libbcmath/src/init.c libbcmath/src/neg.c libbcmath/src/raisemod.c libbcmath/src/sub.c \
25008libbcmath/src/compare.c libbcmath/src/divmod.c libbcmath/src/int2num.c libbcmath/src/num2long.c libbcmath/src/output.c libbcmath/src/recmul.c \
25009libbcmath/src/sqrt.c libbcmath/src/zero.c libbcmath/src/debug.c libbcmath/src/doaddsub.c libbcmath/src/nearzero.c libbcmath/src/num2str.c libbcmath/src/raise.c \
25010libbcmath/src/rmzero.c libbcmath/src/str2num.c; do
25011
25012      IFS=.
25013      set $ac_src
25014      ac_obj=$1
25015      IFS=$old_IFS
25016
25017      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25018
25019      case $ac_src in
25020        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25021        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25022        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25023        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25024      esac
25025
25026      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25027
25028    cat >>Makefile.objects<<EOF
25029-include $ac_bdir$ac_obj.dep
25030$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25031	$ac_comp
25032EOF
25033  done
25034
25035
25036        EXT_STATIC="$EXT_STATIC bcmath;$ext_dir"
25037        ;;
25038      *)
25039
25040
25041  case $ext_dir in
25042  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25043  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25044  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25045  esac
25046
25047
25048
25049  b_c_pre=$php_c_pre
25050  b_cxx_pre=$php_cxx_pre
25051  b_c_meta=$php_c_meta
25052  b_cxx_meta=$php_cxx_meta
25053  b_c_post=$php_c_post
25054  b_cxx_post=$php_cxx_post
25055  b_lo=$php_lo
25056
25057
25058  old_IFS=$IFS
25059  for ac_src in bcmath.c \
25060libbcmath/src/add.c libbcmath/src/div.c libbcmath/src/init.c libbcmath/src/neg.c libbcmath/src/raisemod.c libbcmath/src/sub.c \
25061libbcmath/src/compare.c libbcmath/src/divmod.c libbcmath/src/int2num.c libbcmath/src/num2long.c libbcmath/src/output.c libbcmath/src/recmul.c \
25062libbcmath/src/sqrt.c libbcmath/src/zero.c libbcmath/src/debug.c libbcmath/src/doaddsub.c libbcmath/src/nearzero.c libbcmath/src/num2str.c libbcmath/src/raise.c \
25063libbcmath/src/rmzero.c libbcmath/src/str2num.c; do
25064
25065      IFS=.
25066      set $ac_src
25067      ac_obj=$1
25068      IFS=$old_IFS
25069
25070      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25071
25072      case $ac_src in
25073        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25074        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25075        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25076        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25077      esac
25078
25079      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25080
25081    cat >>Makefile.objects<<EOF
25082-include $ac_bdir$ac_obj.dep
25083$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25084	$ac_comp
25085EOF
25086  done
25087
25088
25089        ;;
25090    esac
25091    EXT_CLI_STATIC="$EXT_CLI_STATIC bcmath;$ext_dir"
25092  fi
25093
25094
25095    BUILD_DIR="$BUILD_DIR $ext_builddir"
25096
25097
25098
25099  if test "$ext_builddir" = "."; then
25100    PHP_PECL_EXTENSION=bcmath
25101
25102  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
25103
25104  fi
25105
25106
25107
25108    BUILD_DIR="$BUILD_DIR $ext_builddir/libbcmath/src"
25109
25110
25111
25112printf "%s\n" "#define HAVE_BCMATH 1" >>confdefs.h
25113
25114fi
25115
25116
25117
25118
25119
25120php_with_bz2=no
25121
25122{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BZip2 support" >&5
25123printf %s "checking for BZip2 support... " >&6; }
25124
25125# Check whether --with-bz2 was given.
25126if test ${with_bz2+y}
25127then :
25128  withval=$with_bz2; PHP_BZ2=$withval
25129else $as_nop
25130
25131  PHP_BZ2=no
25132  test "$PHP_ENABLE_ALL" && PHP_BZ2=$PHP_ENABLE_ALL
25133
25134fi
25135
25136
25137
25138ext_output="yes, shared"
25139ext_shared=yes
25140case $PHP_BZ2 in
25141shared,*)
25142  PHP_BZ2=`echo "$PHP_BZ2"|$SED 's/^shared,//'`
25143  ;;
25144shared)
25145  PHP_BZ2=yes
25146  ;;
25147no)
25148  ext_output=no
25149  ext_shared=no
25150  ;;
25151*)
25152  ext_output=yes
25153  ext_shared=no
25154  ;;
25155esac
25156
25157
25158
25159{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
25160printf "%s\n" "$ext_output" >&6; }
25161
25162
25163
25164
25165if test "$PHP_BZ2" != "no"; then
25166  if test -r $PHP_BZ2/include/bzlib.h; then
25167    BZIP_DIR=$PHP_BZ2
25168  else
25169    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BZip2 in default path" >&5
25170printf %s "checking for BZip2 in default path... " >&6; }
25171    for i in /usr/local /usr; do
25172      if test -r $i/include/bzlib.h; then
25173        BZIP_DIR=$i
25174        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found in $i" >&5
25175printf "%s\n" "found in $i" >&6; }
25176        break
25177      fi
25178    done
25179  fi
25180
25181  if test -z "$BZIP_DIR"; then
25182    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25183printf "%s\n" "not found" >&6; }
25184    as_fn_error $? "Please reinstall the BZip2 distribution" "$LINENO" 5
25185  fi
25186
25187
25188  save_old_LDFLAGS=$LDFLAGS
25189  ac_stuff="
25190    -L$BZIP_DIR/$PHP_LIBDIR
25191  "
25192
25193  save_ext_shared=$ext_shared
25194  ext_shared=yes
25195
25196  for ac_i in $ac_stuff; do
25197    case $ac_i in
25198    -pthread)
25199      if test "$ext_shared" = "yes"; then
25200        LDFLAGS="$LDFLAGS -pthread"
25201      else
25202
25203
25204  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
25205
25206  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
25207  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25208    eval "EXTRA_LDFLAGS$unique=set"
25209    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
25210  fi
25211
25212
25213
25214  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
25215
25216  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
25217  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25218    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
25219    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
25220  fi
25221
25222      fi
25223    ;;
25224    -l*)
25225      ac_ii=`echo $ac_i|cut -c 3-`
25226
25227
25228  case $ac_ii in
25229  c|c_r) ;;
25230  *)
25231    if test "$ext_shared" = "yes"; then
25232        LDFLAGS="$LDFLAGS -l$ac_ii"
25233    else
25234
25235
25236  case $ac_ii in
25237  c|c_r) ;;
25238  *)
25239      LIBS="$LIBS -l$ac_ii"
25240   ;;
25241  esac
25242
25243
25244    fi
25245   ;;
25246  esac
25247
25248
25249    ;;
25250    -L*)
25251      ac_ii=`echo $ac_i|cut -c 3-`
25252
25253  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
25254
25255  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
25256    ai_p=$ac_ii
25257  else
25258
25259    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
25260
25261    ep_realdir=`(cd "$ep_dir" && pwd)`
25262    ai_p="$ep_realdir"/`basename "$ac_ii"`
25263  fi
25264
25265
25266      if test "$ext_shared" = "yes"; then
25267        LDFLAGS="-L$ai_p $LDFLAGS"
25268        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
25269      else
25270
25271
25272
25273  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
25274
25275  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
25276  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25277    eval "LIBPATH$unique=set"
25278
25279    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
25280    LDFLAGS="$LDFLAGS -L$ai_p"
25281    PHP_RPATHS="$PHP_RPATHS $ai_p"
25282
25283  fi
25284
25285
25286      fi
25287
25288  fi
25289
25290    ;;
25291    esac
25292  done
25293
25294  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BZ2_bzerror in -lbz2" >&5
25295printf %s "checking for BZ2_bzerror in -lbz2... " >&6; }
25296if test ${ac_cv_lib_bz2_BZ2_bzerror+y}
25297then :
25298  printf %s "(cached) " >&6
25299else $as_nop
25300  ac_check_lib_save_LIBS=$LIBS
25301LIBS="-lbz2  $LIBS"
25302cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25303/* end confdefs.h.  */
25304
25305/* Override any GCC internal prototype to avoid an error.
25306   Use char because int might match the return type of a GCC
25307   builtin and then its argument prototype would still apply.  */
25308char BZ2_bzerror ();
25309int
25310main (void)
25311{
25312return BZ2_bzerror ();
25313  ;
25314  return 0;
25315}
25316_ACEOF
25317if ac_fn_c_try_link "$LINENO"
25318then :
25319  ac_cv_lib_bz2_BZ2_bzerror=yes
25320else $as_nop
25321  ac_cv_lib_bz2_BZ2_bzerror=no
25322fi
25323rm -f core conftest.err conftest.$ac_objext conftest.beam \
25324    conftest$ac_exeext conftest.$ac_ext
25325LIBS=$ac_check_lib_save_LIBS
25326fi
25327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bz2_BZ2_bzerror" >&5
25328printf "%s\n" "$ac_cv_lib_bz2_BZ2_bzerror" >&6; }
25329if test "x$ac_cv_lib_bz2_BZ2_bzerror" = xyes
25330then :
25331
25332    LDFLAGS=$save_old_LDFLAGS
25333    ext_shared=$save_ext_shared
25334
25335
25336  if test "$BZIP_DIR/include" != "/usr/include"; then
25337
25338  if test -z "$BZIP_DIR/include" || echo "$BZIP_DIR/include" | grep '^/' >/dev/null ; then
25339    ai_p=$BZIP_DIR/include
25340  else
25341
25342    ep_dir=`echo $BZIP_DIR/include|$SED 's%/*[^/][^/]*/*$%%'`
25343
25344    ep_realdir=`(cd "$ep_dir" && pwd)`
25345    ai_p="$ep_realdir"/`basename "$BZIP_DIR/include"`
25346  fi
25347
25348
25349
25350  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
25351
25352  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
25353  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25354    eval "INCLUDEPATH$unique=set"
25355
25356      if test ""; then
25357        INCLUDES="-I$ai_p $INCLUDES"
25358      else
25359        INCLUDES="$INCLUDES -I$ai_p"
25360      fi
25361
25362  fi
25363
25364  fi
25365
25366
25367
25368  if test "$ext_shared" = "yes"; then
25369    BZ2_SHARED_LIBADD="-lbz2 $BZ2_SHARED_LIBADD"
25370    if test -n "$BZIP_DIR/$PHP_LIBDIR"; then
25371
25372  if test "$BZIP_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$BZIP_DIR/$PHP_LIBDIR" != "/usr/lib"; then
25373
25374  if test -z "$BZIP_DIR/$PHP_LIBDIR" || echo "$BZIP_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
25375    ai_p=$BZIP_DIR/$PHP_LIBDIR
25376  else
25377
25378    ep_dir=`echo $BZIP_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
25379
25380    ep_realdir=`(cd "$ep_dir" && pwd)`
25381    ai_p="$ep_realdir"/`basename "$BZIP_DIR/$PHP_LIBDIR"`
25382  fi
25383
25384
25385      if test "$ext_shared" = "yes"; then
25386        BZ2_SHARED_LIBADD="-L$ai_p $BZ2_SHARED_LIBADD"
25387        test -n "$ld_runpath_switch" && BZ2_SHARED_LIBADD="$ld_runpath_switch$ai_p $BZ2_SHARED_LIBADD"
25388      else
25389
25390
25391
25392  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
25393
25394  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
25395  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25396    eval "LIBPATH$unique=set"
25397
25398    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
25399    LDFLAGS="$LDFLAGS -L$ai_p"
25400    PHP_RPATHS="$PHP_RPATHS $ai_p"
25401
25402  fi
25403
25404
25405      fi
25406
25407  fi
25408
25409    fi
25410  else
25411
25412
25413  if test -n "$BZIP_DIR/$PHP_LIBDIR"; then
25414
25415  if test "$BZIP_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$BZIP_DIR/$PHP_LIBDIR" != "/usr/lib"; then
25416
25417  if test -z "$BZIP_DIR/$PHP_LIBDIR" || echo "$BZIP_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
25418    ai_p=$BZIP_DIR/$PHP_LIBDIR
25419  else
25420
25421    ep_dir=`echo $BZIP_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
25422
25423    ep_realdir=`(cd "$ep_dir" && pwd)`
25424    ai_p="$ep_realdir"/`basename "$BZIP_DIR/$PHP_LIBDIR"`
25425  fi
25426
25427
25428
25429
25430
25431  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
25432
25433  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
25434  if test -n "$unique" && test "`eval $cmd`" = "" ; then
25435    eval "LIBPATH$unique=set"
25436
25437    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
25438    LDFLAGS="$LDFLAGS -L$ai_p"
25439    PHP_RPATHS="$PHP_RPATHS $ai_p"
25440
25441  fi
25442
25443
25444
25445  fi
25446
25447  fi
25448
25449
25450  case bz2 in
25451  c|c_r) ;;
25452  *)
25453      LIBS="-lbz2 $LIBS"
25454   ;;
25455  esac
25456
25457
25458
25459
25460  fi
25461
25462
25463
25464printf "%s\n" "#define HAVE_BZ2 1" >>confdefs.h
25465
25466
25467
25468else $as_nop
25469
25470    LDFLAGS=$save_old_LDFLAGS
25471    ext_shared=$save_ext_shared
25472    unset ac_cv_lib_bz2_BZ2_bzerror
25473
25474    as_fn_error $? "bz2 module requires libbz2 >= 1.0.0" "$LINENO" 5
25475
25476
25477fi
25478
25479
25480
25481  ext_builddir=ext/bz2
25482  ext_srcdir=$abs_srcdir/ext/bz2
25483  ext_dir=ext/bz2
25484
25485  ac_extra=
25486
25487  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
25488    PHP_BZ2_SHARED=no
25489
25490
25491  case $ext_dir in
25492  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25493  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25494  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25495  esac
25496
25497
25498
25499  b_c_pre=$php_c_pre
25500  b_cxx_pre=$php_cxx_pre
25501  b_c_meta=$php_c_meta
25502  b_cxx_meta=$php_cxx_meta
25503  b_c_post=$php_c_post
25504  b_cxx_post=$php_cxx_post
25505  b_lo=$php_lo
25506
25507
25508  old_IFS=$IFS
25509  for ac_src in bz2.c bz2_filter.c; do
25510
25511      IFS=.
25512      set $ac_src
25513      ac_obj=$1
25514      IFS=$old_IFS
25515
25516      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25517
25518      case $ac_src in
25519        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25520        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25521        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25522        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25523      esac
25524
25525      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25526
25527    cat >>Makefile.objects<<EOF
25528-include $ac_bdir$ac_obj.dep
25529$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25530	$ac_comp
25531EOF
25532  done
25533
25534
25535    EXT_STATIC="$EXT_STATIC bz2;$ext_dir"
25536    if test "$ext_shared" != "nocli"; then
25537      EXT_CLI_STATIC="$EXT_CLI_STATIC bz2;$ext_dir"
25538    fi
25539  else
25540    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
25541      PHP_BZ2_SHARED=yes
25542
25543  case $ext_dir in
25544  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25545  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25546  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25547  esac
25548
25549
25550
25551  b_c_pre=$shared_c_pre
25552  b_cxx_pre=$shared_cxx_pre
25553  b_c_meta=$shared_c_meta
25554  b_cxx_meta=$shared_cxx_meta
25555  b_c_post=$shared_c_post
25556  b_cxx_post=$shared_cxx_post
25557  b_lo=$shared_lo
25558
25559
25560  old_IFS=$IFS
25561  for ac_src in bz2.c bz2_filter.c; do
25562
25563      IFS=.
25564      set $ac_src
25565      ac_obj=$1
25566      IFS=$old_IFS
25567
25568      shared_objects_bz2="$shared_objects_bz2 $ac_bdir$ac_obj.lo"
25569
25570      case $ac_src in
25571        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25572        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25573        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25574        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25575      esac
25576
25577      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25578
25579    cat >>Makefile.objects<<EOF
25580-include $ac_bdir$ac_obj.dep
25581$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25582	$ac_comp
25583EOF
25584  done
25585
25586
25587  install_modules="install-modules"
25588  suffix=la
25589
25590  case $host_alias in
25591    *aix*)
25592      additional_flags="-Wl,-G"
25593      ;;
25594  esac
25595
25596  if test "x" = "xyes"; then
25597    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/bz2.$suffix"
25598  else
25599    PHP_MODULES="$PHP_MODULES \$(phplibdir)/bz2.$suffix"
25600  fi
25601
25602  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_bz2"
25603
25604  cat >>Makefile.objects<<EOF
25605\$(phplibdir)/bz2.$suffix: $ext_builddir/bz2.$suffix
25606	\$(LIBTOOL) --mode=install cp $ext_builddir/bz2.$suffix \$(phplibdir)
25607
25608$ext_builddir/bz2.$suffix: \$(shared_objects_bz2) \$(BZ2_SHARED_DEPENDENCIES)
25609	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_bz2) \$(BZ2_SHARED_LIBADD)
25610
25611EOF
25612
25613
25614printf "%s\n" "#define COMPILE_DL_BZ2 1" >>confdefs.h
25615
25616    fi
25617  fi
25618
25619  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
25620    PHP_BZ2_SHARED=no
25621    case "$PHP_SAPI" in
25622      cgi|embed|phpdbg)
25623
25624
25625  case $ext_dir in
25626  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25627  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25628  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25629  esac
25630
25631
25632
25633  b_c_pre=$php_c_pre
25634  b_cxx_pre=$php_cxx_pre
25635  b_c_meta=$php_c_meta
25636  b_cxx_meta=$php_cxx_meta
25637  b_c_post=$php_c_post
25638  b_cxx_post=$php_cxx_post
25639  b_lo=$php_lo
25640
25641
25642  old_IFS=$IFS
25643  for ac_src in bz2.c bz2_filter.c; do
25644
25645      IFS=.
25646      set $ac_src
25647      ac_obj=$1
25648      IFS=$old_IFS
25649
25650      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25651
25652      case $ac_src in
25653        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25654        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25655        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25656        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25657      esac
25658
25659      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25660
25661    cat >>Makefile.objects<<EOF
25662-include $ac_bdir$ac_obj.dep
25663$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25664	$ac_comp
25665EOF
25666  done
25667
25668
25669        EXT_STATIC="$EXT_STATIC bz2;$ext_dir"
25670        ;;
25671      *)
25672
25673
25674  case $ext_dir in
25675  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25676  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25677  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25678  esac
25679
25680
25681
25682  b_c_pre=$php_c_pre
25683  b_cxx_pre=$php_cxx_pre
25684  b_c_meta=$php_c_meta
25685  b_cxx_meta=$php_cxx_meta
25686  b_c_post=$php_c_post
25687  b_cxx_post=$php_cxx_post
25688  b_lo=$php_lo
25689
25690
25691  old_IFS=$IFS
25692  for ac_src in bz2.c bz2_filter.c; do
25693
25694      IFS=.
25695      set $ac_src
25696      ac_obj=$1
25697      IFS=$old_IFS
25698
25699      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25700
25701      case $ac_src in
25702        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25703        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25704        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25705        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25706      esac
25707
25708      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25709
25710    cat >>Makefile.objects<<EOF
25711-include $ac_bdir$ac_obj.dep
25712$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25713	$ac_comp
25714EOF
25715  done
25716
25717
25718        ;;
25719    esac
25720    EXT_CLI_STATIC="$EXT_CLI_STATIC bz2;$ext_dir"
25721  fi
25722
25723
25724    BUILD_DIR="$BUILD_DIR $ext_builddir"
25725
25726
25727
25728  if test "$ext_builddir" = "."; then
25729    PHP_PECL_EXTENSION=bz2
25730
25731  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
25732
25733  fi
25734
25735
25736  PHP_VAR_SUBST="$PHP_VAR_SUBST BZ2_SHARED_LIBADD"
25737
25738fi
25739
25740
25741
25742
25743
25744php_enable_calendar=no
25745
25746{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable calendar conversion support" >&5
25747printf %s "checking whether to enable calendar conversion support... " >&6; }
25748# Check whether --enable-calendar was given.
25749if test ${enable_calendar+y}
25750then :
25751  enableval=$enable_calendar; PHP_CALENDAR=$enableval
25752else $as_nop
25753
25754  PHP_CALENDAR=no
25755  test "$PHP_ENABLE_ALL" && PHP_CALENDAR=$PHP_ENABLE_ALL
25756
25757fi
25758
25759
25760
25761ext_output="yes, shared"
25762ext_shared=yes
25763case $PHP_CALENDAR in
25764shared,*)
25765  PHP_CALENDAR=`echo "$PHP_CALENDAR"|$SED 's/^shared,//'`
25766  ;;
25767shared)
25768  PHP_CALENDAR=yes
25769  ;;
25770no)
25771  ext_output=no
25772  ext_shared=no
25773  ;;
25774*)
25775  ext_output=yes
25776  ext_shared=no
25777  ;;
25778esac
25779
25780
25781
25782{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
25783printf "%s\n" "$ext_output" >&6; }
25784
25785
25786
25787
25788if test "$PHP_CALENDAR" = "yes"; then
25789
25790printf "%s\n" "#define HAVE_CALENDAR 1" >>confdefs.h
25791
25792
25793  ext_builddir=ext/calendar
25794  ext_srcdir=$abs_srcdir/ext/calendar
25795  ext_dir=ext/calendar
25796
25797  ac_extra=
25798
25799  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
25800    PHP_CALENDAR_SHARED=no
25801
25802
25803  case $ext_dir in
25804  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25805  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25806  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25807  esac
25808
25809
25810
25811  b_c_pre=$php_c_pre
25812  b_cxx_pre=$php_cxx_pre
25813  b_c_meta=$php_c_meta
25814  b_cxx_meta=$php_cxx_meta
25815  b_c_post=$php_c_post
25816  b_cxx_post=$php_cxx_post
25817  b_lo=$php_lo
25818
25819
25820  old_IFS=$IFS
25821  for ac_src in calendar.c dow.c french.c gregor.c jewish.c julian.c easter.c cal_unix.c; do
25822
25823      IFS=.
25824      set $ac_src
25825      ac_obj=$1
25826      IFS=$old_IFS
25827
25828      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25829
25830      case $ac_src in
25831        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25832        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25833        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25834        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25835      esac
25836
25837      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25838
25839    cat >>Makefile.objects<<EOF
25840-include $ac_bdir$ac_obj.dep
25841$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25842	$ac_comp
25843EOF
25844  done
25845
25846
25847    EXT_STATIC="$EXT_STATIC calendar;$ext_dir"
25848    if test "$ext_shared" != "nocli"; then
25849      EXT_CLI_STATIC="$EXT_CLI_STATIC calendar;$ext_dir"
25850    fi
25851  else
25852    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
25853      PHP_CALENDAR_SHARED=yes
25854
25855  case $ext_dir in
25856  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25857  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25858  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25859  esac
25860
25861
25862
25863  b_c_pre=$shared_c_pre
25864  b_cxx_pre=$shared_cxx_pre
25865  b_c_meta=$shared_c_meta
25866  b_cxx_meta=$shared_cxx_meta
25867  b_c_post=$shared_c_post
25868  b_cxx_post=$shared_cxx_post
25869  b_lo=$shared_lo
25870
25871
25872  old_IFS=$IFS
25873  for ac_src in calendar.c dow.c french.c gregor.c jewish.c julian.c easter.c cal_unix.c; do
25874
25875      IFS=.
25876      set $ac_src
25877      ac_obj=$1
25878      IFS=$old_IFS
25879
25880      shared_objects_calendar="$shared_objects_calendar $ac_bdir$ac_obj.lo"
25881
25882      case $ac_src in
25883        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25884        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25885        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25886        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25887      esac
25888
25889      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25890
25891    cat >>Makefile.objects<<EOF
25892-include $ac_bdir$ac_obj.dep
25893$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25894	$ac_comp
25895EOF
25896  done
25897
25898
25899  install_modules="install-modules"
25900  suffix=la
25901
25902  case $host_alias in
25903    *aix*)
25904      additional_flags="-Wl,-G"
25905      ;;
25906  esac
25907
25908  if test "x" = "xyes"; then
25909    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/calendar.$suffix"
25910  else
25911    PHP_MODULES="$PHP_MODULES \$(phplibdir)/calendar.$suffix"
25912  fi
25913
25914  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_calendar"
25915
25916  cat >>Makefile.objects<<EOF
25917\$(phplibdir)/calendar.$suffix: $ext_builddir/calendar.$suffix
25918	\$(LIBTOOL) --mode=install cp $ext_builddir/calendar.$suffix \$(phplibdir)
25919
25920$ext_builddir/calendar.$suffix: \$(shared_objects_calendar) \$(CALENDAR_SHARED_DEPENDENCIES)
25921	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_calendar) \$(CALENDAR_SHARED_LIBADD)
25922
25923EOF
25924
25925
25926printf "%s\n" "#define COMPILE_DL_CALENDAR 1" >>confdefs.h
25927
25928    fi
25929  fi
25930
25931  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
25932    PHP_CALENDAR_SHARED=no
25933    case "$PHP_SAPI" in
25934      cgi|embed|phpdbg)
25935
25936
25937  case $ext_dir in
25938  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25939  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25940  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25941  esac
25942
25943
25944
25945  b_c_pre=$php_c_pre
25946  b_cxx_pre=$php_cxx_pre
25947  b_c_meta=$php_c_meta
25948  b_cxx_meta=$php_cxx_meta
25949  b_c_post=$php_c_post
25950  b_cxx_post=$php_cxx_post
25951  b_lo=$php_lo
25952
25953
25954  old_IFS=$IFS
25955  for ac_src in calendar.c dow.c french.c gregor.c jewish.c julian.c easter.c cal_unix.c; do
25956
25957      IFS=.
25958      set $ac_src
25959      ac_obj=$1
25960      IFS=$old_IFS
25961
25962      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
25963
25964      case $ac_src in
25965        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25966        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25967        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
25968        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
25969      esac
25970
25971      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
25972
25973    cat >>Makefile.objects<<EOF
25974-include $ac_bdir$ac_obj.dep
25975$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
25976	$ac_comp
25977EOF
25978  done
25979
25980
25981        EXT_STATIC="$EXT_STATIC calendar;$ext_dir"
25982        ;;
25983      *)
25984
25985
25986  case $ext_dir in
25987  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
25988  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
25989  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
25990  esac
25991
25992
25993
25994  b_c_pre=$php_c_pre
25995  b_cxx_pre=$php_cxx_pre
25996  b_c_meta=$php_c_meta
25997  b_cxx_meta=$php_cxx_meta
25998  b_c_post=$php_c_post
25999  b_cxx_post=$php_cxx_post
26000  b_lo=$php_lo
26001
26002
26003  old_IFS=$IFS
26004  for ac_src in calendar.c dow.c french.c gregor.c jewish.c julian.c easter.c cal_unix.c; do
26005
26006      IFS=.
26007      set $ac_src
26008      ac_obj=$1
26009      IFS=$old_IFS
26010
26011      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
26012
26013      case $ac_src in
26014        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26015        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26016        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26017        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
26018      esac
26019
26020      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
26021
26022    cat >>Makefile.objects<<EOF
26023-include $ac_bdir$ac_obj.dep
26024$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
26025	$ac_comp
26026EOF
26027  done
26028
26029
26030        ;;
26031    esac
26032    EXT_CLI_STATIC="$EXT_CLI_STATIC calendar;$ext_dir"
26033  fi
26034
26035
26036    BUILD_DIR="$BUILD_DIR $ext_builddir"
26037
26038
26039
26040  if test "$ext_builddir" = "."; then
26041    PHP_PECL_EXTENSION=calendar
26042
26043  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
26044
26045  fi
26046
26047fi
26048
26049
26050
26051
26052
26053php_enable_ctype=yes
26054
26055{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable ctype functions" >&5
26056printf %s "checking whether to enable ctype functions... " >&6; }
26057# Check whether --enable-ctype was given.
26058if test ${enable_ctype+y}
26059then :
26060  enableval=$enable_ctype; PHP_CTYPE=$enableval
26061else $as_nop
26062
26063  PHP_CTYPE=yes
26064  test "$PHP_ENABLE_ALL" && PHP_CTYPE=$PHP_ENABLE_ALL
26065
26066fi
26067
26068
26069
26070ext_output="yes, shared"
26071ext_shared=yes
26072case $PHP_CTYPE in
26073shared,*)
26074  PHP_CTYPE=`echo "$PHP_CTYPE"|$SED 's/^shared,//'`
26075  ;;
26076shared)
26077  PHP_CTYPE=yes
26078  ;;
26079no)
26080  ext_output=no
26081  ext_shared=no
26082  ;;
26083*)
26084  ext_output=yes
26085  ext_shared=no
26086  ;;
26087esac
26088
26089
26090
26091{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
26092printf "%s\n" "$ext_output" >&6; }
26093
26094
26095
26096
26097if test "$PHP_CTYPE" != "no"; then
26098
26099printf "%s\n" "#define HAVE_CTYPE 1" >>confdefs.h
26100
26101
26102  ext_builddir=ext/ctype
26103  ext_srcdir=$abs_srcdir/ext/ctype
26104  ext_dir=ext/ctype
26105
26106  ac_extra=
26107
26108  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
26109    PHP_CTYPE_SHARED=no
26110
26111
26112  case $ext_dir in
26113  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
26114  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
26115  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
26116  esac
26117
26118
26119
26120  b_c_pre=$php_c_pre
26121  b_cxx_pre=$php_cxx_pre
26122  b_c_meta=$php_c_meta
26123  b_cxx_meta=$php_cxx_meta
26124  b_c_post=$php_c_post
26125  b_cxx_post=$php_cxx_post
26126  b_lo=$php_lo
26127
26128
26129  old_IFS=$IFS
26130  for ac_src in ctype.c; do
26131
26132      IFS=.
26133      set $ac_src
26134      ac_obj=$1
26135      IFS=$old_IFS
26136
26137      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
26138
26139      case $ac_src in
26140        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26141        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26142        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26143        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
26144      esac
26145
26146      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
26147
26148    cat >>Makefile.objects<<EOF
26149-include $ac_bdir$ac_obj.dep
26150$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
26151	$ac_comp
26152EOF
26153  done
26154
26155
26156    EXT_STATIC="$EXT_STATIC ctype;$ext_dir"
26157    if test "$ext_shared" != "nocli"; then
26158      EXT_CLI_STATIC="$EXT_CLI_STATIC ctype;$ext_dir"
26159    fi
26160  else
26161    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
26162      PHP_CTYPE_SHARED=yes
26163
26164  case $ext_dir in
26165  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
26166  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
26167  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
26168  esac
26169
26170
26171
26172  b_c_pre=$shared_c_pre
26173  b_cxx_pre=$shared_cxx_pre
26174  b_c_meta=$shared_c_meta
26175  b_cxx_meta=$shared_cxx_meta
26176  b_c_post=$shared_c_post
26177  b_cxx_post=$shared_cxx_post
26178  b_lo=$shared_lo
26179
26180
26181  old_IFS=$IFS
26182  for ac_src in ctype.c; do
26183
26184      IFS=.
26185      set $ac_src
26186      ac_obj=$1
26187      IFS=$old_IFS
26188
26189      shared_objects_ctype="$shared_objects_ctype $ac_bdir$ac_obj.lo"
26190
26191      case $ac_src in
26192        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26193        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26194        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26195        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
26196      esac
26197
26198      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
26199
26200    cat >>Makefile.objects<<EOF
26201-include $ac_bdir$ac_obj.dep
26202$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
26203	$ac_comp
26204EOF
26205  done
26206
26207
26208  install_modules="install-modules"
26209  suffix=la
26210
26211  case $host_alias in
26212    *aix*)
26213      additional_flags="-Wl,-G"
26214      ;;
26215  esac
26216
26217  if test "x" = "xyes"; then
26218    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/ctype.$suffix"
26219  else
26220    PHP_MODULES="$PHP_MODULES \$(phplibdir)/ctype.$suffix"
26221  fi
26222
26223  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_ctype"
26224
26225  cat >>Makefile.objects<<EOF
26226\$(phplibdir)/ctype.$suffix: $ext_builddir/ctype.$suffix
26227	\$(LIBTOOL) --mode=install cp $ext_builddir/ctype.$suffix \$(phplibdir)
26228
26229$ext_builddir/ctype.$suffix: \$(shared_objects_ctype) \$(CTYPE_SHARED_DEPENDENCIES)
26230	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_ctype) \$(CTYPE_SHARED_LIBADD)
26231
26232EOF
26233
26234
26235printf "%s\n" "#define COMPILE_DL_CTYPE 1" >>confdefs.h
26236
26237    fi
26238  fi
26239
26240  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
26241    PHP_CTYPE_SHARED=no
26242    case "$PHP_SAPI" in
26243      cgi|embed|phpdbg)
26244
26245
26246  case $ext_dir in
26247  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
26248  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
26249  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
26250  esac
26251
26252
26253
26254  b_c_pre=$php_c_pre
26255  b_cxx_pre=$php_cxx_pre
26256  b_c_meta=$php_c_meta
26257  b_cxx_meta=$php_cxx_meta
26258  b_c_post=$php_c_post
26259  b_cxx_post=$php_cxx_post
26260  b_lo=$php_lo
26261
26262
26263  old_IFS=$IFS
26264  for ac_src in ctype.c; do
26265
26266      IFS=.
26267      set $ac_src
26268      ac_obj=$1
26269      IFS=$old_IFS
26270
26271      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
26272
26273      case $ac_src in
26274        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26275        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26276        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26277        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
26278      esac
26279
26280      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
26281
26282    cat >>Makefile.objects<<EOF
26283-include $ac_bdir$ac_obj.dep
26284$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
26285	$ac_comp
26286EOF
26287  done
26288
26289
26290        EXT_STATIC="$EXT_STATIC ctype;$ext_dir"
26291        ;;
26292      *)
26293
26294
26295  case $ext_dir in
26296  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
26297  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
26298  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
26299  esac
26300
26301
26302
26303  b_c_pre=$php_c_pre
26304  b_cxx_pre=$php_cxx_pre
26305  b_c_meta=$php_c_meta
26306  b_cxx_meta=$php_cxx_meta
26307  b_c_post=$php_c_post
26308  b_cxx_post=$php_cxx_post
26309  b_lo=$php_lo
26310
26311
26312  old_IFS=$IFS
26313  for ac_src in ctype.c; do
26314
26315      IFS=.
26316      set $ac_src
26317      ac_obj=$1
26318      IFS=$old_IFS
26319
26320      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
26321
26322      case $ac_src in
26323        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26324        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26325        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
26326        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
26327      esac
26328
26329      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
26330
26331    cat >>Makefile.objects<<EOF
26332-include $ac_bdir$ac_obj.dep
26333$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
26334	$ac_comp
26335EOF
26336  done
26337
26338
26339        ;;
26340    esac
26341    EXT_CLI_STATIC="$EXT_CLI_STATIC ctype;$ext_dir"
26342  fi
26343
26344
26345    BUILD_DIR="$BUILD_DIR $ext_builddir"
26346
26347
26348
26349  if test "$ext_builddir" = "."; then
26350    PHP_PECL_EXTENSION=ctype
26351
26352  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
26353
26354  fi
26355
26356fi
26357
26358
26359
26360
26361
26362php_with_curl=no
26363
26364{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cURL support" >&5
26365printf %s "checking for cURL support... " >&6; }
26366
26367# Check whether --with-curl was given.
26368if test ${with_curl+y}
26369then :
26370  withval=$with_curl; PHP_CURL=$withval
26371else $as_nop
26372
26373  PHP_CURL=no
26374  test "$PHP_ENABLE_ALL" && PHP_CURL=$PHP_ENABLE_ALL
26375
26376fi
26377
26378
26379
26380ext_output="yes, shared"
26381ext_shared=yes
26382case $PHP_CURL in
26383shared,*)
26384  PHP_CURL=`echo "$PHP_CURL"|$SED 's/^shared,//'`
26385  ;;
26386shared)
26387  PHP_CURL=yes
26388  ;;
26389no)
26390  ext_output=no
26391  ext_shared=no
26392  ;;
26393*)
26394  ext_output=yes
26395  ext_shared=no
26396  ;;
26397esac
26398
26399
26400
26401{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
26402printf "%s\n" "$ext_output" >&6; }
26403
26404
26405
26406
26407if test "$PHP_CURL" != "no"; then
26408
26409pkg_failed=no
26410{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libcurl >= 7.29.0" >&5
26411printf %s "checking for libcurl >= 7.29.0... " >&6; }
26412
26413if test -n "$CURL_CFLAGS"; then
26414    pkg_cv_CURL_CFLAGS="$CURL_CFLAGS"
26415 elif test -n "$PKG_CONFIG"; then
26416    if test -n "$PKG_CONFIG" && \
26417    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl >= 7.29.0\""; } >&5
26418  ($PKG_CONFIG --exists --print-errors "libcurl >= 7.29.0") 2>&5
26419  ac_status=$?
26420  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26421  test $ac_status = 0; }; then
26422  pkg_cv_CURL_CFLAGS=`$PKG_CONFIG --cflags "libcurl >= 7.29.0" 2>/dev/null`
26423		      test "x$?" != "x0" && pkg_failed=yes
26424else
26425  pkg_failed=yes
26426fi
26427 else
26428    pkg_failed=untried
26429fi
26430if test -n "$CURL_LIBS"; then
26431    pkg_cv_CURL_LIBS="$CURL_LIBS"
26432 elif test -n "$PKG_CONFIG"; then
26433    if test -n "$PKG_CONFIG" && \
26434    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl >= 7.29.0\""; } >&5
26435  ($PKG_CONFIG --exists --print-errors "libcurl >= 7.29.0") 2>&5
26436  ac_status=$?
26437  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26438  test $ac_status = 0; }; then
26439  pkg_cv_CURL_LIBS=`$PKG_CONFIG --libs "libcurl >= 7.29.0" 2>/dev/null`
26440		      test "x$?" != "x0" && pkg_failed=yes
26441else
26442  pkg_failed=yes
26443fi
26444 else
26445    pkg_failed=untried
26446fi
26447
26448
26449
26450if test $pkg_failed = yes; then
26451        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26452printf "%s\n" "no" >&6; }
26453
26454if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
26455        _pkg_short_errors_supported=yes
26456else
26457        _pkg_short_errors_supported=no
26458fi
26459        if test $_pkg_short_errors_supported = yes; then
26460	        CURL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libcurl >= 7.29.0" 2>&1`
26461        else
26462	        CURL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libcurl >= 7.29.0" 2>&1`
26463        fi
26464	# Put the nasty error message in config.log where it belongs
26465	echo "$CURL_PKG_ERRORS" >&5
26466
26467	as_fn_error $? "Package requirements (libcurl >= 7.29.0) were not met:
26468
26469$CURL_PKG_ERRORS
26470
26471Consider adjusting the PKG_CONFIG_PATH environment variable if you
26472installed software in a non-standard prefix.
26473
26474Alternatively, you may set the environment variables CURL_CFLAGS
26475and CURL_LIBS to avoid the need to call pkg-config.
26476See the pkg-config man page for more details." "$LINENO" 5
26477elif test $pkg_failed = untried; then
26478        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26479printf "%s\n" "no" >&6; }
26480	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
26481printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
26482as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
26483is in your PATH or set the PKG_CONFIG environment variable to the full
26484path to pkg-config.
26485
26486Alternatively, you may set the environment variables CURL_CFLAGS
26487and CURL_LIBS to avoid the need to call pkg-config.
26488See the pkg-config man page for more details.
26489
26490To get pkg-config, see <http://pkg-config.freedesktop.org/>.
26491See \`config.log' for more details" "$LINENO" 5; }
26492else
26493	CURL_CFLAGS=$pkg_cv_CURL_CFLAGS
26494	CURL_LIBS=$pkg_cv_CURL_LIBS
26495        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26496printf "%s\n" "yes" >&6; }
26497
26498fi
26499
26500if test -n "$CURL_FEATURES"; then
26501    pkg_cv_CURL_FEATURES="$CURL_FEATURES"
26502 elif test -n "$PKG_CONFIG"; then
26503    if test -n "$PKG_CONFIG" && \
26504    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl\""; } >&5
26505  ($PKG_CONFIG --exists --print-errors "libcurl") 2>&5
26506  ac_status=$?
26507  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26508  test $ac_status = 0; }; then
26509  pkg_cv_CURL_FEATURES=`$PKG_CONFIG --variable="supported_features" "libcurl" 2>/dev/null`
26510		      test "x$?" != "x0" && pkg_failed=yes
26511else
26512  pkg_failed=yes
26513fi
26514 else
26515    pkg_failed=untried
26516fi
26517CURL_FEATURES=$pkg_cv_CURL_FEATURES
26518
26519if test "x$CURL_FEATURES" = x""
26520then :
26521
26522fi
26523
26524
26525  for ac_i in $CURL_LIBS; do
26526    case $ac_i in
26527    -pthread)
26528      if test "$ext_shared" = "yes"; then
26529        CURL_SHARED_LIBADD="$CURL_SHARED_LIBADD -pthread"
26530      else
26531
26532
26533  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
26534
26535  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
26536  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26537    eval "EXTRA_LDFLAGS$unique=set"
26538    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
26539  fi
26540
26541
26542
26543  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
26544
26545  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
26546  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26547    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
26548    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
26549  fi
26550
26551      fi
26552    ;;
26553    -l*)
26554      ac_ii=`echo $ac_i|cut -c 3-`
26555
26556
26557  case $ac_ii in
26558  c|c_r) ;;
26559  *)
26560    if test "$ext_shared" = "yes"; then
26561        CURL_SHARED_LIBADD="$CURL_SHARED_LIBADD -l$ac_ii"
26562    else
26563
26564
26565  case $ac_ii in
26566  c|c_r) ;;
26567  *)
26568      LIBS="$LIBS -l$ac_ii"
26569   ;;
26570  esac
26571
26572
26573    fi
26574   ;;
26575  esac
26576
26577
26578    ;;
26579    -L*)
26580      ac_ii=`echo $ac_i|cut -c 3-`
26581
26582  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
26583
26584  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
26585    ai_p=$ac_ii
26586  else
26587
26588    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
26589
26590    ep_realdir=`(cd "$ep_dir" && pwd)`
26591    ai_p="$ep_realdir"/`basename "$ac_ii"`
26592  fi
26593
26594
26595      if test "$ext_shared" = "yes"; then
26596        CURL_SHARED_LIBADD="-L$ai_p $CURL_SHARED_LIBADD"
26597        test -n "$ld_runpath_switch" && CURL_SHARED_LIBADD="$ld_runpath_switch$ai_p $CURL_SHARED_LIBADD"
26598      else
26599
26600
26601
26602  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
26603
26604  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
26605  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26606    eval "LIBPATH$unique=set"
26607
26608    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
26609    LDFLAGS="$LDFLAGS -L$ai_p"
26610    PHP_RPATHS="$PHP_RPATHS $ai_p"
26611
26612  fi
26613
26614
26615      fi
26616
26617  fi
26618
26619    ;;
26620    esac
26621  done
26622
26623
26624  for ac_i in $CURL_CFLAGS; do
26625    case $ac_i in
26626    -I*)
26627      ac_ii=`echo $ac_i|cut -c 3-`
26628
26629  if test "$ac_ii" != "/usr/include"; then
26630
26631  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
26632    ai_p=$ac_ii
26633  else
26634
26635    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
26636
26637    ep_realdir=`(cd "$ep_dir" && pwd)`
26638    ai_p="$ep_realdir"/`basename "$ac_ii"`
26639  fi
26640
26641
26642
26643  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
26644
26645  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
26646  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26647    eval "INCLUDEPATH$unique=set"
26648
26649      if test ""; then
26650        INCLUDES="-I$ai_p $INCLUDES"
26651      else
26652        INCLUDES="$INCLUDES -I$ai_p"
26653      fi
26654
26655  fi
26656
26657  fi
26658
26659    ;;
26660    esac
26661  done
26662
26663
26664  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSL support in libcurl" >&5
26665printf %s "checking for SSL support in libcurl... " >&6; }
26666  case "$CURL_FEATURES" in
26667    *SSL*)
26668      CURL_SSL=yes
26669      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26670printf "%s\n" "yes" >&6; }
26671      ;;
26672    *)
26673      CURL_SSL=no
26674      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26675printf "%s\n" "no" >&6; }
26676      ;;
26677  esac
26678
26679  if test "$CURL_SSL" = yes; then
26680    save_LDFLAGS="$LDFLAGS"
26681    LDFLAGS="$LDFLAGS $CURL_LIBS"
26682
26683    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libcurl linked against old openssl" >&5
26684printf %s "checking for libcurl linked against old openssl... " >&6; }
26685    if test "$cross_compiling" = yes
26686then :
26687
26688      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26689printf "%s\n" "no" >&6; }
26690
26691else $as_nop
26692  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26693/* end confdefs.h.  */
26694
26695#include <strings.h>
26696#include <curl/curl.h>
26697
26698int main(int argc, char *argv[])
26699{
26700  curl_version_info_data *data = curl_version_info(CURLVERSION_NOW);
26701
26702  if (data && data->ssl_version && *data->ssl_version) {
26703    const char *ptr = data->ssl_version;
26704
26705    while(*ptr == ' ') ++ptr;
26706    if (strncasecmp(ptr, "OpenSSL/1.1", sizeof("OpenSSL/1.1")-1) == 0) {
26707      /* New OpenSSL version */
26708      return 3;
26709    }
26710    if (strncasecmp(ptr, "OpenSSL", sizeof("OpenSSL")-1) == 0) {
26711      /* Old OpenSSL version */
26712      return 0;
26713    }
26714    /* Different SSL library */
26715    return 2;
26716  }
26717  /* No SSL support */
26718  return 1;
26719}
26720
26721_ACEOF
26722if ac_fn_c_try_run "$LINENO"
26723then :
26724
26725      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26726printf "%s\n" "yes" >&6; }
26727
26728printf "%s\n" "#define HAVE_CURL_OLD_OPENSSL 1" >>confdefs.h
26729
26730
26731pkg_failed=no
26732{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl" >&5
26733printf %s "checking for openssl... " >&6; }
26734
26735if test -n "$OPENSSL_CFLAGS"; then
26736    pkg_cv_OPENSSL_CFLAGS="$OPENSSL_CFLAGS"
26737 elif test -n "$PKG_CONFIG"; then
26738    if test -n "$PKG_CONFIG" && \
26739    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl\""; } >&5
26740  ($PKG_CONFIG --exists --print-errors "openssl") 2>&5
26741  ac_status=$?
26742  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26743  test $ac_status = 0; }; then
26744  pkg_cv_OPENSSL_CFLAGS=`$PKG_CONFIG --cflags "openssl" 2>/dev/null`
26745		      test "x$?" != "x0" && pkg_failed=yes
26746else
26747  pkg_failed=yes
26748fi
26749 else
26750    pkg_failed=untried
26751fi
26752if test -n "$OPENSSL_LIBS"; then
26753    pkg_cv_OPENSSL_LIBS="$OPENSSL_LIBS"
26754 elif test -n "$PKG_CONFIG"; then
26755    if test -n "$PKG_CONFIG" && \
26756    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl\""; } >&5
26757  ($PKG_CONFIG --exists --print-errors "openssl") 2>&5
26758  ac_status=$?
26759  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26760  test $ac_status = 0; }; then
26761  pkg_cv_OPENSSL_LIBS=`$PKG_CONFIG --libs "openssl" 2>/dev/null`
26762		      test "x$?" != "x0" && pkg_failed=yes
26763else
26764  pkg_failed=yes
26765fi
26766 else
26767    pkg_failed=untried
26768fi
26769
26770
26771
26772if test $pkg_failed = yes; then
26773        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26774printf "%s\n" "no" >&6; }
26775
26776if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
26777        _pkg_short_errors_supported=yes
26778else
26779        _pkg_short_errors_supported=no
26780fi
26781        if test $_pkg_short_errors_supported = yes; then
26782	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openssl" 2>&1`
26783        else
26784	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openssl" 2>&1`
26785        fi
26786	# Put the nasty error message in config.log where it belongs
26787	echo "$OPENSSL_PKG_ERRORS" >&5
26788
26789	as_fn_error $? "Package requirements (openssl) were not met:
26790
26791$OPENSSL_PKG_ERRORS
26792
26793Consider adjusting the PKG_CONFIG_PATH environment variable if you
26794installed software in a non-standard prefix.
26795
26796Alternatively, you may set the environment variables OPENSSL_CFLAGS
26797and OPENSSL_LIBS to avoid the need to call pkg-config.
26798See the pkg-config man page for more details." "$LINENO" 5
26799elif test $pkg_failed = untried; then
26800        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26801printf "%s\n" "no" >&6; }
26802	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
26803printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
26804as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
26805is in your PATH or set the PKG_CONFIG environment variable to the full
26806path to pkg-config.
26807
26808Alternatively, you may set the environment variables OPENSSL_CFLAGS
26809and OPENSSL_LIBS to avoid the need to call pkg-config.
26810See the pkg-config man page for more details.
26811
26812To get pkg-config, see <http://pkg-config.freedesktop.org/>.
26813See \`config.log' for more details" "$LINENO" 5; }
26814else
26815	OPENSSL_CFLAGS=$pkg_cv_OPENSSL_CFLAGS
26816	OPENSSL_LIBS=$pkg_cv_OPENSSL_LIBS
26817        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26818printf "%s\n" "yes" >&6; }
26819
26820
26821  for ac_i in $OPENSSL_LIBS; do
26822    case $ac_i in
26823    -pthread)
26824      if test "$ext_shared" = "yes"; then
26825        CURL_SHARED_LIBADD="$CURL_SHARED_LIBADD -pthread"
26826      else
26827
26828
26829  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
26830
26831  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
26832  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26833    eval "EXTRA_LDFLAGS$unique=set"
26834    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
26835  fi
26836
26837
26838
26839  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
26840
26841  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
26842  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26843    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
26844    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
26845  fi
26846
26847      fi
26848    ;;
26849    -l*)
26850      ac_ii=`echo $ac_i|cut -c 3-`
26851
26852
26853  case $ac_ii in
26854  c|c_r) ;;
26855  *)
26856    if test "$ext_shared" = "yes"; then
26857        CURL_SHARED_LIBADD="$CURL_SHARED_LIBADD -l$ac_ii"
26858    else
26859
26860
26861  case $ac_ii in
26862  c|c_r) ;;
26863  *)
26864      LIBS="$LIBS -l$ac_ii"
26865   ;;
26866  esac
26867
26868
26869    fi
26870   ;;
26871  esac
26872
26873
26874    ;;
26875    -L*)
26876      ac_ii=`echo $ac_i|cut -c 3-`
26877
26878  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
26879
26880  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
26881    ai_p=$ac_ii
26882  else
26883
26884    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
26885
26886    ep_realdir=`(cd "$ep_dir" && pwd)`
26887    ai_p="$ep_realdir"/`basename "$ac_ii"`
26888  fi
26889
26890
26891      if test "$ext_shared" = "yes"; then
26892        CURL_SHARED_LIBADD="-L$ai_p $CURL_SHARED_LIBADD"
26893        test -n "$ld_runpath_switch" && CURL_SHARED_LIBADD="$ld_runpath_switch$ai_p $CURL_SHARED_LIBADD"
26894      else
26895
26896
26897
26898  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
26899
26900  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
26901  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26902    eval "LIBPATH$unique=set"
26903
26904    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
26905    LDFLAGS="$LDFLAGS -L$ai_p"
26906    PHP_RPATHS="$PHP_RPATHS $ai_p"
26907
26908  fi
26909
26910
26911      fi
26912
26913  fi
26914
26915    ;;
26916    esac
26917  done
26918
26919
26920  for ac_i in $OPENSSL_CFLAGS; do
26921    case $ac_i in
26922    -I*)
26923      ac_ii=`echo $ac_i|cut -c 3-`
26924
26925  if test "$ac_ii" != "/usr/include"; then
26926
26927  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
26928    ai_p=$ac_ii
26929  else
26930
26931    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
26932
26933    ep_realdir=`(cd "$ep_dir" && pwd)`
26934    ai_p="$ep_realdir"/`basename "$ac_ii"`
26935  fi
26936
26937
26938
26939  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
26940
26941  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
26942  if test -n "$unique" && test "`eval $cmd`" = "" ; then
26943    eval "INCLUDEPATH$unique=set"
26944
26945      if test ""; then
26946        INCLUDES="-I$ai_p $INCLUDES"
26947      else
26948        INCLUDES="$INCLUDES -I$ai_p"
26949      fi
26950
26951  fi
26952
26953  fi
26954
26955    ;;
26956    esac
26957  done
26958
26959        ac_fn_c_check_header_compile "$LINENO" "openssl/crypto.h" "ac_cv_header_openssl_crypto_h" "$ac_includes_default"
26960if test "x$ac_cv_header_openssl_crypto_h" = xyes
26961then :
26962  printf "%s\n" "#define HAVE_OPENSSL_CRYPTO_H 1" >>confdefs.h
26963
26964fi
26965
26966
26967fi
26968
26969else $as_nop
26970
26971      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26972printf "%s\n" "no" >&6; }
26973
26974fi
26975rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
26976  conftest.$ac_objext conftest.beam conftest.$ac_ext
26977fi
26978
26979
26980    LDFLAGS="$save_LDFLAGS"
26981  else
26982    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
26983printf "%s\n" "no" >&6; }
26984  fi
26985
26986
26987  save_old_LDFLAGS=$LDFLAGS
26988  ac_stuff="
26989    $CURL_LIBS
26990  "
26991
26992  save_ext_shared=$ext_shared
26993  ext_shared=yes
26994
26995  for ac_i in $ac_stuff; do
26996    case $ac_i in
26997    -pthread)
26998      if test "$ext_shared" = "yes"; then
26999        LDFLAGS="$LDFLAGS -pthread"
27000      else
27001
27002
27003  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
27004
27005  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
27006  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27007    eval "EXTRA_LDFLAGS$unique=set"
27008    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
27009  fi
27010
27011
27012
27013  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
27014
27015  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
27016  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27017    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
27018    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
27019  fi
27020
27021      fi
27022    ;;
27023    -l*)
27024      ac_ii=`echo $ac_i|cut -c 3-`
27025
27026
27027  case $ac_ii in
27028  c|c_r) ;;
27029  *)
27030    if test "$ext_shared" = "yes"; then
27031        LDFLAGS="$LDFLAGS -l$ac_ii"
27032    else
27033
27034
27035  case $ac_ii in
27036  c|c_r) ;;
27037  *)
27038      LIBS="$LIBS -l$ac_ii"
27039   ;;
27040  esac
27041
27042
27043    fi
27044   ;;
27045  esac
27046
27047
27048    ;;
27049    -L*)
27050      ac_ii=`echo $ac_i|cut -c 3-`
27051
27052  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
27053
27054  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
27055    ai_p=$ac_ii
27056  else
27057
27058    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
27059
27060    ep_realdir=`(cd "$ep_dir" && pwd)`
27061    ai_p="$ep_realdir"/`basename "$ac_ii"`
27062  fi
27063
27064
27065      if test "$ext_shared" = "yes"; then
27066        LDFLAGS="-L$ai_p $LDFLAGS"
27067        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
27068      else
27069
27070
27071
27072  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
27073
27074  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
27075  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27076    eval "LIBPATH$unique=set"
27077
27078    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
27079    LDFLAGS="$LDFLAGS -L$ai_p"
27080    PHP_RPATHS="$PHP_RPATHS $ai_p"
27081
27082  fi
27083
27084
27085      fi
27086
27087  fi
27088
27089    ;;
27090    esac
27091  done
27092
27093  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for curl_easy_perform in -lcurl" >&5
27094printf %s "checking for curl_easy_perform in -lcurl... " >&6; }
27095if test ${ac_cv_lib_curl_curl_easy_perform+y}
27096then :
27097  printf %s "(cached) " >&6
27098else $as_nop
27099  ac_check_lib_save_LIBS=$LIBS
27100LIBS="-lcurl  $LIBS"
27101cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27102/* end confdefs.h.  */
27103
27104/* Override any GCC internal prototype to avoid an error.
27105   Use char because int might match the return type of a GCC
27106   builtin and then its argument prototype would still apply.  */
27107char curl_easy_perform ();
27108int
27109main (void)
27110{
27111return curl_easy_perform ();
27112  ;
27113  return 0;
27114}
27115_ACEOF
27116if ac_fn_c_try_link "$LINENO"
27117then :
27118  ac_cv_lib_curl_curl_easy_perform=yes
27119else $as_nop
27120  ac_cv_lib_curl_curl_easy_perform=no
27121fi
27122rm -f core conftest.err conftest.$ac_objext conftest.beam \
27123    conftest$ac_exeext conftest.$ac_ext
27124LIBS=$ac_check_lib_save_LIBS
27125fi
27126{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curl_curl_easy_perform" >&5
27127printf "%s\n" "$ac_cv_lib_curl_curl_easy_perform" >&6; }
27128if test "x$ac_cv_lib_curl_curl_easy_perform" = xyes
27129then :
27130
27131    LDFLAGS=$save_old_LDFLAGS
27132    ext_shared=$save_ext_shared
27133
27134
27135printf "%s\n" "#define HAVE_CURL 1" >>confdefs.h
27136
27137
27138
27139else $as_nop
27140
27141    LDFLAGS=$save_old_LDFLAGS
27142    ext_shared=$save_ext_shared
27143    unset ac_cv_lib_curl_curl_easy_perform
27144
27145    as_fn_error $? "There is something wrong. Please check config.log for more information." "$LINENO" 5
27146
27147
27148fi
27149
27150
27151
27152  ext_builddir=ext/curl
27153  ext_srcdir=$abs_srcdir/ext/curl
27154  ext_dir=ext/curl
27155
27156  ac_extra=
27157
27158  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
27159    PHP_CURL_SHARED=no
27160
27161
27162  case $ext_dir in
27163  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
27164  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
27165  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
27166  esac
27167
27168
27169
27170  b_c_pre=$php_c_pre
27171  b_cxx_pre=$php_cxx_pre
27172  b_c_meta=$php_c_meta
27173  b_cxx_meta=$php_cxx_meta
27174  b_c_post=$php_c_post
27175  b_cxx_post=$php_cxx_post
27176  b_lo=$php_lo
27177
27178
27179  old_IFS=$IFS
27180  for ac_src in interface.c multi.c share.c curl_file.c; do
27181
27182      IFS=.
27183      set $ac_src
27184      ac_obj=$1
27185      IFS=$old_IFS
27186
27187      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
27188
27189      case $ac_src in
27190        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27191        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27192        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27193        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
27194      esac
27195
27196      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
27197
27198    cat >>Makefile.objects<<EOF
27199-include $ac_bdir$ac_obj.dep
27200$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
27201	$ac_comp
27202EOF
27203  done
27204
27205
27206    EXT_STATIC="$EXT_STATIC curl;$ext_dir"
27207    if test "$ext_shared" != "nocli"; then
27208      EXT_CLI_STATIC="$EXT_CLI_STATIC curl;$ext_dir"
27209    fi
27210  else
27211    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
27212      PHP_CURL_SHARED=yes
27213
27214  case $ext_dir in
27215  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
27216  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
27217  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
27218  esac
27219
27220
27221
27222  b_c_pre=$shared_c_pre
27223  b_cxx_pre=$shared_cxx_pre
27224  b_c_meta=$shared_c_meta
27225  b_cxx_meta=$shared_cxx_meta
27226  b_c_post=$shared_c_post
27227  b_cxx_post=$shared_cxx_post
27228  b_lo=$shared_lo
27229
27230
27231  old_IFS=$IFS
27232  for ac_src in interface.c multi.c share.c curl_file.c; do
27233
27234      IFS=.
27235      set $ac_src
27236      ac_obj=$1
27237      IFS=$old_IFS
27238
27239      shared_objects_curl="$shared_objects_curl $ac_bdir$ac_obj.lo"
27240
27241      case $ac_src in
27242        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27243        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27244        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27245        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
27246      esac
27247
27248      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
27249
27250    cat >>Makefile.objects<<EOF
27251-include $ac_bdir$ac_obj.dep
27252$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
27253	$ac_comp
27254EOF
27255  done
27256
27257
27258  install_modules="install-modules"
27259  suffix=la
27260
27261  case $host_alias in
27262    *aix*)
27263      additional_flags="-Wl,-G"
27264      ;;
27265  esac
27266
27267  if test "x" = "xyes"; then
27268    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/curl.$suffix"
27269  else
27270    PHP_MODULES="$PHP_MODULES \$(phplibdir)/curl.$suffix"
27271  fi
27272
27273  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_curl"
27274
27275  cat >>Makefile.objects<<EOF
27276\$(phplibdir)/curl.$suffix: $ext_builddir/curl.$suffix
27277	\$(LIBTOOL) --mode=install cp $ext_builddir/curl.$suffix \$(phplibdir)
27278
27279$ext_builddir/curl.$suffix: \$(shared_objects_curl) \$(CURL_SHARED_DEPENDENCIES)
27280	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_curl) \$(CURL_SHARED_LIBADD)
27281
27282EOF
27283
27284
27285printf "%s\n" "#define COMPILE_DL_CURL 1" >>confdefs.h
27286
27287    fi
27288  fi
27289
27290  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
27291    PHP_CURL_SHARED=no
27292    case "$PHP_SAPI" in
27293      cgi|embed|phpdbg)
27294
27295
27296  case $ext_dir in
27297  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
27298  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
27299  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
27300  esac
27301
27302
27303
27304  b_c_pre=$php_c_pre
27305  b_cxx_pre=$php_cxx_pre
27306  b_c_meta=$php_c_meta
27307  b_cxx_meta=$php_cxx_meta
27308  b_c_post=$php_c_post
27309  b_cxx_post=$php_cxx_post
27310  b_lo=$php_lo
27311
27312
27313  old_IFS=$IFS
27314  for ac_src in interface.c multi.c share.c curl_file.c; do
27315
27316      IFS=.
27317      set $ac_src
27318      ac_obj=$1
27319      IFS=$old_IFS
27320
27321      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
27322
27323      case $ac_src in
27324        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27325        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27326        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27327        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
27328      esac
27329
27330      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
27331
27332    cat >>Makefile.objects<<EOF
27333-include $ac_bdir$ac_obj.dep
27334$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
27335	$ac_comp
27336EOF
27337  done
27338
27339
27340        EXT_STATIC="$EXT_STATIC curl;$ext_dir"
27341        ;;
27342      *)
27343
27344
27345  case $ext_dir in
27346  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
27347  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
27348  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
27349  esac
27350
27351
27352
27353  b_c_pre=$php_c_pre
27354  b_cxx_pre=$php_cxx_pre
27355  b_c_meta=$php_c_meta
27356  b_cxx_meta=$php_cxx_meta
27357  b_c_post=$php_c_post
27358  b_cxx_post=$php_cxx_post
27359  b_lo=$php_lo
27360
27361
27362  old_IFS=$IFS
27363  for ac_src in interface.c multi.c share.c curl_file.c; do
27364
27365      IFS=.
27366      set $ac_src
27367      ac_obj=$1
27368      IFS=$old_IFS
27369
27370      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
27371
27372      case $ac_src in
27373        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27374        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27375        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
27376        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
27377      esac
27378
27379      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
27380
27381    cat >>Makefile.objects<<EOF
27382-include $ac_bdir$ac_obj.dep
27383$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
27384	$ac_comp
27385EOF
27386  done
27387
27388
27389        ;;
27390    esac
27391    EXT_CLI_STATIC="$EXT_CLI_STATIC curl;$ext_dir"
27392  fi
27393
27394
27395    BUILD_DIR="$BUILD_DIR $ext_builddir"
27396
27397
27398
27399  if test "$ext_builddir" = "."; then
27400    PHP_PECL_EXTENSION=curl
27401
27402  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
27403
27404  fi
27405
27406
27407
27408    header_path=ext/curl
27409    for header_file in php_curl.h; do
27410      hp_hf="$header_path/$header_file"
27411
27412
27413  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
27414
27415  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
27416  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27417    eval "INSTALLHEADERS$unique=set"
27418
27419        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
27420
27421  fi
27422
27423    done
27424
27425
27426
27427  PHP_VAR_SUBST="$PHP_VAR_SUBST CURL_SHARED_LIBADD"
27428
27429fi
27430
27431
27432
27433
27434
27435
27436
27437
27438
27439
27440
27441
27442
27443
27444
27445
27446
27447
27448php_enable_dba=no
27449
27450
27451# Check whether --enable-dba was given.
27452if test ${enable_dba+y}
27453then :
27454  enableval=$enable_dba; PHP_DBA=$enableval
27455else $as_nop
27456
27457  PHP_DBA=no
27458  test "$PHP_ENABLE_ALL" && PHP_DBA=$PHP_ENABLE_ALL
27459
27460fi
27461
27462
27463
27464ext_output="yes, shared"
27465ext_shared=yes
27466case $PHP_DBA in
27467shared,*)
27468  PHP_DBA=`echo "$PHP_DBA"|$SED 's/^shared,//'`
27469  ;;
27470shared)
27471  PHP_DBA=yes
27472  ;;
27473no)
27474  ext_output=no
27475  ext_shared=no
27476  ;;
27477*)
27478  ext_output=yes
27479  ext_shared=no
27480  ;;
27481esac
27482
27483
27484
27485
27486
27487
27488
27489
27490
27491php_with_qdbm=no
27492
27493
27494
27495# Check whether --with-qdbm was given.
27496if test ${with_qdbm+y}
27497then :
27498  withval=$with_qdbm; PHP_QDBM=$withval
27499else $as_nop
27500
27501  PHP_QDBM=no
27502
27503
27504fi
27505
27506
27507ext_output=$PHP_QDBM
27508
27509
27510
27511
27512
27513
27514php_with_gdbm=no
27515
27516
27517
27518# Check whether --with-gdbm was given.
27519if test ${with_gdbm+y}
27520then :
27521  withval=$with_gdbm; PHP_GDBM=$withval
27522else $as_nop
27523
27524  PHP_GDBM=no
27525
27526
27527fi
27528
27529
27530ext_output=$PHP_GDBM
27531
27532
27533
27534
27535
27536
27537php_with_ndbm=no
27538
27539
27540
27541# Check whether --with-ndbm was given.
27542if test ${with_ndbm+y}
27543then :
27544  withval=$with_ndbm; PHP_NDBM=$withval
27545else $as_nop
27546
27547  PHP_NDBM=no
27548
27549
27550fi
27551
27552
27553ext_output=$PHP_NDBM
27554
27555
27556
27557
27558
27559
27560php_with_db4=no
27561
27562
27563
27564# Check whether --with-db4 was given.
27565if test ${with_db4+y}
27566then :
27567  withval=$with_db4; PHP_DB4=$withval
27568else $as_nop
27569
27570  PHP_DB4=no
27571
27572
27573fi
27574
27575
27576ext_output=$PHP_DB4
27577
27578
27579
27580
27581
27582
27583php_with_db3=no
27584
27585
27586
27587# Check whether --with-db3 was given.
27588if test ${with_db3+y}
27589then :
27590  withval=$with_db3; PHP_DB3=$withval
27591else $as_nop
27592
27593  PHP_DB3=no
27594
27595
27596fi
27597
27598
27599ext_output=$PHP_DB3
27600
27601
27602
27603
27604
27605
27606php_with_db2=no
27607
27608
27609
27610# Check whether --with-db2 was given.
27611if test ${with_db2+y}
27612then :
27613  withval=$with_db2; PHP_DB2=$withval
27614else $as_nop
27615
27616  PHP_DB2=no
27617
27618
27619fi
27620
27621
27622ext_output=$PHP_DB2
27623
27624
27625
27626
27627
27628
27629php_with_db1=no
27630
27631
27632
27633# Check whether --with-db1 was given.
27634if test ${with_db1+y}
27635then :
27636  withval=$with_db1; PHP_DB1=$withval
27637else $as_nop
27638
27639  PHP_DB1=no
27640
27641
27642fi
27643
27644
27645ext_output=$PHP_DB1
27646
27647
27648
27649
27650
27651
27652php_with_dbm=no
27653
27654
27655
27656# Check whether --with-dbm was given.
27657if test ${with_dbm+y}
27658then :
27659  withval=$with_dbm; PHP_DBM=$withval
27660else $as_nop
27661
27662  PHP_DBM=no
27663
27664
27665fi
27666
27667
27668ext_output=$PHP_DBM
27669
27670
27671
27672
27673
27674
27675php_with_tcadb=no
27676
27677
27678
27679# Check whether --with-tcadb was given.
27680if test ${with_tcadb+y}
27681then :
27682  withval=$with_tcadb; PHP_TCADB=$withval
27683else $as_nop
27684
27685  PHP_TCADB=no
27686
27687
27688fi
27689
27690
27691ext_output=$PHP_TCADB
27692
27693
27694
27695
27696
27697
27698php_with_lmdb=no
27699
27700
27701
27702# Check whether --with-lmdb was given.
27703if test ${with_lmdb+y}
27704then :
27705  withval=$with_lmdb; PHP_LMDB=$withval
27706else $as_nop
27707
27708  PHP_LMDB=no
27709
27710
27711fi
27712
27713
27714ext_output=$PHP_LMDB
27715
27716
27717
27718
27719
27720
27721if test "$PHP_QDBM" != "no"; then
27722
27723  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
27724
27725  for i in $PHP_QDBM /usr/local /usr; do
27726    if test -f "$i/include/depot.h"; then
27727      THIS_PREFIX=$i
27728      THIS_INCLUDE=$i/include/depot.h
27729      break
27730    elif test -f "$i/include/qdbm/depot.h"; then
27731      THIS_PREFIX=$i
27732      THIS_INCLUDE=$i/include/qdbm/depot.h
27733      break
27734    fi
27735  done
27736
27737  if test -n "$THIS_INCLUDE"; then
27738    for LIB in qdbm; do
27739
27740  save_old_LDFLAGS=$LDFLAGS
27741  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
27742
27743  save_ext_shared=$ext_shared
27744  ext_shared=yes
27745
27746  for ac_i in $ac_stuff; do
27747    case $ac_i in
27748    -pthread)
27749      if test "$ext_shared" = "yes"; then
27750        LDFLAGS="$LDFLAGS -pthread"
27751      else
27752
27753
27754  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
27755
27756  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
27757  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27758    eval "EXTRA_LDFLAGS$unique=set"
27759    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
27760  fi
27761
27762
27763
27764  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
27765
27766  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
27767  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27768    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
27769    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
27770  fi
27771
27772      fi
27773    ;;
27774    -l*)
27775      ac_ii=`echo $ac_i|cut -c 3-`
27776
27777
27778  case $ac_ii in
27779  c|c_r) ;;
27780  *)
27781    if test "$ext_shared" = "yes"; then
27782        LDFLAGS="$LDFLAGS -l$ac_ii"
27783    else
27784
27785
27786  case $ac_ii in
27787  c|c_r) ;;
27788  *)
27789      LIBS="$LIBS -l$ac_ii"
27790   ;;
27791  esac
27792
27793
27794    fi
27795   ;;
27796  esac
27797
27798
27799    ;;
27800    -L*)
27801      ac_ii=`echo $ac_i|cut -c 3-`
27802
27803  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
27804
27805  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
27806    ai_p=$ac_ii
27807  else
27808
27809    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
27810
27811    ep_realdir=`(cd "$ep_dir" && pwd)`
27812    ai_p="$ep_realdir"/`basename "$ac_ii"`
27813  fi
27814
27815
27816      if test "$ext_shared" = "yes"; then
27817        LDFLAGS="-L$ai_p $LDFLAGS"
27818        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
27819      else
27820
27821
27822
27823  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
27824
27825  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
27826  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27827    eval "LIBPATH$unique=set"
27828
27829    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
27830    LDFLAGS="$LDFLAGS -L$ai_p"
27831    PHP_RPATHS="$PHP_RPATHS $ai_p"
27832
27833  fi
27834
27835
27836      fi
27837
27838  fi
27839
27840    ;;
27841    esac
27842  done
27843
27844  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_dpopen" | $as_tr_sh`
27845{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dpopen in -l$LIB" >&5
27846printf %s "checking for dpopen in -l$LIB... " >&6; }
27847if eval test \${$as_ac_Lib+y}
27848then :
27849  printf %s "(cached) " >&6
27850else $as_nop
27851  ac_check_lib_save_LIBS=$LIBS
27852LIBS="-l$LIB  $LIBS"
27853cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27854/* end confdefs.h.  */
27855
27856/* Override any GCC internal prototype to avoid an error.
27857   Use char because int might match the return type of a GCC
27858   builtin and then its argument prototype would still apply.  */
27859char dpopen ();
27860int
27861main (void)
27862{
27863return dpopen ();
27864  ;
27865  return 0;
27866}
27867_ACEOF
27868if ac_fn_c_try_link "$LINENO"
27869then :
27870  eval "$as_ac_Lib=yes"
27871else $as_nop
27872  eval "$as_ac_Lib=no"
27873fi
27874rm -f core conftest.err conftest.$ac_objext conftest.beam \
27875    conftest$ac_exeext conftest.$ac_ext
27876LIBS=$ac_check_lib_save_LIBS
27877fi
27878eval ac_res=\$$as_ac_Lib
27879	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
27880printf "%s\n" "$ac_res" >&6; }
27881if eval test \"x\$"$as_ac_Lib"\" = x"yes"
27882then :
27883
27884    LDFLAGS=$save_old_LDFLAGS
27885    ext_shared=$save_ext_shared
27886
27887
27888printf "%s\n" "#define QDBM_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
27889
27890
27891printf "%s\n" "#define DBA_QDBM 1" >>confdefs.h
27892
27893        THIS_LIBS=$LIB
27894
27895
27896else $as_nop
27897
27898    LDFLAGS=$save_old_LDFLAGS
27899    ext_shared=$save_ext_shared
27900    unset ac_cv_lib_$LIB_dpopen
27901
27902
27903fi
27904
27905      if test -n "$THIS_LIBS"; then
27906        break
27907      fi
27908    done
27909  fi
27910
27911
27912  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
27913    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
27914  fi
27915
27916
27917  THIS_RESULT=yes
27918  if test -z "$THIS_INCLUDE"; then
27919    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
27920  fi
27921  if test -z "$THIS_LIBS"; then
27922    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
27923  fi
27924
27925
27926
27927
27928  if test "$ext_shared" = "yes"; then
27929    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
27930    if test -n "$THIS_LFLAGS"; then
27931
27932  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
27933
27934  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
27935    ai_p=$THIS_LFLAGS
27936  else
27937
27938    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
27939
27940    ep_realdir=`(cd "$ep_dir" && pwd)`
27941    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
27942  fi
27943
27944
27945      if test "$ext_shared" = "yes"; then
27946        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
27947        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
27948      else
27949
27950
27951
27952  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
27953
27954  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
27955  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27956    eval "LIBPATH$unique=set"
27957
27958    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
27959    LDFLAGS="$LDFLAGS -L$ai_p"
27960    PHP_RPATHS="$PHP_RPATHS $ai_p"
27961
27962  fi
27963
27964
27965      fi
27966
27967  fi
27968
27969    fi
27970  else
27971
27972
27973  if test -n "$THIS_LFLAGS"; then
27974
27975  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
27976
27977  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
27978    ai_p=$THIS_LFLAGS
27979  else
27980
27981    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
27982
27983    ep_realdir=`(cd "$ep_dir" && pwd)`
27984    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
27985  fi
27986
27987
27988
27989
27990
27991  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
27992
27993  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
27994  if test -n "$unique" && test "`eval $cmd`" = "" ; then
27995    eval "LIBPATH$unique=set"
27996
27997    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
27998    LDFLAGS="$LDFLAGS -L$ai_p"
27999    PHP_RPATHS="$PHP_RPATHS $ai_p"
28000
28001  fi
28002
28003
28004
28005  fi
28006
28007  fi
28008
28009
28010  case $THIS_LIBS in
28011  c|c_r) ;;
28012  *)
28013      LIBS="-l$THIS_LIBS $LIBS"
28014   ;;
28015  esac
28016
28017
28018
28019
28020  fi
28021
28022
28023  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
28024
28025fi
28026
28027  THIS_NAME=QDBM
28028  if test -n ""; then
28029    THIS_FULL_NAME=""
28030  else
28031    THIS_FULL_NAME="$THIS_NAME"
28032  fi
28033  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
28034printf %s "checking for $THIS_FULL_NAME support... " >&6; }
28035  if test -n ""; then
28036    as_fn_error $? "" "$LINENO" 5
28037  fi
28038  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
28039    HAVE_DBA=1
28040    eval HAVE_$THIS_NAME=1
28041    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
28042printf "%s\n" "$THIS_RESULT" >&6; }
28043  else
28044    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
28045printf "%s\n" "no" >&6; }
28046  fi
28047  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
28048
28049
28050if test "$PHP_GDBM" != "no"; then
28051
28052  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
28053
28054  if test "$HAVE_QDBM" = "1"; then
28055
28056  THIS_NAME=GDBM
28057  if test -n "gdbm"; then
28058    THIS_FULL_NAME="gdbm"
28059  else
28060    THIS_FULL_NAME="$THIS_NAME"
28061  fi
28062  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
28063printf %s "checking for $THIS_FULL_NAME support... " >&6; }
28064  if test -n "You cannot combine --with-gdbm with --with-qdbm"; then
28065    as_fn_error $? "You cannot combine --with-gdbm with --with-qdbm" "$LINENO" 5
28066  fi
28067  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
28068    HAVE_DBA=1
28069    eval HAVE_$THIS_NAME=1
28070    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
28071printf "%s\n" "$THIS_RESULT" >&6; }
28072  else
28073    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
28074printf "%s\n" "no" >&6; }
28075  fi
28076  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
28077
28078  fi
28079  for i in $PHP_GDBM /usr/local /usr; do
28080    if test -f "$i/include/gdbm.h"; then
28081      THIS_PREFIX=$i
28082      THIS_INCLUDE=$i/include/gdbm.h
28083      break
28084    fi
28085  done
28086
28087  if test -n "$THIS_INCLUDE"; then
28088
28089  save_old_LDFLAGS=$LDFLAGS
28090  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
28091
28092  save_ext_shared=$ext_shared
28093  ext_shared=yes
28094
28095  for ac_i in $ac_stuff; do
28096    case $ac_i in
28097    -pthread)
28098      if test "$ext_shared" = "yes"; then
28099        LDFLAGS="$LDFLAGS -pthread"
28100      else
28101
28102
28103  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28104
28105  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
28106  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28107    eval "EXTRA_LDFLAGS$unique=set"
28108    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
28109  fi
28110
28111
28112
28113  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28114
28115  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
28116  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28117    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
28118    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
28119  fi
28120
28121      fi
28122    ;;
28123    -l*)
28124      ac_ii=`echo $ac_i|cut -c 3-`
28125
28126
28127  case $ac_ii in
28128  c|c_r) ;;
28129  *)
28130    if test "$ext_shared" = "yes"; then
28131        LDFLAGS="$LDFLAGS -l$ac_ii"
28132    else
28133
28134
28135  case $ac_ii in
28136  c|c_r) ;;
28137  *)
28138      LIBS="$LIBS -l$ac_ii"
28139   ;;
28140  esac
28141
28142
28143    fi
28144   ;;
28145  esac
28146
28147
28148    ;;
28149    -L*)
28150      ac_ii=`echo $ac_i|cut -c 3-`
28151
28152  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
28153
28154  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
28155    ai_p=$ac_ii
28156  else
28157
28158    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
28159
28160    ep_realdir=`(cd "$ep_dir" && pwd)`
28161    ai_p="$ep_realdir"/`basename "$ac_ii"`
28162  fi
28163
28164
28165      if test "$ext_shared" = "yes"; then
28166        LDFLAGS="-L$ai_p $LDFLAGS"
28167        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
28168      else
28169
28170
28171
28172  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28173
28174  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28175  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28176    eval "LIBPATH$unique=set"
28177
28178    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28179    LDFLAGS="$LDFLAGS -L$ai_p"
28180    PHP_RPATHS="$PHP_RPATHS $ai_p"
28181
28182  fi
28183
28184
28185      fi
28186
28187  fi
28188
28189    ;;
28190    esac
28191  done
28192
28193  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdbm_open in -lgdbm" >&5
28194printf %s "checking for gdbm_open in -lgdbm... " >&6; }
28195if test ${ac_cv_lib_gdbm_gdbm_open+y}
28196then :
28197  printf %s "(cached) " >&6
28198else $as_nop
28199  ac_check_lib_save_LIBS=$LIBS
28200LIBS="-lgdbm  $LIBS"
28201cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28202/* end confdefs.h.  */
28203
28204/* Override any GCC internal prototype to avoid an error.
28205   Use char because int might match the return type of a GCC
28206   builtin and then its argument prototype would still apply.  */
28207char gdbm_open ();
28208int
28209main (void)
28210{
28211return gdbm_open ();
28212  ;
28213  return 0;
28214}
28215_ACEOF
28216if ac_fn_c_try_link "$LINENO"
28217then :
28218  ac_cv_lib_gdbm_gdbm_open=yes
28219else $as_nop
28220  ac_cv_lib_gdbm_gdbm_open=no
28221fi
28222rm -f core conftest.err conftest.$ac_objext conftest.beam \
28223    conftest$ac_exeext conftest.$ac_ext
28224LIBS=$ac_check_lib_save_LIBS
28225fi
28226{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gdbm_gdbm_open" >&5
28227printf "%s\n" "$ac_cv_lib_gdbm_gdbm_open" >&6; }
28228if test "x$ac_cv_lib_gdbm_gdbm_open" = xyes
28229then :
28230
28231    LDFLAGS=$save_old_LDFLAGS
28232    ext_shared=$save_ext_shared
28233
28234
28235printf "%s\n" "#define GDBM_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
28236
28237
28238printf "%s\n" "#define DBA_GDBM 1" >>confdefs.h
28239
28240      THIS_LIBS=gdbm
28241
28242
28243else $as_nop
28244
28245    LDFLAGS=$save_old_LDFLAGS
28246    ext_shared=$save_ext_shared
28247    unset ac_cv_lib_gdbm_gdbm_open
28248
28249
28250fi
28251
28252  fi
28253
28254
28255  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
28256    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
28257  fi
28258
28259
28260  THIS_RESULT=yes
28261  if test -z "$THIS_INCLUDE"; then
28262    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
28263  fi
28264  if test -z "$THIS_LIBS"; then
28265    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
28266  fi
28267
28268
28269
28270
28271  if test "$ext_shared" = "yes"; then
28272    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
28273    if test -n "$THIS_LFLAGS"; then
28274
28275  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
28276
28277  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
28278    ai_p=$THIS_LFLAGS
28279  else
28280
28281    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
28282
28283    ep_realdir=`(cd "$ep_dir" && pwd)`
28284    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
28285  fi
28286
28287
28288      if test "$ext_shared" = "yes"; then
28289        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
28290        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
28291      else
28292
28293
28294
28295  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28296
28297  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28298  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28299    eval "LIBPATH$unique=set"
28300
28301    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28302    LDFLAGS="$LDFLAGS -L$ai_p"
28303    PHP_RPATHS="$PHP_RPATHS $ai_p"
28304
28305  fi
28306
28307
28308      fi
28309
28310  fi
28311
28312    fi
28313  else
28314
28315
28316  if test -n "$THIS_LFLAGS"; then
28317
28318  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
28319
28320  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
28321    ai_p=$THIS_LFLAGS
28322  else
28323
28324    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
28325
28326    ep_realdir=`(cd "$ep_dir" && pwd)`
28327    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
28328  fi
28329
28330
28331
28332
28333
28334  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28335
28336  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28337  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28338    eval "LIBPATH$unique=set"
28339
28340    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28341    LDFLAGS="$LDFLAGS -L$ai_p"
28342    PHP_RPATHS="$PHP_RPATHS $ai_p"
28343
28344  fi
28345
28346
28347
28348  fi
28349
28350  fi
28351
28352
28353  case $THIS_LIBS in
28354  c|c_r) ;;
28355  *)
28356      LIBS="-l$THIS_LIBS $LIBS"
28357   ;;
28358  esac
28359
28360
28361
28362
28363  fi
28364
28365
28366  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
28367
28368fi
28369
28370  THIS_NAME=GDBM
28371  if test -n ""; then
28372    THIS_FULL_NAME=""
28373  else
28374    THIS_FULL_NAME="$THIS_NAME"
28375  fi
28376  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
28377printf %s "checking for $THIS_FULL_NAME support... " >&6; }
28378  if test -n ""; then
28379    as_fn_error $? "" "$LINENO" 5
28380  fi
28381  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
28382    HAVE_DBA=1
28383    eval HAVE_$THIS_NAME=1
28384    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
28385printf "%s\n" "$THIS_RESULT" >&6; }
28386  else
28387    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
28388printf "%s\n" "no" >&6; }
28389  fi
28390  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
28391
28392
28393if test "$PHP_NDBM" != "no"; then
28394
28395  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
28396
28397  for i in $PHP_NDBM /usr/local /usr; do
28398    if test -f "$i/include/ndbm.h"; then
28399      THIS_PREFIX=$i
28400      THIS_INCLUDE=$i/include/ndbm.h
28401      break
28402    elif test -f "$i/include/db1/ndbm.h"; then
28403      THIS_PREFIX=$i
28404      THIS_INCLUDE=$i/include/db1/ndbm.h
28405      break
28406    fi
28407  done
28408
28409  if test -n "$THIS_INCLUDE"; then
28410    for LIB in ndbm db1 c; do
28411
28412  save_old_LDFLAGS=$LDFLAGS
28413  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
28414
28415  save_ext_shared=$ext_shared
28416  ext_shared=yes
28417
28418  for ac_i in $ac_stuff; do
28419    case $ac_i in
28420    -pthread)
28421      if test "$ext_shared" = "yes"; then
28422        LDFLAGS="$LDFLAGS -pthread"
28423      else
28424
28425
28426  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28427
28428  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
28429  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28430    eval "EXTRA_LDFLAGS$unique=set"
28431    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
28432  fi
28433
28434
28435
28436  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28437
28438  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
28439  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28440    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
28441    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
28442  fi
28443
28444      fi
28445    ;;
28446    -l*)
28447      ac_ii=`echo $ac_i|cut -c 3-`
28448
28449
28450  case $ac_ii in
28451  c|c_r) ;;
28452  *)
28453    if test "$ext_shared" = "yes"; then
28454        LDFLAGS="$LDFLAGS -l$ac_ii"
28455    else
28456
28457
28458  case $ac_ii in
28459  c|c_r) ;;
28460  *)
28461      LIBS="$LIBS -l$ac_ii"
28462   ;;
28463  esac
28464
28465
28466    fi
28467   ;;
28468  esac
28469
28470
28471    ;;
28472    -L*)
28473      ac_ii=`echo $ac_i|cut -c 3-`
28474
28475  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
28476
28477  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
28478    ai_p=$ac_ii
28479  else
28480
28481    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
28482
28483    ep_realdir=`(cd "$ep_dir" && pwd)`
28484    ai_p="$ep_realdir"/`basename "$ac_ii"`
28485  fi
28486
28487
28488      if test "$ext_shared" = "yes"; then
28489        LDFLAGS="-L$ai_p $LDFLAGS"
28490        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
28491      else
28492
28493
28494
28495  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28496
28497  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28498  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28499    eval "LIBPATH$unique=set"
28500
28501    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28502    LDFLAGS="$LDFLAGS -L$ai_p"
28503    PHP_RPATHS="$PHP_RPATHS $ai_p"
28504
28505  fi
28506
28507
28508      fi
28509
28510  fi
28511
28512    ;;
28513    esac
28514  done
28515
28516  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_dbm_open" | $as_tr_sh`
28517{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dbm_open in -l$LIB" >&5
28518printf %s "checking for dbm_open in -l$LIB... " >&6; }
28519if eval test \${$as_ac_Lib+y}
28520then :
28521  printf %s "(cached) " >&6
28522else $as_nop
28523  ac_check_lib_save_LIBS=$LIBS
28524LIBS="-l$LIB  $LIBS"
28525cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28526/* end confdefs.h.  */
28527
28528/* Override any GCC internal prototype to avoid an error.
28529   Use char because int might match the return type of a GCC
28530   builtin and then its argument prototype would still apply.  */
28531char dbm_open ();
28532int
28533main (void)
28534{
28535return dbm_open ();
28536  ;
28537  return 0;
28538}
28539_ACEOF
28540if ac_fn_c_try_link "$LINENO"
28541then :
28542  eval "$as_ac_Lib=yes"
28543else $as_nop
28544  eval "$as_ac_Lib=no"
28545fi
28546rm -f core conftest.err conftest.$ac_objext conftest.beam \
28547    conftest$ac_exeext conftest.$ac_ext
28548LIBS=$ac_check_lib_save_LIBS
28549fi
28550eval ac_res=\$$as_ac_Lib
28551	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
28552printf "%s\n" "$ac_res" >&6; }
28553if eval test \"x\$"$as_ac_Lib"\" = x"yes"
28554then :
28555
28556    LDFLAGS=$save_old_LDFLAGS
28557    ext_shared=$save_ext_shared
28558
28559
28560printf "%s\n" "#define NDBM_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
28561
28562
28563printf "%s\n" "#define DBA_NDBM 1" >>confdefs.h
28564
28565        THIS_LIBS=$LIB
28566
28567
28568else $as_nop
28569
28570    LDFLAGS=$save_old_LDFLAGS
28571    ext_shared=$save_ext_shared
28572    unset ac_cv_lib_$LIB_dbm_open
28573
28574
28575fi
28576
28577      if test -n "$THIS_LIBS"; then
28578        break
28579      fi
28580    done
28581  fi
28582
28583
28584  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
28585    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
28586  fi
28587
28588
28589  THIS_RESULT=yes
28590  if test -z "$THIS_INCLUDE"; then
28591    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
28592  fi
28593  if test -z "$THIS_LIBS"; then
28594    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
28595  fi
28596
28597
28598
28599
28600  if test "$ext_shared" = "yes"; then
28601    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
28602    if test -n "$THIS_LFLAGS"; then
28603
28604  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
28605
28606  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
28607    ai_p=$THIS_LFLAGS
28608  else
28609
28610    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
28611
28612    ep_realdir=`(cd "$ep_dir" && pwd)`
28613    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
28614  fi
28615
28616
28617      if test "$ext_shared" = "yes"; then
28618        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
28619        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
28620      else
28621
28622
28623
28624  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28625
28626  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28627  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28628    eval "LIBPATH$unique=set"
28629
28630    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28631    LDFLAGS="$LDFLAGS -L$ai_p"
28632    PHP_RPATHS="$PHP_RPATHS $ai_p"
28633
28634  fi
28635
28636
28637      fi
28638
28639  fi
28640
28641    fi
28642  else
28643
28644
28645  if test -n "$THIS_LFLAGS"; then
28646
28647  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
28648
28649  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
28650    ai_p=$THIS_LFLAGS
28651  else
28652
28653    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
28654
28655    ep_realdir=`(cd "$ep_dir" && pwd)`
28656    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
28657  fi
28658
28659
28660
28661
28662
28663  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28664
28665  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28666  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28667    eval "LIBPATH$unique=set"
28668
28669    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28670    LDFLAGS="$LDFLAGS -L$ai_p"
28671    PHP_RPATHS="$PHP_RPATHS $ai_p"
28672
28673  fi
28674
28675
28676
28677  fi
28678
28679  fi
28680
28681
28682  case $THIS_LIBS in
28683  c|c_r) ;;
28684  *)
28685      LIBS="-l$THIS_LIBS $LIBS"
28686   ;;
28687  esac
28688
28689
28690
28691
28692  fi
28693
28694
28695  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
28696
28697fi
28698
28699  THIS_NAME=NDBM
28700  if test -n ""; then
28701    THIS_FULL_NAME=""
28702  else
28703    THIS_FULL_NAME="$THIS_NAME"
28704  fi
28705  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
28706printf %s "checking for $THIS_FULL_NAME support... " >&6; }
28707  if test -n ""; then
28708    as_fn_error $? "" "$LINENO" 5
28709  fi
28710  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
28711    HAVE_DBA=1
28712    eval HAVE_$THIS_NAME=1
28713    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
28714printf "%s\n" "$THIS_RESULT" >&6; }
28715  else
28716    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
28717printf "%s\n" "no" >&6; }
28718  fi
28719  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
28720
28721
28722if test "$PHP_TCADB" != "no"; then
28723
28724  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
28725
28726  for i in $PHP_TCADB /usr/local /usr; do
28727	if test -f "$i/include/tcadb.h"; then
28728	  THIS_PREFIX=$i
28729
28730  if test "$THIS_PREFIX/include" != "/usr/include"; then
28731
28732  if test -z "$THIS_PREFIX/include" || echo "$THIS_PREFIX/include" | grep '^/' >/dev/null ; then
28733    ai_p=$THIS_PREFIX/include
28734  else
28735
28736    ep_dir=`echo $THIS_PREFIX/include|$SED 's%/*[^/][^/]*/*$%%'`
28737
28738    ep_realdir=`(cd "$ep_dir" && pwd)`
28739    ai_p="$ep_realdir"/`basename "$THIS_PREFIX/include"`
28740  fi
28741
28742
28743
28744  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28745
28746  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
28747  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28748    eval "INCLUDEPATH$unique=set"
28749
28750      if test ""; then
28751        INCLUDES="-I$ai_p $INCLUDES"
28752      else
28753        INCLUDES="$INCLUDES -I$ai_p"
28754      fi
28755
28756  fi
28757
28758  fi
28759
28760	  THIS_INCLUDE=$i/include/tcadb.h
28761	  break
28762	fi
28763  done
28764
28765  if test -n "$THIS_INCLUDE"; then
28766	for LIB in tokyocabinet; do
28767
28768  save_old_LDFLAGS=$LDFLAGS
28769  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
28770
28771  save_ext_shared=$ext_shared
28772  ext_shared=yes
28773
28774  for ac_i in $ac_stuff; do
28775    case $ac_i in
28776    -pthread)
28777      if test "$ext_shared" = "yes"; then
28778        LDFLAGS="$LDFLAGS -pthread"
28779      else
28780
28781
28782  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28783
28784  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
28785  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28786    eval "EXTRA_LDFLAGS$unique=set"
28787    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
28788  fi
28789
28790
28791
28792  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
28793
28794  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
28795  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28796    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
28797    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
28798  fi
28799
28800      fi
28801    ;;
28802    -l*)
28803      ac_ii=`echo $ac_i|cut -c 3-`
28804
28805
28806  case $ac_ii in
28807  c|c_r) ;;
28808  *)
28809    if test "$ext_shared" = "yes"; then
28810        LDFLAGS="$LDFLAGS -l$ac_ii"
28811    else
28812
28813
28814  case $ac_ii in
28815  c|c_r) ;;
28816  *)
28817      LIBS="$LIBS -l$ac_ii"
28818   ;;
28819  esac
28820
28821
28822    fi
28823   ;;
28824  esac
28825
28826
28827    ;;
28828    -L*)
28829      ac_ii=`echo $ac_i|cut -c 3-`
28830
28831  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
28832
28833  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
28834    ai_p=$ac_ii
28835  else
28836
28837    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
28838
28839    ep_realdir=`(cd "$ep_dir" && pwd)`
28840    ai_p="$ep_realdir"/`basename "$ac_ii"`
28841  fi
28842
28843
28844      if test "$ext_shared" = "yes"; then
28845        LDFLAGS="-L$ai_p $LDFLAGS"
28846        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
28847      else
28848
28849
28850
28851  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28852
28853  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28854  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28855    eval "LIBPATH$unique=set"
28856
28857    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28858    LDFLAGS="$LDFLAGS -L$ai_p"
28859    PHP_RPATHS="$PHP_RPATHS $ai_p"
28860
28861  fi
28862
28863
28864      fi
28865
28866  fi
28867
28868    ;;
28869    esac
28870  done
28871
28872  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_tcadbopen" | $as_tr_sh`
28873{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tcadbopen in -l$LIB" >&5
28874printf %s "checking for tcadbopen in -l$LIB... " >&6; }
28875if eval test \${$as_ac_Lib+y}
28876then :
28877  printf %s "(cached) " >&6
28878else $as_nop
28879  ac_check_lib_save_LIBS=$LIBS
28880LIBS="-l$LIB  $LIBS"
28881cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28882/* end confdefs.h.  */
28883
28884/* Override any GCC internal prototype to avoid an error.
28885   Use char because int might match the return type of a GCC
28886   builtin and then its argument prototype would still apply.  */
28887char tcadbopen ();
28888int
28889main (void)
28890{
28891return tcadbopen ();
28892  ;
28893  return 0;
28894}
28895_ACEOF
28896if ac_fn_c_try_link "$LINENO"
28897then :
28898  eval "$as_ac_Lib=yes"
28899else $as_nop
28900  eval "$as_ac_Lib=no"
28901fi
28902rm -f core conftest.err conftest.$ac_objext conftest.beam \
28903    conftest$ac_exeext conftest.$ac_ext
28904LIBS=$ac_check_lib_save_LIBS
28905fi
28906eval ac_res=\$$as_ac_Lib
28907	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
28908printf "%s\n" "$ac_res" >&6; }
28909if eval test \"x\$"$as_ac_Lib"\" = x"yes"
28910then :
28911
28912    LDFLAGS=$save_old_LDFLAGS
28913    ext_shared=$save_ext_shared
28914
28915
28916printf "%s\n" "#define TCADB_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
28917
28918
28919printf "%s\n" "#define DBA_TCADB 1" >>confdefs.h
28920
28921		THIS_LIBS=$LIB
28922
28923
28924else $as_nop
28925
28926    LDFLAGS=$save_old_LDFLAGS
28927    ext_shared=$save_ext_shared
28928    unset ac_cv_lib_$LIB_tcadbopen
28929
28930
28931fi
28932
28933	  if test -n "$THIS_LIBS"; then
28934		break
28935	  fi
28936	done
28937  fi
28938
28939
28940  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
28941    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
28942  fi
28943
28944
28945  THIS_RESULT=yes
28946  if test -z "$THIS_INCLUDE"; then
28947    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
28948  fi
28949  if test -z "$THIS_LIBS"; then
28950    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
28951  fi
28952
28953
28954
28955
28956  if test "$ext_shared" = "yes"; then
28957    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
28958    if test -n "$THIS_LFLAGS"; then
28959
28960  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
28961
28962  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
28963    ai_p=$THIS_LFLAGS
28964  else
28965
28966    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
28967
28968    ep_realdir=`(cd "$ep_dir" && pwd)`
28969    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
28970  fi
28971
28972
28973      if test "$ext_shared" = "yes"; then
28974        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
28975        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
28976      else
28977
28978
28979
28980  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
28981
28982  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
28983  if test -n "$unique" && test "`eval $cmd`" = "" ; then
28984    eval "LIBPATH$unique=set"
28985
28986    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
28987    LDFLAGS="$LDFLAGS -L$ai_p"
28988    PHP_RPATHS="$PHP_RPATHS $ai_p"
28989
28990  fi
28991
28992
28993      fi
28994
28995  fi
28996
28997    fi
28998  else
28999
29000
29001  if test -n "$THIS_LFLAGS"; then
29002
29003  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29004
29005  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29006    ai_p=$THIS_LFLAGS
29007  else
29008
29009    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29010
29011    ep_realdir=`(cd "$ep_dir" && pwd)`
29012    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29013  fi
29014
29015
29016
29017
29018
29019  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29020
29021  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29022  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29023    eval "LIBPATH$unique=set"
29024
29025    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29026    LDFLAGS="$LDFLAGS -L$ai_p"
29027    PHP_RPATHS="$PHP_RPATHS $ai_p"
29028
29029  fi
29030
29031
29032
29033  fi
29034
29035  fi
29036
29037
29038  case $THIS_LIBS in
29039  c|c_r) ;;
29040  *)
29041      LIBS="-l$THIS_LIBS $LIBS"
29042   ;;
29043  esac
29044
29045
29046
29047
29048  fi
29049
29050
29051  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
29052
29053fi
29054
29055  THIS_NAME=TCADB
29056  if test -n ""; then
29057    THIS_FULL_NAME=""
29058  else
29059    THIS_FULL_NAME="$THIS_NAME"
29060  fi
29061  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
29062printf %s "checking for $THIS_FULL_NAME support... " >&6; }
29063  if test -n ""; then
29064    as_fn_error $? "" "$LINENO" 5
29065  fi
29066  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
29067    HAVE_DBA=1
29068    eval HAVE_$THIS_NAME=1
29069    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
29070printf "%s\n" "$THIS_RESULT" >&6; }
29071  else
29072    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
29073printf "%s\n" "no" >&6; }
29074  fi
29075  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
29076
29077
29078if test "$PHP_LMDB" != "no"; then
29079
29080  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
29081
29082  for i in $PHP_LMDB /usr/local /usr; do
29083	if test -f "$i/include/lmdb.h"; then
29084	  THIS_PREFIX=$i
29085
29086  if test "$THIS_PREFIX/include" != "/usr/include"; then
29087
29088  if test -z "$THIS_PREFIX/include" || echo "$THIS_PREFIX/include" | grep '^/' >/dev/null ; then
29089    ai_p=$THIS_PREFIX/include
29090  else
29091
29092    ep_dir=`echo $THIS_PREFIX/include|$SED 's%/*[^/][^/]*/*$%%'`
29093
29094    ep_realdir=`(cd "$ep_dir" && pwd)`
29095    ai_p="$ep_realdir"/`basename "$THIS_PREFIX/include"`
29096  fi
29097
29098
29099
29100  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29101
29102  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
29103  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29104    eval "INCLUDEPATH$unique=set"
29105
29106      if test ""; then
29107        INCLUDES="-I$ai_p $INCLUDES"
29108      else
29109        INCLUDES="$INCLUDES -I$ai_p"
29110      fi
29111
29112  fi
29113
29114  fi
29115
29116	  THIS_INCLUDE=$i/include/lmdb.h
29117	  break
29118	fi
29119  done
29120
29121  if test -n "$THIS_INCLUDE"; then
29122	for LIB in lmdb; do
29123
29124  save_old_LDFLAGS=$LDFLAGS
29125  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
29126
29127  save_ext_shared=$ext_shared
29128  ext_shared=yes
29129
29130  for ac_i in $ac_stuff; do
29131    case $ac_i in
29132    -pthread)
29133      if test "$ext_shared" = "yes"; then
29134        LDFLAGS="$LDFLAGS -pthread"
29135      else
29136
29137
29138  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
29139
29140  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
29141  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29142    eval "EXTRA_LDFLAGS$unique=set"
29143    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
29144  fi
29145
29146
29147
29148  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
29149
29150  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
29151  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29152    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
29153    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
29154  fi
29155
29156      fi
29157    ;;
29158    -l*)
29159      ac_ii=`echo $ac_i|cut -c 3-`
29160
29161
29162  case $ac_ii in
29163  c|c_r) ;;
29164  *)
29165    if test "$ext_shared" = "yes"; then
29166        LDFLAGS="$LDFLAGS -l$ac_ii"
29167    else
29168
29169
29170  case $ac_ii in
29171  c|c_r) ;;
29172  *)
29173      LIBS="$LIBS -l$ac_ii"
29174   ;;
29175  esac
29176
29177
29178    fi
29179   ;;
29180  esac
29181
29182
29183    ;;
29184    -L*)
29185      ac_ii=`echo $ac_i|cut -c 3-`
29186
29187  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
29188
29189  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
29190    ai_p=$ac_ii
29191  else
29192
29193    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
29194
29195    ep_realdir=`(cd "$ep_dir" && pwd)`
29196    ai_p="$ep_realdir"/`basename "$ac_ii"`
29197  fi
29198
29199
29200      if test "$ext_shared" = "yes"; then
29201        LDFLAGS="-L$ai_p $LDFLAGS"
29202        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
29203      else
29204
29205
29206
29207  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29208
29209  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29210  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29211    eval "LIBPATH$unique=set"
29212
29213    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29214    LDFLAGS="$LDFLAGS -L$ai_p"
29215    PHP_RPATHS="$PHP_RPATHS $ai_p"
29216
29217  fi
29218
29219
29220      fi
29221
29222  fi
29223
29224    ;;
29225    esac
29226  done
29227
29228  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_mdb_env_open" | $as_tr_sh`
29229{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mdb_env_open in -l$LIB" >&5
29230printf %s "checking for mdb_env_open in -l$LIB... " >&6; }
29231if eval test \${$as_ac_Lib+y}
29232then :
29233  printf %s "(cached) " >&6
29234else $as_nop
29235  ac_check_lib_save_LIBS=$LIBS
29236LIBS="-l$LIB  $LIBS"
29237cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29238/* end confdefs.h.  */
29239
29240/* Override any GCC internal prototype to avoid an error.
29241   Use char because int might match the return type of a GCC
29242   builtin and then its argument prototype would still apply.  */
29243char mdb_env_open ();
29244int
29245main (void)
29246{
29247return mdb_env_open ();
29248  ;
29249  return 0;
29250}
29251_ACEOF
29252if ac_fn_c_try_link "$LINENO"
29253then :
29254  eval "$as_ac_Lib=yes"
29255else $as_nop
29256  eval "$as_ac_Lib=no"
29257fi
29258rm -f core conftest.err conftest.$ac_objext conftest.beam \
29259    conftest$ac_exeext conftest.$ac_ext
29260LIBS=$ac_check_lib_save_LIBS
29261fi
29262eval ac_res=\$$as_ac_Lib
29263	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
29264printf "%s\n" "$ac_res" >&6; }
29265if eval test \"x\$"$as_ac_Lib"\" = x"yes"
29266then :
29267
29268    LDFLAGS=$save_old_LDFLAGS
29269    ext_shared=$save_ext_shared
29270
29271
29272printf "%s\n" "#define LMDB_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
29273
29274
29275printf "%s\n" "#define DBA_LMDB 1" >>confdefs.h
29276
29277		THIS_LIBS=$LIB
29278
29279
29280else $as_nop
29281
29282    LDFLAGS=$save_old_LDFLAGS
29283    ext_shared=$save_ext_shared
29284    unset ac_cv_lib_$LIB_mdb_env_open
29285
29286
29287fi
29288
29289	  if test -n "$THIS_LIBS"; then
29290		break
29291	  fi
29292	done
29293  fi
29294
29295
29296  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
29297    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
29298  fi
29299
29300
29301  THIS_RESULT=yes
29302  if test -z "$THIS_INCLUDE"; then
29303    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
29304  fi
29305  if test -z "$THIS_LIBS"; then
29306    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
29307  fi
29308
29309
29310
29311
29312  if test "$ext_shared" = "yes"; then
29313    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
29314    if test -n "$THIS_LFLAGS"; then
29315
29316  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29317
29318  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29319    ai_p=$THIS_LFLAGS
29320  else
29321
29322    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29323
29324    ep_realdir=`(cd "$ep_dir" && pwd)`
29325    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29326  fi
29327
29328
29329      if test "$ext_shared" = "yes"; then
29330        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
29331        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
29332      else
29333
29334
29335
29336  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29337
29338  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29339  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29340    eval "LIBPATH$unique=set"
29341
29342    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29343    LDFLAGS="$LDFLAGS -L$ai_p"
29344    PHP_RPATHS="$PHP_RPATHS $ai_p"
29345
29346  fi
29347
29348
29349      fi
29350
29351  fi
29352
29353    fi
29354  else
29355
29356
29357  if test -n "$THIS_LFLAGS"; then
29358
29359  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29360
29361  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29362    ai_p=$THIS_LFLAGS
29363  else
29364
29365    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29366
29367    ep_realdir=`(cd "$ep_dir" && pwd)`
29368    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29369  fi
29370
29371
29372
29373
29374
29375  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29376
29377  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29378  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29379    eval "LIBPATH$unique=set"
29380
29381    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29382    LDFLAGS="$LDFLAGS -L$ai_p"
29383    PHP_RPATHS="$PHP_RPATHS $ai_p"
29384
29385  fi
29386
29387
29388
29389  fi
29390
29391  fi
29392
29393
29394  case $THIS_LIBS in
29395  c|c_r) ;;
29396  *)
29397      LIBS="-l$THIS_LIBS $LIBS"
29398   ;;
29399  esac
29400
29401
29402
29403
29404  fi
29405
29406
29407  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
29408
29409fi
29410
29411  THIS_NAME=LMDB
29412  if test -n ""; then
29413    THIS_FULL_NAME=""
29414  else
29415    THIS_FULL_NAME="$THIS_NAME"
29416  fi
29417  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
29418printf %s "checking for $THIS_FULL_NAME support... " >&6; }
29419  if test -n ""; then
29420    as_fn_error $? "" "$LINENO" 5
29421  fi
29422  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
29423    HAVE_DBA=1
29424    eval HAVE_$THIS_NAME=1
29425    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
29426printf "%s\n" "$THIS_RESULT" >&6; }
29427  else
29428    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
29429printf "%s\n" "no" >&6; }
29430  fi
29431  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
29432
29433
29434
29435
29436if test "$PHP_DB4" != "no"; then
29437
29438  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
29439
29440  dbdp4="/usr/local/BerkeleyDB.4."
29441  dbdp5="/usr/local/BerkeleyDB.5."
29442  for i in $PHP_DB4 ${dbdp5}1 ${dbdp5}0 ${dbdp4}8 ${dbdp4}7 ${dbdp4}6 ${dbdp4}5 ${dbdp4}4 ${dbdp4}3 ${dbdp4}2 ${dbdp4}1 ${dbdp}0 /usr/local /usr; do
29443    if test -f "$i/db5/db.h"; then
29444      THIS_PREFIX=$i
29445      THIS_INCLUDE=$i/db5/db.h
29446      break
29447    elif test -f "$i/db4/db.h"; then
29448      THIS_PREFIX=$i
29449      THIS_INCLUDE=$i/db4/db.h
29450      break
29451    elif test -f "$i/include/db5.3/db.h"; then
29452      THIS_PREFIX=$i
29453      THIS_INCLUDE=$i/include/db5.3/db.h
29454      break
29455    elif test -f "$i/include/db5.1/db.h"; then
29456      THIS_PREFIX=$i
29457      THIS_INCLUDE=$i/include/db5.1/db.h
29458      break
29459    elif test -f "$i/include/db5.0/db.h"; then
29460      THIS_PREFIX=$i
29461      THIS_INCLUDE=$i/include/db5.0/db.h
29462      break
29463    elif test -f "$i/include/db4.8/db.h"; then
29464      THIS_PREFIX=$i
29465      THIS_INCLUDE=$i/include/db4.8/db.h
29466      break
29467    elif test -f "$i/include/db4.7/db.h"; then
29468      THIS_PREFIX=$i
29469      THIS_INCLUDE=$i/include/db4.7/db.h
29470      break
29471    elif test -f "$i/include/db4.6/db.h"; then
29472      THIS_PREFIX=$i
29473      THIS_INCLUDE=$i/include/db4.6/db.h
29474      break
29475    elif test -f "$i/include/db4.5/db.h"; then
29476      THIS_PREFIX=$i
29477      THIS_INCLUDE=$i/include/db4.5/db.h
29478      break
29479    elif test -f "$i/include/db4/db.h"; then
29480      THIS_PREFIX=$i
29481      THIS_INCLUDE=$i/include/db4/db.h
29482      break
29483    elif test -f "$i/include/db/db4.h"; then
29484      THIS_PREFIX=$i
29485      THIS_INCLUDE=$i/include/db/db4.h
29486      break
29487    elif test -f "$i/include/db4.h"; then
29488      THIS_PREFIX=$i
29489      THIS_INCLUDE=$i/include/db4.h
29490      break
29491    elif test -f "$i/include/db.h"; then
29492      THIS_PREFIX=$i
29493      THIS_INCLUDE=$i/include/db.h
29494      break
29495    fi
29496  done
29497
29498  if test -z "$THIS_INCLUDE"; then
29499    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
29500  fi
29501  for LIB in db-5.3 db-5.1 db-5.0 db-4.8 db-4.7 db-4.6 db-4.5 db-4.4 db-4.3 db-4.2 db-4.1 db-4.0 db-4 db4 db; do
29502    if test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.a || test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.$SHLIB_SUFFIX_NAME; then
29503      lib_found="";
29504
29505  old_LDFLAGS=$LDFLAGS
29506  LDFLAGS="-L$THIS_PREFIX/$PHP_LIBDIR $LDFLAGS"
29507  old_LIBS=$LIBS
29508  LIBS="-l$LIB $LIBS"
29509
29510        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29511/* end confdefs.h.  */
29512
29513#include "$THIS_INCLUDE"
29514
29515int
29516main (void)
29517{
29518
29519          (void)db_create((DB**)0, (DB_ENV*)0, 0);
29520
29521  ;
29522  return 0;
29523}
29524_ACEOF
29525if ac_fn_c_try_link "$LINENO"
29526then :
29527
29528          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29529/* end confdefs.h.  */
29530
29531#include "$THIS_INCLUDE"
29532#if DB_VERSION_MAJOR == 4 || (4 == 4 && DB_VERSION_MAJOR == 5)
29533            yes
29534#endif
29535
29536_ACEOF
29537if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29538  $EGREP "yes" >/dev/null 2>&1
29539then :
29540
29541            THIS_LIBS=$LIB
29542            lib_found=1
29543
29544fi
29545rm -rf conftest*
29546
29547
29548fi
29549rm -f core conftest.err conftest.$ac_objext conftest.beam \
29550    conftest$ac_exeext conftest.$ac_ext
29551
29552  LDFLAGS=$old_LDFLAGS
29553  LIBS=$old_LIBS
29554
29555      if test -n "$lib_found"; then
29556        lib_found="";
29557        break;
29558      fi
29559    fi
29560  done
29561  if test -z "$THIS_LIBS"; then
29562    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB4 major version" >&5
29563printf %s "checking for DB4 major version... " >&6; }
29564    as_fn_error $? "Header contains different version" "$LINENO" 5
29565  fi
29566  if test "4" = "4"; then
29567    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB4 minor version and patch level" >&5
29568printf %s "checking for DB4 minor version and patch level... " >&6; }
29569    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29570/* end confdefs.h.  */
29571
29572#include "$THIS_INCLUDE"
29573#if DB_VERSION_MAJOR > 4 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR != 1) || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1 && DB_VERSION_PATCH >= 25)
29574      yes
29575#endif
29576
29577_ACEOF
29578if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29579  $EGREP "yes" >/dev/null 2>&1
29580then :
29581
29582      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
29583printf "%s\n" "ok" >&6; }
29584
29585else $as_nop
29586
29587      as_fn_error $? "Version 4.1 requires patch level 25" "$LINENO" 5
29588
29589fi
29590rm -rf conftest*
29591
29592  fi
29593  if test "$ext_shared" = "yes"; then
29594    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if dba can be used as shared extension" >&5
29595printf %s "checking if dba can be used as shared extension... " >&6; }
29596    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29597/* end confdefs.h.  */
29598
29599#include "$THIS_INCLUDE"
29600#if DB_VERSION_MAJOR > 3 || (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR > 2)
29601      yes
29602#endif
29603
29604_ACEOF
29605if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29606  $EGREP "yes" >/dev/null 2>&1
29607then :
29608
29609      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29610printf "%s\n" "yes" >&6; }
29611
29612else $as_nop
29613
29614      as_fn_error $? "At least version 3.3 is required" "$LINENO" 5
29615
29616fi
29617rm -rf conftest*
29618
29619  fi
29620  if test -n "$THIS_LIBS"; then
29621
29622printf "%s\n" "#define DBA_DB4 1" >>confdefs.h
29623
29624    if test -n "$THIS_INCLUDE"; then
29625
29626printf "%s\n" "#define DB4_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
29627
29628    fi
29629  else
29630    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
29631  fi
29632  THIS_RESULT=yes
29633  DB4_LIBS=$THIS_LIBS
29634  DB4_PREFIX=$THIS_PREFIX
29635  DB4_INCLUDE=$THIS_INCLUDE
29636
29637  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
29638    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
29639  fi
29640
29641
29642
29643
29644  if test "$ext_shared" = "yes"; then
29645    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
29646    if test -n "$THIS_LFLAGS"; then
29647
29648  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29649
29650  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29651    ai_p=$THIS_LFLAGS
29652  else
29653
29654    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29655
29656    ep_realdir=`(cd "$ep_dir" && pwd)`
29657    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29658  fi
29659
29660
29661      if test "$ext_shared" = "yes"; then
29662        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
29663        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
29664      else
29665
29666
29667
29668  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29669
29670  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29671  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29672    eval "LIBPATH$unique=set"
29673
29674    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29675    LDFLAGS="$LDFLAGS -L$ai_p"
29676    PHP_RPATHS="$PHP_RPATHS $ai_p"
29677
29678  fi
29679
29680
29681      fi
29682
29683  fi
29684
29685    fi
29686  else
29687
29688
29689  if test -n "$THIS_LFLAGS"; then
29690
29691  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29692
29693  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29694    ai_p=$THIS_LFLAGS
29695  else
29696
29697    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29698
29699    ep_realdir=`(cd "$ep_dir" && pwd)`
29700    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29701  fi
29702
29703
29704
29705
29706
29707  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29708
29709  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29710  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29711    eval "LIBPATH$unique=set"
29712
29713    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29714    LDFLAGS="$LDFLAGS -L$ai_p"
29715    PHP_RPATHS="$PHP_RPATHS $ai_p"
29716
29717  fi
29718
29719
29720
29721  fi
29722
29723  fi
29724
29725
29726  case $THIS_LIBS in
29727  c|c_r) ;;
29728  *)
29729      LIBS="-l$THIS_LIBS $LIBS"
29730   ;;
29731  esac
29732
29733
29734
29735
29736  fi
29737
29738
29739  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
29740
29741
29742fi
29743
29744  THIS_NAME=DB4
29745  if test -n "Berkeley DB4"; then
29746    THIS_FULL_NAME="Berkeley DB4"
29747  else
29748    THIS_FULL_NAME="$THIS_NAME"
29749  fi
29750  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
29751printf %s "checking for $THIS_FULL_NAME support... " >&6; }
29752  if test -n ""; then
29753    as_fn_error $? "" "$LINENO" 5
29754  fi
29755  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
29756    HAVE_DBA=1
29757    eval HAVE_$THIS_NAME=1
29758    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
29759printf "%s\n" "$THIS_RESULT" >&6; }
29760  else
29761    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
29762printf "%s\n" "no" >&6; }
29763  fi
29764  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
29765
29766
29767if test "$PHP_DB3" != "no"; then
29768
29769  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
29770
29771  if test "$HAVE_DB4" = "1"; then
29772
29773  THIS_NAME=DB3
29774  if test -n "Berkeley DB3"; then
29775    THIS_FULL_NAME="Berkeley DB3"
29776  else
29777    THIS_FULL_NAME="$THIS_NAME"
29778  fi
29779  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
29780printf %s "checking for $THIS_FULL_NAME support... " >&6; }
29781  if test -n "You cannot combine --with-db3 with --with-db4"; then
29782    as_fn_error $? "You cannot combine --with-db3 with --with-db4" "$LINENO" 5
29783  fi
29784  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
29785    HAVE_DBA=1
29786    eval HAVE_$THIS_NAME=1
29787    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
29788printf "%s\n" "$THIS_RESULT" >&6; }
29789  else
29790    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
29791printf "%s\n" "no" >&6; }
29792  fi
29793  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
29794
29795  fi
29796  for i in $PHP_DB3 /usr/local/BerkeleyDB.3.3 /usr/local/BerkeleyDB.3.2 /usr/local/BerkeleyDB.3.1 /usr/local/BerkeleyDB.3.0 /usr/local /usr; do
29797    if test -f "$i/db3/db.h"; then
29798      THIS_PREFIX=$i
29799      THIS_INCLUDE=$i/include/db3/db.h
29800      break
29801    elif test -f "$i/include/db3/db.h"; then
29802      THIS_PREFIX=$i
29803      THIS_INCLUDE=$i/include/db3/db.h
29804      break
29805    elif test -f "$i/include/db/db3.h"; then
29806      THIS_PREFIX=$i
29807      THIS_INCLUDE=$i/include/db/db3.h
29808      break
29809    elif test -f "$i/include/db3.h"; then
29810      THIS_PREFIX=$i
29811      THIS_INCLUDE=$i/include/db3.h
29812      break
29813    elif test -f "$i/include/db.h"; then
29814      THIS_PREFIX=$i
29815      THIS_INCLUDE=$i/include/db.h
29816      break
29817    fi
29818  done
29819
29820  if test -z "$THIS_INCLUDE"; then
29821    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
29822  fi
29823  for LIB in db-3.3 db-3.2 db-3.1 db-3.0 db-3 db3 db; do
29824    if test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.a || test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.$SHLIB_SUFFIX_NAME; then
29825      lib_found="";
29826
29827  old_LDFLAGS=$LDFLAGS
29828  LDFLAGS="-L$THIS_PREFIX/$PHP_LIBDIR $LDFLAGS"
29829  old_LIBS=$LIBS
29830  LIBS="-l$LIB $LIBS"
29831
29832        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29833/* end confdefs.h.  */
29834
29835#include "$THIS_INCLUDE"
29836
29837int
29838main (void)
29839{
29840
29841          (void)db_create((DB**)0, (DB_ENV*)0, 0);
29842
29843  ;
29844  return 0;
29845}
29846_ACEOF
29847if ac_fn_c_try_link "$LINENO"
29848then :
29849
29850          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29851/* end confdefs.h.  */
29852
29853#include "$THIS_INCLUDE"
29854#if DB_VERSION_MAJOR == 3 || (3 == 4 && DB_VERSION_MAJOR == 5)
29855            yes
29856#endif
29857
29858_ACEOF
29859if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29860  $EGREP "yes" >/dev/null 2>&1
29861then :
29862
29863            THIS_LIBS=$LIB
29864            lib_found=1
29865
29866fi
29867rm -rf conftest*
29868
29869
29870fi
29871rm -f core conftest.err conftest.$ac_objext conftest.beam \
29872    conftest$ac_exeext conftest.$ac_ext
29873
29874  LDFLAGS=$old_LDFLAGS
29875  LIBS=$old_LIBS
29876
29877      if test -n "$lib_found"; then
29878        lib_found="";
29879        break;
29880      fi
29881    fi
29882  done
29883  if test -z "$THIS_LIBS"; then
29884    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB3 major version" >&5
29885printf %s "checking for DB3 major version... " >&6; }
29886    as_fn_error $? "Header contains different version" "$LINENO" 5
29887  fi
29888  if test "3" = "4"; then
29889    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB4 minor version and patch level" >&5
29890printf %s "checking for DB4 minor version and patch level... " >&6; }
29891    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29892/* end confdefs.h.  */
29893
29894#include "$THIS_INCLUDE"
29895#if DB_VERSION_MAJOR > 4 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR != 1) || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1 && DB_VERSION_PATCH >= 25)
29896      yes
29897#endif
29898
29899_ACEOF
29900if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29901  $EGREP "yes" >/dev/null 2>&1
29902then :
29903
29904      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
29905printf "%s\n" "ok" >&6; }
29906
29907else $as_nop
29908
29909      as_fn_error $? "Version 4.1 requires patch level 25" "$LINENO" 5
29910
29911fi
29912rm -rf conftest*
29913
29914  fi
29915  if test "$ext_shared" = "yes"; then
29916    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if dba can be used as shared extension" >&5
29917printf %s "checking if dba can be used as shared extension... " >&6; }
29918    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29919/* end confdefs.h.  */
29920
29921#include "$THIS_INCLUDE"
29922#if DB_VERSION_MAJOR > 3 || (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR > 2)
29923      yes
29924#endif
29925
29926_ACEOF
29927if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29928  $EGREP "yes" >/dev/null 2>&1
29929then :
29930
29931      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29932printf "%s\n" "yes" >&6; }
29933
29934else $as_nop
29935
29936      as_fn_error $? "At least version 3.3 is required" "$LINENO" 5
29937
29938fi
29939rm -rf conftest*
29940
29941  fi
29942  if test -n "$THIS_LIBS"; then
29943
29944printf "%s\n" "#define DBA_DB3 1" >>confdefs.h
29945
29946    if test -n "$THIS_INCLUDE"; then
29947
29948printf "%s\n" "#define DB3_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
29949
29950    fi
29951  else
29952    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
29953  fi
29954  THIS_RESULT=yes
29955  DB3_LIBS=$THIS_LIBS
29956  DB3_PREFIX=$THIS_PREFIX
29957  DB3_INCLUDE=$THIS_INCLUDE
29958
29959  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
29960    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
29961  fi
29962
29963
29964
29965
29966  if test "$ext_shared" = "yes"; then
29967    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
29968    if test -n "$THIS_LFLAGS"; then
29969
29970  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
29971
29972  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
29973    ai_p=$THIS_LFLAGS
29974  else
29975
29976    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
29977
29978    ep_realdir=`(cd "$ep_dir" && pwd)`
29979    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
29980  fi
29981
29982
29983      if test "$ext_shared" = "yes"; then
29984        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
29985        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
29986      else
29987
29988
29989
29990  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
29991
29992  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
29993  if test -n "$unique" && test "`eval $cmd`" = "" ; then
29994    eval "LIBPATH$unique=set"
29995
29996    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
29997    LDFLAGS="$LDFLAGS -L$ai_p"
29998    PHP_RPATHS="$PHP_RPATHS $ai_p"
29999
30000  fi
30001
30002
30003      fi
30004
30005  fi
30006
30007    fi
30008  else
30009
30010
30011  if test -n "$THIS_LFLAGS"; then
30012
30013  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30014
30015  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30016    ai_p=$THIS_LFLAGS
30017  else
30018
30019    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30020
30021    ep_realdir=`(cd "$ep_dir" && pwd)`
30022    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30023  fi
30024
30025
30026
30027
30028
30029  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30030
30031  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30032  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30033    eval "LIBPATH$unique=set"
30034
30035    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30036    LDFLAGS="$LDFLAGS -L$ai_p"
30037    PHP_RPATHS="$PHP_RPATHS $ai_p"
30038
30039  fi
30040
30041
30042
30043  fi
30044
30045  fi
30046
30047
30048  case $THIS_LIBS in
30049  c|c_r) ;;
30050  *)
30051      LIBS="-l$THIS_LIBS $LIBS"
30052   ;;
30053  esac
30054
30055
30056
30057
30058  fi
30059
30060
30061  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
30062
30063
30064fi
30065
30066  THIS_NAME=DB3
30067  if test -n "Berkeley DB3"; then
30068    THIS_FULL_NAME="Berkeley DB3"
30069  else
30070    THIS_FULL_NAME="$THIS_NAME"
30071  fi
30072  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
30073printf %s "checking for $THIS_FULL_NAME support... " >&6; }
30074  if test -n ""; then
30075    as_fn_error $? "" "$LINENO" 5
30076  fi
30077  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
30078    HAVE_DBA=1
30079    eval HAVE_$THIS_NAME=1
30080    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
30081printf "%s\n" "$THIS_RESULT" >&6; }
30082  else
30083    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30084printf "%s\n" "no" >&6; }
30085  fi
30086  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
30087
30088
30089if test "$PHP_DB2" != "no"; then
30090
30091  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
30092
30093  if test "$HAVE_DB3" = "1" || test "$HAVE_DB4" = "1"; then
30094
30095  THIS_NAME=DB2
30096  if test -n "Berkeley DB2"; then
30097    THIS_FULL_NAME="Berkeley DB2"
30098  else
30099    THIS_FULL_NAME="$THIS_NAME"
30100  fi
30101  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
30102printf %s "checking for $THIS_FULL_NAME support... " >&6; }
30103  if test -n "You cannot combine --with-db2 with --with-db3 or --with-db4"; then
30104    as_fn_error $? "You cannot combine --with-db2 with --with-db3 or --with-db4" "$LINENO" 5
30105  fi
30106  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
30107    HAVE_DBA=1
30108    eval HAVE_$THIS_NAME=1
30109    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
30110printf "%s\n" "$THIS_RESULT" >&6; }
30111  else
30112    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30113printf "%s\n" "no" >&6; }
30114  fi
30115  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
30116
30117  fi
30118  for i in $PHP_DB2 $PHP_DB2/BerkeleyDB /usr/BerkeleyDB /usr/local /usr; do
30119    if test -f "$i/db2/db.h"; then
30120      THIS_PREFIX=$i
30121      THIS_INCLUDE=$i/db2/db.h
30122      break
30123    elif test -f "$i/include/db2/db.h"; then
30124      THIS_PREFIX=$i
30125      THIS_INCLUDE=$i/include/db2/db.h
30126      break
30127    elif test -f "$i/include/db/db2.h"; then
30128      THIS_PREFIX=$i
30129      THIS_INCLUDE=$i/include/db/db2.h
30130      break
30131    elif test -f "$i/include/db2.h"; then
30132      THIS_PREFIX=$i
30133      THIS_INCLUDE=$i/include/db2.h
30134      break
30135    elif test -f "$i/include/db.h"; then
30136      THIS_PREFIX=$i
30137      THIS_INCLUDE=$i/include/db.h
30138      break
30139    fi
30140  done
30141
30142  if test -z "$THIS_INCLUDE"; then
30143    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
30144  fi
30145  for LIB in db-2 db2 db; do
30146    if test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.a || test -f $THIS_PREFIX/$PHP_LIBDIR/lib$LIB.$SHLIB_SUFFIX_NAME; then
30147      lib_found="";
30148
30149  old_LDFLAGS=$LDFLAGS
30150  LDFLAGS="-L$THIS_PREFIX/$PHP_LIBDIR $LDFLAGS"
30151  old_LIBS=$LIBS
30152  LIBS="-l$LIB $LIBS"
30153
30154        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30155/* end confdefs.h.  */
30156
30157#include "$THIS_INCLUDE"
30158
30159int
30160main (void)
30161{
30162
30163          (void)db_appinit("", NULL, (DB_ENV*)0, 0);
30164
30165  ;
30166  return 0;
30167}
30168_ACEOF
30169if ac_fn_c_try_link "$LINENO"
30170then :
30171
30172          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30173/* end confdefs.h.  */
30174
30175#include "$THIS_INCLUDE"
30176#if DB_VERSION_MAJOR == 2 || (2 == 4 && DB_VERSION_MAJOR == 5)
30177            yes
30178#endif
30179
30180_ACEOF
30181if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30182  $EGREP "yes" >/dev/null 2>&1
30183then :
30184
30185            THIS_LIBS=$LIB
30186            lib_found=1
30187
30188fi
30189rm -rf conftest*
30190
30191
30192fi
30193rm -f core conftest.err conftest.$ac_objext conftest.beam \
30194    conftest$ac_exeext conftest.$ac_ext
30195
30196  LDFLAGS=$old_LDFLAGS
30197  LIBS=$old_LIBS
30198
30199      if test -n "$lib_found"; then
30200        lib_found="";
30201        break;
30202      fi
30203    fi
30204  done
30205  if test -z "$THIS_LIBS"; then
30206    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB2 major version" >&5
30207printf %s "checking for DB2 major version... " >&6; }
30208    as_fn_error $? "Header contains different version" "$LINENO" 5
30209  fi
30210  if test "2" = "4"; then
30211    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB4 minor version and patch level" >&5
30212printf %s "checking for DB4 minor version and patch level... " >&6; }
30213    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30214/* end confdefs.h.  */
30215
30216#include "$THIS_INCLUDE"
30217#if DB_VERSION_MAJOR > 4 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR != 1) || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 1 && DB_VERSION_PATCH >= 25)
30218      yes
30219#endif
30220
30221_ACEOF
30222if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30223  $EGREP "yes" >/dev/null 2>&1
30224then :
30225
30226      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
30227printf "%s\n" "ok" >&6; }
30228
30229else $as_nop
30230
30231      as_fn_error $? "Version 4.1 requires patch level 25" "$LINENO" 5
30232
30233fi
30234rm -rf conftest*
30235
30236  fi
30237  if test "$ext_shared" = "yes"; then
30238    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if dba can be used as shared extension" >&5
30239printf %s "checking if dba can be used as shared extension... " >&6; }
30240    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30241/* end confdefs.h.  */
30242
30243#include "$THIS_INCLUDE"
30244#if DB_VERSION_MAJOR > 3 || (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR > 2)
30245      yes
30246#endif
30247
30248_ACEOF
30249if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30250  $EGREP "yes" >/dev/null 2>&1
30251then :
30252
30253      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30254printf "%s\n" "yes" >&6; }
30255
30256else $as_nop
30257
30258      as_fn_error $? "At least version 3.3 is required" "$LINENO" 5
30259
30260fi
30261rm -rf conftest*
30262
30263  fi
30264  if test -n "$THIS_LIBS"; then
30265
30266printf "%s\n" "#define DBA_DB2 1" >>confdefs.h
30267
30268    if test -n "$THIS_INCLUDE"; then
30269
30270printf "%s\n" "#define DB2_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
30271
30272    fi
30273  else
30274    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
30275  fi
30276  THIS_RESULT=yes
30277  DB2_LIBS=$THIS_LIBS
30278  DB2_PREFIX=$THIS_PREFIX
30279  DB2_INCLUDE=$THIS_INCLUDE
30280
30281  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
30282    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
30283  fi
30284
30285
30286
30287
30288  if test "$ext_shared" = "yes"; then
30289    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
30290    if test -n "$THIS_LFLAGS"; then
30291
30292  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30293
30294  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30295    ai_p=$THIS_LFLAGS
30296  else
30297
30298    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30299
30300    ep_realdir=`(cd "$ep_dir" && pwd)`
30301    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30302  fi
30303
30304
30305      if test "$ext_shared" = "yes"; then
30306        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
30307        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
30308      else
30309
30310
30311
30312  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30313
30314  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30315  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30316    eval "LIBPATH$unique=set"
30317
30318    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30319    LDFLAGS="$LDFLAGS -L$ai_p"
30320    PHP_RPATHS="$PHP_RPATHS $ai_p"
30321
30322  fi
30323
30324
30325      fi
30326
30327  fi
30328
30329    fi
30330  else
30331
30332
30333  if test -n "$THIS_LFLAGS"; then
30334
30335  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30336
30337  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30338    ai_p=$THIS_LFLAGS
30339  else
30340
30341    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30342
30343    ep_realdir=`(cd "$ep_dir" && pwd)`
30344    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30345  fi
30346
30347
30348
30349
30350
30351  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30352
30353  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30354  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30355    eval "LIBPATH$unique=set"
30356
30357    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30358    LDFLAGS="$LDFLAGS -L$ai_p"
30359    PHP_RPATHS="$PHP_RPATHS $ai_p"
30360
30361  fi
30362
30363
30364
30365  fi
30366
30367  fi
30368
30369
30370  case $THIS_LIBS in
30371  c|c_r) ;;
30372  *)
30373      LIBS="-l$THIS_LIBS $LIBS"
30374   ;;
30375  esac
30376
30377
30378
30379
30380  fi
30381
30382
30383  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
30384
30385
30386fi
30387
30388  THIS_NAME=DB2
30389  if test -n "Berkeley DB2"; then
30390    THIS_FULL_NAME="Berkeley DB2"
30391  else
30392    THIS_FULL_NAME="$THIS_NAME"
30393  fi
30394  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
30395printf %s "checking for $THIS_FULL_NAME support... " >&6; }
30396  if test -n ""; then
30397    as_fn_error $? "" "$LINENO" 5
30398  fi
30399  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
30400    HAVE_DBA=1
30401    eval HAVE_$THIS_NAME=1
30402    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
30403printf "%s\n" "$THIS_RESULT" >&6; }
30404  else
30405    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30406printf "%s\n" "no" >&6; }
30407  fi
30408  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
30409
30410
30411if test "$PHP_DB1" != "no"; then
30412
30413  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
30414
30415  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB1 in library" >&5
30416printf %s "checking for DB1 in library... " >&6; }
30417  if test "$HAVE_DB4" = "1"; then
30418    THIS_VERSION=4
30419    THIS_LIBS=$DB4_LIBS
30420    THIS_PREFIX=$DB4_PREFIX
30421  elif test "$HAVE_DB3" = "1"; then
30422    THIS_LIBS=$DB3_LIBS
30423    THIS_PREFIX=$DB3_PREFIX
30424  elif test "$HAVE_DB2" = "1"; then
30425    THIS_VERSION=2
30426    THIS_LIBS=$DB2_LIBS
30427    THIS_PREFIX=$DB2_PREFIX
30428  fi
30429  if test "$HAVE_DB4" = "1" || test "$HAVE_DB3" = "1" || test "$HAVE_DB2" = "1"; then
30430
30431printf "%s\n" "#define DB1_VERSION \"Berkeley DB 1.85 emulation in DB$THIS_VERSION\"" >>confdefs.h
30432
30433    for i in db$THIS_VERSION/db_185.h include/db$THIS_VERSION/db_185.h include/db/db_185.h; do
30434      if test -f "$THIS_PREFIX/$i"; then
30435        THIS_INCLUDE=$THIS_PREFIX/$i
30436        break
30437      fi
30438    done
30439  else
30440
30441printf "%s\n" "#define DB1_VERSION \"Unknown DB1\"" >>confdefs.h
30442
30443    for i in $PHP_DB1 /usr/local /usr; do
30444      if test -f "$i/db1/db.h"; then
30445        THIS_PREFIX=$i
30446        THIS_INCLUDE=$i/db1/db.h
30447        break
30448      elif test -f "$i/include/db1/db.h"; then
30449        THIS_PREFIX=$i
30450        THIS_INCLUDE=$i/include/db1/db.h
30451        break
30452      elif test -f "$i/include/db.h"; then
30453        THIS_PREFIX=$i
30454        THIS_INCLUDE=$i/include/db.h
30455        break
30456      fi
30457    done
30458    THIS_LIBS=db
30459  fi
30460  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_LIBS" >&5
30461printf "%s\n" "$THIS_LIBS" >&6; }
30462  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DB1 in header" >&5
30463printf %s "checking for DB1 in header... " >&6; }
30464  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_INCLUDE" >&5
30465printf "%s\n" "$THIS_INCLUDE" >&6; }
30466  if test -n "$THIS_INCLUDE"; then
30467
30468  old_LDFLAGS=$LDFLAGS
30469  LDFLAGS="-L$THIS_PREFIX/$PHP_LIBDIR $LDFLAGS"
30470  old_LIBS=$LIBS
30471  LIBS="-l$THIS_LIBS $LIBS"
30472
30473      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30474/* end confdefs.h.  */
30475
30476#include "$THIS_INCLUDE"
30477
30478int
30479main (void)
30480{
30481
30482        DB * dbp = dbopen("", 0, 0, DB_HASH, 0);
30483
30484  ;
30485  return 0;
30486}
30487_ACEOF
30488if ac_fn_c_try_link "$LINENO"
30489then :
30490
30491
30492printf "%s\n" "#define DB1_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
30493
30494
30495printf "%s\n" "#define DBA_DB1 1" >>confdefs.h
30496
30497        THIS_RESULT=yes
30498
30499else $as_nop
30500
30501        THIS_RESULT=no
30502
30503fi
30504rm -f core conftest.err conftest.$ac_objext conftest.beam \
30505    conftest$ac_exeext conftest.$ac_ext
30506
30507  LDFLAGS=$old_LDFLAGS
30508  LIBS=$old_LIBS
30509
30510  fi
30511
30512  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
30513    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
30514  fi
30515
30516
30517  THIS_RESULT=yes
30518  if test -z "$THIS_INCLUDE"; then
30519    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
30520  fi
30521  if test -z "$THIS_LIBS"; then
30522    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
30523  fi
30524
30525
30526
30527
30528  if test "$ext_shared" = "yes"; then
30529    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
30530    if test -n "$THIS_LFLAGS"; then
30531
30532  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30533
30534  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30535    ai_p=$THIS_LFLAGS
30536  else
30537
30538    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30539
30540    ep_realdir=`(cd "$ep_dir" && pwd)`
30541    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30542  fi
30543
30544
30545      if test "$ext_shared" = "yes"; then
30546        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
30547        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
30548      else
30549
30550
30551
30552  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30553
30554  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30555  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30556    eval "LIBPATH$unique=set"
30557
30558    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30559    LDFLAGS="$LDFLAGS -L$ai_p"
30560    PHP_RPATHS="$PHP_RPATHS $ai_p"
30561
30562  fi
30563
30564
30565      fi
30566
30567  fi
30568
30569    fi
30570  else
30571
30572
30573  if test -n "$THIS_LFLAGS"; then
30574
30575  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30576
30577  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30578    ai_p=$THIS_LFLAGS
30579  else
30580
30581    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30582
30583    ep_realdir=`(cd "$ep_dir" && pwd)`
30584    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30585  fi
30586
30587
30588
30589
30590
30591  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30592
30593  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30594  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30595    eval "LIBPATH$unique=set"
30596
30597    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30598    LDFLAGS="$LDFLAGS -L$ai_p"
30599    PHP_RPATHS="$PHP_RPATHS $ai_p"
30600
30601  fi
30602
30603
30604
30605  fi
30606
30607  fi
30608
30609
30610  case $THIS_LIBS in
30611  c|c_r) ;;
30612  *)
30613      LIBS="-l$THIS_LIBS $LIBS"
30614   ;;
30615  esac
30616
30617
30618
30619
30620  fi
30621
30622
30623  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
30624
30625fi
30626
30627  THIS_NAME=DB1
30628  if test -n "DB1"; then
30629    THIS_FULL_NAME="DB1"
30630  else
30631    THIS_FULL_NAME="$THIS_NAME"
30632  fi
30633  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
30634printf %s "checking for $THIS_FULL_NAME support... " >&6; }
30635  if test -n ""; then
30636    as_fn_error $? "" "$LINENO" 5
30637  fi
30638  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
30639    HAVE_DBA=1
30640    eval HAVE_$THIS_NAME=1
30641    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
30642printf "%s\n" "$THIS_RESULT" >&6; }
30643  else
30644    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30645printf "%s\n" "no" >&6; }
30646  fi
30647  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
30648
30649
30650if test "$PHP_DBM" != "no"; then
30651
30652  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
30653
30654  if test "$HAVE_QDBM" = "1"; then
30655
30656  THIS_NAME=DBM
30657  if test -n "dbm"; then
30658    THIS_FULL_NAME="dbm"
30659  else
30660    THIS_FULL_NAME="$THIS_NAME"
30661  fi
30662  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
30663printf %s "checking for $THIS_FULL_NAME support... " >&6; }
30664  if test -n "You cannot combine --with-dbm with --with-qdbm"; then
30665    as_fn_error $? "You cannot combine --with-dbm with --with-qdbm" "$LINENO" 5
30666  fi
30667  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
30668    HAVE_DBA=1
30669    eval HAVE_$THIS_NAME=1
30670    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
30671printf "%s\n" "$THIS_RESULT" >&6; }
30672  else
30673    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30674printf "%s\n" "no" >&6; }
30675  fi
30676  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
30677
30678  fi
30679  for i in $PHP_DBM /usr/local /usr; do
30680    if test -f "$i/include/dbm.h"; then
30681      THIS_PREFIX=$i
30682      THIS_INCLUDE=$i/include/dbm.h
30683      break
30684    elif test -f "$i/include/gdbm/dbm.h"; then
30685      THIS_PREFIX=$i
30686      THIS_INCLUDE=$i/include/gdbm/dbm.h
30687      break
30688    fi
30689  done
30690
30691  if test -n "$THIS_INCLUDE"; then
30692    for LIB in dbm c gdbm; do
30693
30694  save_old_LDFLAGS=$LDFLAGS
30695  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
30696
30697  save_ext_shared=$ext_shared
30698  ext_shared=yes
30699
30700  for ac_i in $ac_stuff; do
30701    case $ac_i in
30702    -pthread)
30703      if test "$ext_shared" = "yes"; then
30704        LDFLAGS="$LDFLAGS -pthread"
30705      else
30706
30707
30708  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
30709
30710  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
30711  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30712    eval "EXTRA_LDFLAGS$unique=set"
30713    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
30714  fi
30715
30716
30717
30718  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
30719
30720  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
30721  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30722    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
30723    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
30724  fi
30725
30726      fi
30727    ;;
30728    -l*)
30729      ac_ii=`echo $ac_i|cut -c 3-`
30730
30731
30732  case $ac_ii in
30733  c|c_r) ;;
30734  *)
30735    if test "$ext_shared" = "yes"; then
30736        LDFLAGS="$LDFLAGS -l$ac_ii"
30737    else
30738
30739
30740  case $ac_ii in
30741  c|c_r) ;;
30742  *)
30743      LIBS="$LIBS -l$ac_ii"
30744   ;;
30745  esac
30746
30747
30748    fi
30749   ;;
30750  esac
30751
30752
30753    ;;
30754    -L*)
30755      ac_ii=`echo $ac_i|cut -c 3-`
30756
30757  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
30758
30759  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
30760    ai_p=$ac_ii
30761  else
30762
30763    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
30764
30765    ep_realdir=`(cd "$ep_dir" && pwd)`
30766    ai_p="$ep_realdir"/`basename "$ac_ii"`
30767  fi
30768
30769
30770      if test "$ext_shared" = "yes"; then
30771        LDFLAGS="-L$ai_p $LDFLAGS"
30772        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
30773      else
30774
30775
30776
30777  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30778
30779  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30780  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30781    eval "LIBPATH$unique=set"
30782
30783    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30784    LDFLAGS="$LDFLAGS -L$ai_p"
30785    PHP_RPATHS="$PHP_RPATHS $ai_p"
30786
30787  fi
30788
30789
30790      fi
30791
30792  fi
30793
30794    ;;
30795    esac
30796  done
30797
30798  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_dbminit" | $as_tr_sh`
30799{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dbminit in -l$LIB" >&5
30800printf %s "checking for dbminit in -l$LIB... " >&6; }
30801if eval test \${$as_ac_Lib+y}
30802then :
30803  printf %s "(cached) " >&6
30804else $as_nop
30805  ac_check_lib_save_LIBS=$LIBS
30806LIBS="-l$LIB  $LIBS"
30807cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30808/* end confdefs.h.  */
30809
30810/* Override any GCC internal prototype to avoid an error.
30811   Use char because int might match the return type of a GCC
30812   builtin and then its argument prototype would still apply.  */
30813char dbminit ();
30814int
30815main (void)
30816{
30817return dbminit ();
30818  ;
30819  return 0;
30820}
30821_ACEOF
30822if ac_fn_c_try_link "$LINENO"
30823then :
30824  eval "$as_ac_Lib=yes"
30825else $as_nop
30826  eval "$as_ac_Lib=no"
30827fi
30828rm -f core conftest.err conftest.$ac_objext conftest.beam \
30829    conftest$ac_exeext conftest.$ac_ext
30830LIBS=$ac_check_lib_save_LIBS
30831fi
30832eval ac_res=\$$as_ac_Lib
30833	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
30834printf "%s\n" "$ac_res" >&6; }
30835if eval test \"x\$"$as_ac_Lib"\" = x"yes"
30836then :
30837
30838    LDFLAGS=$save_old_LDFLAGS
30839    ext_shared=$save_ext_shared
30840
30841        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DBM using GDBM" >&5
30842printf %s "checking for DBM using GDBM... " >&6; }
30843
30844printf "%s\n" "#define DBM_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
30845
30846        if test "$LIB" = "gdbm"; then
30847
30848printf "%s\n" "#define DBM_VERSION \"GDBM\"" >>confdefs.h
30849
30850          { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30851printf "%s\n" "yes" >&6; }
30852        else
30853
30854printf "%s\n" "#define DBM_VERSION \"DBM\"" >>confdefs.h
30855
30856          { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
30857printf "%s\n" "no" >&6; }
30858        fi
30859
30860printf "%s\n" "#define DBA_DBM 1" >>confdefs.h
30861
30862        THIS_LIBS=$LIB
30863
30864
30865else $as_nop
30866
30867    LDFLAGS=$save_old_LDFLAGS
30868    ext_shared=$save_ext_shared
30869    unset ac_cv_lib_$LIB_dbminit
30870
30871
30872fi
30873
30874      if test -n "$THIS_LIBS"; then
30875        break
30876      fi
30877    done
30878  fi
30879
30880
30881  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
30882    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
30883  fi
30884
30885
30886  THIS_RESULT=yes
30887  if test -z "$THIS_INCLUDE"; then
30888    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
30889  fi
30890  if test -z "$THIS_LIBS"; then
30891    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
30892  fi
30893
30894
30895
30896
30897  if test "$ext_shared" = "yes"; then
30898    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
30899    if test -n "$THIS_LFLAGS"; then
30900
30901  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30902
30903  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30904    ai_p=$THIS_LFLAGS
30905  else
30906
30907    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30908
30909    ep_realdir=`(cd "$ep_dir" && pwd)`
30910    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30911  fi
30912
30913
30914      if test "$ext_shared" = "yes"; then
30915        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
30916        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
30917      else
30918
30919
30920
30921  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30922
30923  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30924  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30925    eval "LIBPATH$unique=set"
30926
30927    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30928    LDFLAGS="$LDFLAGS -L$ai_p"
30929    PHP_RPATHS="$PHP_RPATHS $ai_p"
30930
30931  fi
30932
30933
30934      fi
30935
30936  fi
30937
30938    fi
30939  else
30940
30941
30942  if test -n "$THIS_LFLAGS"; then
30943
30944  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
30945
30946  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
30947    ai_p=$THIS_LFLAGS
30948  else
30949
30950    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
30951
30952    ep_realdir=`(cd "$ep_dir" && pwd)`
30953    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
30954  fi
30955
30956
30957
30958
30959
30960  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
30961
30962  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
30963  if test -n "$unique" && test "`eval $cmd`" = "" ; then
30964    eval "LIBPATH$unique=set"
30965
30966    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
30967    LDFLAGS="$LDFLAGS -L$ai_p"
30968    PHP_RPATHS="$PHP_RPATHS $ai_p"
30969
30970  fi
30971
30972
30973
30974  fi
30975
30976  fi
30977
30978
30979  case $THIS_LIBS in
30980  c|c_r) ;;
30981  *)
30982      LIBS="-l$THIS_LIBS $LIBS"
30983   ;;
30984  esac
30985
30986
30987
30988
30989  fi
30990
30991
30992  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
30993
30994fi
30995
30996  THIS_NAME=DBM
30997  if test -n ""; then
30998    THIS_FULL_NAME=""
30999  else
31000    THIS_FULL_NAME="$THIS_NAME"
31001  fi
31002  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
31003printf %s "checking for $THIS_FULL_NAME support... " >&6; }
31004  if test -n ""; then
31005    as_fn_error $? "" "$LINENO" 5
31006  fi
31007  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
31008    HAVE_DBA=1
31009    eval HAVE_$THIS_NAME=1
31010    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
31011printf "%s\n" "$THIS_RESULT" >&6; }
31012  else
31013    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31014printf "%s\n" "no" >&6; }
31015  fi
31016  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
31017
31018
31019if test "$PHP_DBA" != "no" || test "$HAVE_DBA" = "1" || test "$with_cdb" = "yes" || test "$enable_inifile" = "yes" || test "$enable_flatfile" = "yes"; then
31020  php_dba_enable=yes
31021else
31022  php_dba_enable=no
31023fi
31024
31025
31026php_with_cdb=$php_dba_enable
31027
31028
31029
31030# Check whether --with-cdb was given.
31031if test ${with_cdb+y}
31032then :
31033  withval=$with_cdb; PHP_CDB=$withval
31034else $as_nop
31035
31036  PHP_CDB=$php_dba_enable
31037
31038
31039fi
31040
31041
31042ext_output=$PHP_CDB
31043
31044
31045
31046
31047
31048
31049php_enable_inifile=$php_dba_enable
31050
31051
31052# Check whether --enable-inifile was given.
31053if test ${enable_inifile+y}
31054then :
31055  enableval=$enable_inifile; PHP_INIFILE=$enableval
31056else $as_nop
31057
31058  PHP_INIFILE=$php_dba_enable
31059
31060
31061fi
31062
31063
31064ext_output=$PHP_INIFILE
31065
31066
31067
31068
31069
31070
31071php_enable_flatfile=$php_dba_enable
31072
31073
31074# Check whether --enable-flatfile was given.
31075if test ${enable_flatfile+y}
31076then :
31077  enableval=$enable_flatfile; PHP_FLATFILE=$enableval
31078else $as_nop
31079
31080  PHP_FLATFILE=$php_dba_enable
31081
31082
31083fi
31084
31085
31086ext_output=$PHP_FLATFILE
31087
31088
31089
31090
31091
31092if test "$PHP_CDB" = "yes"; then
31093
31094printf "%s\n" "#define DBA_CDB_BUILTIN 1" >>confdefs.h
31095
31096
31097printf "%s\n" "#define DBA_CDB_MAKE 1" >>confdefs.h
31098
31099
31100printf "%s\n" "#define DBA_CDB 1" >>confdefs.h
31101
31102  cdb_sources="libcdb/cdb.c libcdb/cdb_make.c libcdb/uint32.c"
31103  THIS_RESULT="builtin"
31104elif test "$PHP_CDB" != "no"; then
31105
31106  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
31107
31108  for i in $PHP_CDB /usr/local /usr; do
31109    if test -f "$i/include/cdb.h"; then
31110      THIS_PREFIX=$i
31111      THIS_INCLUDE=$i/include/cdb.h
31112      break
31113    fi
31114  done
31115
31116  if test -n "$THIS_INCLUDE"; then
31117    for LIB in cdb c; do
31118
31119  save_old_LDFLAGS=$LDFLAGS
31120  ac_stuff="-L$THIS_PREFIX/$PHP_LIBDIR"
31121
31122  save_ext_shared=$ext_shared
31123  ext_shared=yes
31124
31125  for ac_i in $ac_stuff; do
31126    case $ac_i in
31127    -pthread)
31128      if test "$ext_shared" = "yes"; then
31129        LDFLAGS="$LDFLAGS -pthread"
31130      else
31131
31132
31133  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
31134
31135  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
31136  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31137    eval "EXTRA_LDFLAGS$unique=set"
31138    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
31139  fi
31140
31141
31142
31143  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
31144
31145  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
31146  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31147    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
31148    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
31149  fi
31150
31151      fi
31152    ;;
31153    -l*)
31154      ac_ii=`echo $ac_i|cut -c 3-`
31155
31156
31157  case $ac_ii in
31158  c|c_r) ;;
31159  *)
31160    if test "$ext_shared" = "yes"; then
31161        LDFLAGS="$LDFLAGS -l$ac_ii"
31162    else
31163
31164
31165  case $ac_ii in
31166  c|c_r) ;;
31167  *)
31168      LIBS="$LIBS -l$ac_ii"
31169   ;;
31170  esac
31171
31172
31173    fi
31174   ;;
31175  esac
31176
31177
31178    ;;
31179    -L*)
31180      ac_ii=`echo $ac_i|cut -c 3-`
31181
31182  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
31183
31184  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
31185    ai_p=$ac_ii
31186  else
31187
31188    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
31189
31190    ep_realdir=`(cd "$ep_dir" && pwd)`
31191    ai_p="$ep_realdir"/`basename "$ac_ii"`
31192  fi
31193
31194
31195      if test "$ext_shared" = "yes"; then
31196        LDFLAGS="-L$ai_p $LDFLAGS"
31197        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
31198      else
31199
31200
31201
31202  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
31203
31204  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
31205  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31206    eval "LIBPATH$unique=set"
31207
31208    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
31209    LDFLAGS="$LDFLAGS -L$ai_p"
31210    PHP_RPATHS="$PHP_RPATHS $ai_p"
31211
31212  fi
31213
31214
31215      fi
31216
31217  fi
31218
31219    ;;
31220    esac
31221  done
31222
31223  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$LIB""_cdb_read" | $as_tr_sh`
31224{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cdb_read in -l$LIB" >&5
31225printf %s "checking for cdb_read in -l$LIB... " >&6; }
31226if eval test \${$as_ac_Lib+y}
31227then :
31228  printf %s "(cached) " >&6
31229else $as_nop
31230  ac_check_lib_save_LIBS=$LIBS
31231LIBS="-l$LIB  $LIBS"
31232cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31233/* end confdefs.h.  */
31234
31235/* Override any GCC internal prototype to avoid an error.
31236   Use char because int might match the return type of a GCC
31237   builtin and then its argument prototype would still apply.  */
31238char cdb_read ();
31239int
31240main (void)
31241{
31242return cdb_read ();
31243  ;
31244  return 0;
31245}
31246_ACEOF
31247if ac_fn_c_try_link "$LINENO"
31248then :
31249  eval "$as_ac_Lib=yes"
31250else $as_nop
31251  eval "$as_ac_Lib=no"
31252fi
31253rm -f core conftest.err conftest.$ac_objext conftest.beam \
31254    conftest$ac_exeext conftest.$ac_ext
31255LIBS=$ac_check_lib_save_LIBS
31256fi
31257eval ac_res=\$$as_ac_Lib
31258	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
31259printf "%s\n" "$ac_res" >&6; }
31260if eval test \"x\$"$as_ac_Lib"\" = x"yes"
31261then :
31262
31263    LDFLAGS=$save_old_LDFLAGS
31264    ext_shared=$save_ext_shared
31265
31266
31267printf "%s\n" "#define CDB_INCLUDE_FILE \"$THIS_INCLUDE\"" >>confdefs.h
31268
31269
31270printf "%s\n" "#define DBA_CDB 1" >>confdefs.h
31271
31272        THIS_LIBS=$LIB
31273
31274
31275else $as_nop
31276
31277    LDFLAGS=$save_old_LDFLAGS
31278    ext_shared=$save_ext_shared
31279    unset ac_cv_lib_$LIB_cdb_read
31280
31281
31282fi
31283
31284      if test -n "$THIS_LIBS"; then
31285        break
31286      fi
31287    done
31288  fi
31289
31290
31291  if test -n "$THIS_PREFIX" && test "$THIS_PREFIX" != "/usr"; then
31292    THIS_LFLAGS=$THIS_PREFIX/$PHP_LIBDIR
31293  fi
31294
31295
31296  THIS_RESULT=yes
31297  if test -z "$THIS_INCLUDE"; then
31298    as_fn_error $? "DBA: Could not find necessary header file(s)." "$LINENO" 5
31299  fi
31300  if test -z "$THIS_LIBS"; then
31301    as_fn_error $? "DBA: Could not find necessary library." "$LINENO" 5
31302  fi
31303
31304
31305
31306
31307  if test "$ext_shared" = "yes"; then
31308    DBA_SHARED_LIBADD="-l$THIS_LIBS $DBA_SHARED_LIBADD"
31309    if test -n "$THIS_LFLAGS"; then
31310
31311  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
31312
31313  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
31314    ai_p=$THIS_LFLAGS
31315  else
31316
31317    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
31318
31319    ep_realdir=`(cd "$ep_dir" && pwd)`
31320    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
31321  fi
31322
31323
31324      if test "$ext_shared" = "yes"; then
31325        DBA_SHARED_LIBADD="-L$ai_p $DBA_SHARED_LIBADD"
31326        test -n "$ld_runpath_switch" && DBA_SHARED_LIBADD="$ld_runpath_switch$ai_p $DBA_SHARED_LIBADD"
31327      else
31328
31329
31330
31331  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
31332
31333  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
31334  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31335    eval "LIBPATH$unique=set"
31336
31337    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
31338    LDFLAGS="$LDFLAGS -L$ai_p"
31339    PHP_RPATHS="$PHP_RPATHS $ai_p"
31340
31341  fi
31342
31343
31344      fi
31345
31346  fi
31347
31348    fi
31349  else
31350
31351
31352  if test -n "$THIS_LFLAGS"; then
31353
31354  if test "$THIS_LFLAGS" != "/usr/$PHP_LIBDIR" && test "$THIS_LFLAGS" != "/usr/lib"; then
31355
31356  if test -z "$THIS_LFLAGS" || echo "$THIS_LFLAGS" | grep '^/' >/dev/null ; then
31357    ai_p=$THIS_LFLAGS
31358  else
31359
31360    ep_dir=`echo $THIS_LFLAGS|$SED 's%/*[^/][^/]*/*$%%'`
31361
31362    ep_realdir=`(cd "$ep_dir" && pwd)`
31363    ai_p="$ep_realdir"/`basename "$THIS_LFLAGS"`
31364  fi
31365
31366
31367
31368
31369
31370  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
31371
31372  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
31373  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31374    eval "LIBPATH$unique=set"
31375
31376    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
31377    LDFLAGS="$LDFLAGS -L$ai_p"
31378    PHP_RPATHS="$PHP_RPATHS $ai_p"
31379
31380  fi
31381
31382
31383
31384  fi
31385
31386  fi
31387
31388
31389  case $THIS_LIBS in
31390  c|c_r) ;;
31391  *)
31392      LIBS="-l$THIS_LIBS $LIBS"
31393   ;;
31394  esac
31395
31396
31397
31398
31399  fi
31400
31401
31402  unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX
31403
31404fi
31405
31406  THIS_NAME=CDB
31407  if test -n ""; then
31408    THIS_FULL_NAME=""
31409  else
31410    THIS_FULL_NAME="$THIS_NAME"
31411  fi
31412  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
31413printf %s "checking for $THIS_FULL_NAME support... " >&6; }
31414  if test -n ""; then
31415    as_fn_error $? "" "$LINENO" 5
31416  fi
31417  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
31418    HAVE_DBA=1
31419    eval HAVE_$THIS_NAME=1
31420    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
31421printf "%s\n" "$THIS_RESULT" >&6; }
31422  else
31423    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31424printf "%s\n" "no" >&6; }
31425  fi
31426  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
31427
31428
31429if test "$PHP_INIFILE" != "no"; then
31430
31431printf "%s\n" "#define DBA_INIFILE 1" >>confdefs.h
31432
31433  ini_sources="libinifile/inifile.c"
31434  THIS_RESULT="builtin"
31435fi
31436
31437  THIS_NAME=INIFILE
31438  if test -n "INI File"; then
31439    THIS_FULL_NAME="INI File"
31440  else
31441    THIS_FULL_NAME="$THIS_NAME"
31442  fi
31443  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
31444printf %s "checking for $THIS_FULL_NAME support... " >&6; }
31445  if test -n ""; then
31446    as_fn_error $? "" "$LINENO" 5
31447  fi
31448  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
31449    HAVE_DBA=1
31450    eval HAVE_$THIS_NAME=1
31451    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
31452printf "%s\n" "$THIS_RESULT" >&6; }
31453  else
31454    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31455printf "%s\n" "no" >&6; }
31456  fi
31457  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
31458
31459
31460if test "$PHP_FLATFILE" != "no"; then
31461
31462printf "%s\n" "#define DBA_FLATFILE 1" >>confdefs.h
31463
31464  flat_sources="libflatfile/flatfile.c"
31465  THIS_RESULT="builtin"
31466fi
31467
31468  THIS_NAME=FLATFILE
31469  if test -n "FlatFile"; then
31470    THIS_FULL_NAME="FlatFile"
31471  else
31472    THIS_FULL_NAME="$THIS_NAME"
31473  fi
31474  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $THIS_FULL_NAME support" >&5
31475printf %s "checking for $THIS_FULL_NAME support... " >&6; }
31476  if test -n ""; then
31477    as_fn_error $? "" "$LINENO" 5
31478  fi
31479  if test "$THIS_RESULT" = "yes" || test "$THIS_RESULT" = "builtin"; then
31480    HAVE_DBA=1
31481    eval HAVE_$THIS_NAME=1
31482    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $THIS_RESULT" >&5
31483printf "%s\n" "$THIS_RESULT" >&6; }
31484  else
31485    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31486printf "%s\n" "no" >&6; }
31487  fi
31488  unset THIS_RESULT THIS_NAME THIS_FULL_NAME
31489
31490
31491{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable DBA interface" >&5
31492printf %s "checking whether to enable DBA interface... " >&6; }
31493if test "$HAVE_DBA" = "1"; then
31494  if test "$ext_shared" = "yes"; then
31495    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes, shared" >&5
31496printf "%s\n" "yes, shared" >&6; }
31497  else
31498    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31499printf "%s\n" "yes" >&6; }
31500  fi
31501
31502printf "%s\n" "#define HAVE_DBA 1" >>confdefs.h
31503
31504
31505  ext_builddir=ext/dba
31506  ext_srcdir=$abs_srcdir/ext/dba
31507  ext_dir=ext/dba
31508
31509  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
31510
31511  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
31512    PHP_DBA_SHARED=no
31513
31514
31515  case $ext_dir in
31516  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
31517  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
31518  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
31519  esac
31520
31521
31522
31523  b_c_pre=$php_c_pre
31524  b_cxx_pre=$php_cxx_pre
31525  b_c_meta=$php_c_meta
31526  b_cxx_meta=$php_cxx_meta
31527  b_c_post=$php_c_post
31528  b_cxx_post=$php_cxx_post
31529  b_lo=$php_lo
31530
31531
31532  old_IFS=$IFS
31533  for ac_src in dba.c dba_cdb.c dba_dbm.c dba_gdbm.c dba_ndbm.c dba_db1.c dba_db2.c dba_db3.c dba_db4.c dba_flatfile.c dba_inifile.c dba_qdbm.c dba_tcadb.c dba_lmdb.c $cdb_sources $flat_sources $ini_sources; do
31534
31535      IFS=.
31536      set $ac_src
31537      ac_obj=$1
31538      IFS=$old_IFS
31539
31540      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
31541
31542      case $ac_src in
31543        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31544        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31545        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31546        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
31547      esac
31548
31549      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
31550
31551    cat >>Makefile.objects<<EOF
31552-include $ac_bdir$ac_obj.dep
31553$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
31554	$ac_comp
31555EOF
31556  done
31557
31558
31559    EXT_STATIC="$EXT_STATIC dba;$ext_dir"
31560    if test "$ext_shared" != "nocli"; then
31561      EXT_CLI_STATIC="$EXT_CLI_STATIC dba;$ext_dir"
31562    fi
31563  else
31564    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
31565      PHP_DBA_SHARED=yes
31566
31567  case $ext_dir in
31568  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
31569  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
31570  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
31571  esac
31572
31573
31574
31575  b_c_pre=$shared_c_pre
31576  b_cxx_pre=$shared_cxx_pre
31577  b_c_meta=$shared_c_meta
31578  b_cxx_meta=$shared_cxx_meta
31579  b_c_post=$shared_c_post
31580  b_cxx_post=$shared_cxx_post
31581  b_lo=$shared_lo
31582
31583
31584  old_IFS=$IFS
31585  for ac_src in dba.c dba_cdb.c dba_dbm.c dba_gdbm.c dba_ndbm.c dba_db1.c dba_db2.c dba_db3.c dba_db4.c dba_flatfile.c dba_inifile.c dba_qdbm.c dba_tcadb.c dba_lmdb.c $cdb_sources $flat_sources $ini_sources; do
31586
31587      IFS=.
31588      set $ac_src
31589      ac_obj=$1
31590      IFS=$old_IFS
31591
31592      shared_objects_dba="$shared_objects_dba $ac_bdir$ac_obj.lo"
31593
31594      case $ac_src in
31595        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31596        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31597        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31598        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
31599      esac
31600
31601      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
31602
31603    cat >>Makefile.objects<<EOF
31604-include $ac_bdir$ac_obj.dep
31605$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
31606	$ac_comp
31607EOF
31608  done
31609
31610
31611  install_modules="install-modules"
31612  suffix=la
31613
31614  case $host_alias in
31615    *aix*)
31616      additional_flags="-Wl,-G"
31617      ;;
31618  esac
31619
31620  if test "x" = "xyes"; then
31621    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/dba.$suffix"
31622  else
31623    PHP_MODULES="$PHP_MODULES \$(phplibdir)/dba.$suffix"
31624  fi
31625
31626  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_dba"
31627
31628  cat >>Makefile.objects<<EOF
31629\$(phplibdir)/dba.$suffix: $ext_builddir/dba.$suffix
31630	\$(LIBTOOL) --mode=install cp $ext_builddir/dba.$suffix \$(phplibdir)
31631
31632$ext_builddir/dba.$suffix: \$(shared_objects_dba) \$(DBA_SHARED_DEPENDENCIES)
31633	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_dba) \$(DBA_SHARED_LIBADD)
31634
31635EOF
31636
31637
31638printf "%s\n" "#define COMPILE_DL_DBA 1" >>confdefs.h
31639
31640    fi
31641  fi
31642
31643  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
31644    PHP_DBA_SHARED=no
31645    case "$PHP_SAPI" in
31646      cgi|embed|phpdbg)
31647
31648
31649  case $ext_dir in
31650  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
31651  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
31652  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
31653  esac
31654
31655
31656
31657  b_c_pre=$php_c_pre
31658  b_cxx_pre=$php_cxx_pre
31659  b_c_meta=$php_c_meta
31660  b_cxx_meta=$php_cxx_meta
31661  b_c_post=$php_c_post
31662  b_cxx_post=$php_cxx_post
31663  b_lo=$php_lo
31664
31665
31666  old_IFS=$IFS
31667  for ac_src in dba.c dba_cdb.c dba_dbm.c dba_gdbm.c dba_ndbm.c dba_db1.c dba_db2.c dba_db3.c dba_db4.c dba_flatfile.c dba_inifile.c dba_qdbm.c dba_tcadb.c dba_lmdb.c $cdb_sources $flat_sources $ini_sources; do
31668
31669      IFS=.
31670      set $ac_src
31671      ac_obj=$1
31672      IFS=$old_IFS
31673
31674      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
31675
31676      case $ac_src in
31677        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31678        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31679        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31680        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
31681      esac
31682
31683      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
31684
31685    cat >>Makefile.objects<<EOF
31686-include $ac_bdir$ac_obj.dep
31687$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
31688	$ac_comp
31689EOF
31690  done
31691
31692
31693        EXT_STATIC="$EXT_STATIC dba;$ext_dir"
31694        ;;
31695      *)
31696
31697
31698  case $ext_dir in
31699  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
31700  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
31701  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
31702  esac
31703
31704
31705
31706  b_c_pre=$php_c_pre
31707  b_cxx_pre=$php_cxx_pre
31708  b_c_meta=$php_c_meta
31709  b_cxx_meta=$php_cxx_meta
31710  b_c_post=$php_c_post
31711  b_cxx_post=$php_cxx_post
31712  b_lo=$php_lo
31713
31714
31715  old_IFS=$IFS
31716  for ac_src in dba.c dba_cdb.c dba_dbm.c dba_gdbm.c dba_ndbm.c dba_db1.c dba_db2.c dba_db3.c dba_db4.c dba_flatfile.c dba_inifile.c dba_qdbm.c dba_tcadb.c dba_lmdb.c $cdb_sources $flat_sources $ini_sources; do
31717
31718      IFS=.
31719      set $ac_src
31720      ac_obj=$1
31721      IFS=$old_IFS
31722
31723      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
31724
31725      case $ac_src in
31726        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31727        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31728        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
31729        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
31730      esac
31731
31732      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
31733
31734    cat >>Makefile.objects<<EOF
31735-include $ac_bdir$ac_obj.dep
31736$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
31737	$ac_comp
31738EOF
31739  done
31740
31741
31742        ;;
31743    esac
31744    EXT_CLI_STATIC="$EXT_CLI_STATIC dba;$ext_dir"
31745  fi
31746
31747
31748    BUILD_DIR="$BUILD_DIR $ext_builddir"
31749
31750
31751
31752  if test "$ext_builddir" = "."; then
31753    PHP_PECL_EXTENSION=dba
31754
31755  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
31756
31757  fi
31758
31759
31760
31761    BUILD_DIR="$BUILD_DIR $ext_builddir/libinifile"
31762
31763
31764
31765
31766    BUILD_DIR="$BUILD_DIR $ext_builddir/libcdb"
31767
31768
31769
31770
31771    BUILD_DIR="$BUILD_DIR $ext_builddir/libflatfile"
31772
31773
31774
31775  PHP_VAR_SUBST="$PHP_VAR_SUBST DBA_SHARED_LIBADD"
31776
31777else
31778  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31779printf "%s\n" "no" >&6; }
31780fi
31781
31782
31783
31784
31785
31786php_enable_dom=yes
31787
31788{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable DOM support" >&5
31789printf %s "checking whether to enable DOM support... " >&6; }
31790# Check whether --enable-dom was given.
31791if test ${enable_dom+y}
31792then :
31793  enableval=$enable_dom; PHP_DOM=$enableval
31794else $as_nop
31795
31796  PHP_DOM=yes
31797  test "$PHP_ENABLE_ALL" && PHP_DOM=$PHP_ENABLE_ALL
31798
31799fi
31800
31801
31802
31803ext_output="yes, shared"
31804ext_shared=yes
31805case $PHP_DOM in
31806shared,*)
31807  PHP_DOM=`echo "$PHP_DOM"|$SED 's/^shared,//'`
31808  ;;
31809shared)
31810  PHP_DOM=yes
31811  ;;
31812no)
31813  ext_output=no
31814  ext_shared=no
31815  ;;
31816*)
31817  ext_output=yes
31818  ext_shared=no
31819  ;;
31820esac
31821
31822
31823
31824{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
31825printf "%s\n" "$ext_output" >&6; }
31826
31827
31828
31829
31830if test "$PHP_DOM" != "no"; then
31831
31832  if test "$PHP_LIBXML" = "no"; then
31833    as_fn_error $? "DOM extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
31834  fi
31835
31836
31837
31838pkg_failed=no
31839{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
31840printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
31841
31842if test -n "$LIBXML_CFLAGS"; then
31843    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
31844 elif test -n "$PKG_CONFIG"; then
31845    if test -n "$PKG_CONFIG" && \
31846    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
31847  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
31848  ac_status=$?
31849  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
31850  test $ac_status = 0; }; then
31851  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
31852		      test "x$?" != "x0" && pkg_failed=yes
31853else
31854  pkg_failed=yes
31855fi
31856 else
31857    pkg_failed=untried
31858fi
31859if test -n "$LIBXML_LIBS"; then
31860    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
31861 elif test -n "$PKG_CONFIG"; then
31862    if test -n "$PKG_CONFIG" && \
31863    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
31864  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
31865  ac_status=$?
31866  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
31867  test $ac_status = 0; }; then
31868  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
31869		      test "x$?" != "x0" && pkg_failed=yes
31870else
31871  pkg_failed=yes
31872fi
31873 else
31874    pkg_failed=untried
31875fi
31876
31877
31878
31879if test $pkg_failed = yes; then
31880        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31881printf "%s\n" "no" >&6; }
31882
31883if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
31884        _pkg_short_errors_supported=yes
31885else
31886        _pkg_short_errors_supported=no
31887fi
31888        if test $_pkg_short_errors_supported = yes; then
31889	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
31890        else
31891	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
31892        fi
31893	# Put the nasty error message in config.log where it belongs
31894	echo "$LIBXML_PKG_ERRORS" >&5
31895
31896	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
31897
31898$LIBXML_PKG_ERRORS
31899
31900Consider adjusting the PKG_CONFIG_PATH environment variable if you
31901installed software in a non-standard prefix.
31902
31903Alternatively, you may set the environment variables LIBXML_CFLAGS
31904and LIBXML_LIBS to avoid the need to call pkg-config.
31905See the pkg-config man page for more details." "$LINENO" 5
31906elif test $pkg_failed = untried; then
31907        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
31908printf "%s\n" "no" >&6; }
31909	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
31910printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
31911as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
31912is in your PATH or set the PKG_CONFIG environment variable to the full
31913path to pkg-config.
31914
31915Alternatively, you may set the environment variables LIBXML_CFLAGS
31916and LIBXML_LIBS to avoid the need to call pkg-config.
31917See the pkg-config man page for more details.
31918
31919To get pkg-config, see <http://pkg-config.freedesktop.org/>.
31920See \`config.log' for more details" "$LINENO" 5; }
31921else
31922	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
31923	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
31924        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31925printf "%s\n" "yes" >&6; }
31926
31927fi
31928
31929
31930  for ac_i in $LIBXML_CFLAGS; do
31931    case $ac_i in
31932    -I*)
31933      ac_ii=`echo $ac_i|cut -c 3-`
31934
31935  if test "$ac_ii" != "/usr/include"; then
31936
31937  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
31938    ai_p=$ac_ii
31939  else
31940
31941    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
31942
31943    ep_realdir=`(cd "$ep_dir" && pwd)`
31944    ai_p="$ep_realdir"/`basename "$ac_ii"`
31945  fi
31946
31947
31948
31949  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
31950
31951  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
31952  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31953    eval "INCLUDEPATH$unique=set"
31954
31955      if test ""; then
31956        INCLUDES="-I$ai_p $INCLUDES"
31957      else
31958        INCLUDES="$INCLUDES -I$ai_p"
31959      fi
31960
31961  fi
31962
31963  fi
31964
31965    ;;
31966    esac
31967  done
31968
31969
31970  for ac_i in $LIBXML_LIBS; do
31971    case $ac_i in
31972    -pthread)
31973      if test "$ext_shared" = "yes"; then
31974        DOM_SHARED_LIBADD="$DOM_SHARED_LIBADD -pthread"
31975      else
31976
31977
31978  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
31979
31980  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
31981  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31982    eval "EXTRA_LDFLAGS$unique=set"
31983    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
31984  fi
31985
31986
31987
31988  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
31989
31990  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
31991  if test -n "$unique" && test "`eval $cmd`" = "" ; then
31992    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
31993    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
31994  fi
31995
31996      fi
31997    ;;
31998    -l*)
31999      ac_ii=`echo $ac_i|cut -c 3-`
32000
32001
32002  case $ac_ii in
32003  c|c_r) ;;
32004  *)
32005    if test "$ext_shared" = "yes"; then
32006        DOM_SHARED_LIBADD="$DOM_SHARED_LIBADD -l$ac_ii"
32007    else
32008
32009
32010  case $ac_ii in
32011  c|c_r) ;;
32012  *)
32013      LIBS="$LIBS -l$ac_ii"
32014   ;;
32015  esac
32016
32017
32018    fi
32019   ;;
32020  esac
32021
32022
32023    ;;
32024    -L*)
32025      ac_ii=`echo $ac_i|cut -c 3-`
32026
32027  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
32028
32029  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32030    ai_p=$ac_ii
32031  else
32032
32033    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32034
32035    ep_realdir=`(cd "$ep_dir" && pwd)`
32036    ai_p="$ep_realdir"/`basename "$ac_ii"`
32037  fi
32038
32039
32040      if test "$ext_shared" = "yes"; then
32041        DOM_SHARED_LIBADD="-L$ai_p $DOM_SHARED_LIBADD"
32042        test -n "$ld_runpath_switch" && DOM_SHARED_LIBADD="$ld_runpath_switch$ai_p $DOM_SHARED_LIBADD"
32043      else
32044
32045
32046
32047  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
32048
32049  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
32050  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32051    eval "LIBPATH$unique=set"
32052
32053    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
32054    LDFLAGS="$LDFLAGS -L$ai_p"
32055    PHP_RPATHS="$PHP_RPATHS $ai_p"
32056
32057  fi
32058
32059
32060      fi
32061
32062  fi
32063
32064    ;;
32065    esac
32066  done
32067
32068
32069
32070printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
32071
32072
32073
32074
32075printf "%s\n" "#define HAVE_DOM 1" >>confdefs.h
32076
32077
32078  ext_builddir=ext/dom
32079  ext_srcdir=$abs_srcdir/ext/dom
32080  ext_dir=ext/dom
32081
32082  ac_extra=
32083
32084  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
32085    PHP_DOM_SHARED=no
32086
32087
32088  case $ext_dir in
32089  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
32090  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
32091  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
32092  esac
32093
32094
32095
32096  b_c_pre=$php_c_pre
32097  b_cxx_pre=$php_cxx_pre
32098  b_c_meta=$php_c_meta
32099  b_cxx_meta=$php_cxx_meta
32100  b_c_post=$php_c_post
32101  b_cxx_post=$php_cxx_post
32102  b_lo=$php_lo
32103
32104
32105  old_IFS=$IFS
32106  for ac_src in php_dom.c attr.c document.c \
32107                            domexception.c parentnode.c \
32108                            processinginstruction.c cdatasection.c \
32109                            documentfragment.c domimplementation.c \
32110                            element.c node.c characterdata.c \
32111                            documenttype.c entity.c \
32112                            nodelist.c text.c comment.c \
32113                            entityreference.c \
32114                            notation.c xpath.c dom_iterators.c \
32115                            namednodemap.c; do
32116
32117      IFS=.
32118      set $ac_src
32119      ac_obj=$1
32120      IFS=$old_IFS
32121
32122      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
32123
32124      case $ac_src in
32125        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32126        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32127        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32128        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
32129      esac
32130
32131      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
32132
32133    cat >>Makefile.objects<<EOF
32134-include $ac_bdir$ac_obj.dep
32135$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
32136	$ac_comp
32137EOF
32138  done
32139
32140
32141    EXT_STATIC="$EXT_STATIC dom;$ext_dir"
32142    if test "$ext_shared" != "nocli"; then
32143      EXT_CLI_STATIC="$EXT_CLI_STATIC dom;$ext_dir"
32144    fi
32145  else
32146    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
32147      PHP_DOM_SHARED=yes
32148
32149  case $ext_dir in
32150  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
32151  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
32152  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
32153  esac
32154
32155
32156
32157  b_c_pre=$shared_c_pre
32158  b_cxx_pre=$shared_cxx_pre
32159  b_c_meta=$shared_c_meta
32160  b_cxx_meta=$shared_cxx_meta
32161  b_c_post=$shared_c_post
32162  b_cxx_post=$shared_cxx_post
32163  b_lo=$shared_lo
32164
32165
32166  old_IFS=$IFS
32167  for ac_src in php_dom.c attr.c document.c \
32168                            domexception.c parentnode.c \
32169                            processinginstruction.c cdatasection.c \
32170                            documentfragment.c domimplementation.c \
32171                            element.c node.c characterdata.c \
32172                            documenttype.c entity.c \
32173                            nodelist.c text.c comment.c \
32174                            entityreference.c \
32175                            notation.c xpath.c dom_iterators.c \
32176                            namednodemap.c; do
32177
32178      IFS=.
32179      set $ac_src
32180      ac_obj=$1
32181      IFS=$old_IFS
32182
32183      shared_objects_dom="$shared_objects_dom $ac_bdir$ac_obj.lo"
32184
32185      case $ac_src in
32186        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32187        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32188        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32189        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
32190      esac
32191
32192      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
32193
32194    cat >>Makefile.objects<<EOF
32195-include $ac_bdir$ac_obj.dep
32196$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
32197	$ac_comp
32198EOF
32199  done
32200
32201
32202  install_modules="install-modules"
32203  suffix=la
32204
32205  case $host_alias in
32206    *aix*)
32207      additional_flags="-Wl,-G"
32208      ;;
32209  esac
32210
32211  if test "x" = "xyes"; then
32212    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/dom.$suffix"
32213  else
32214    PHP_MODULES="$PHP_MODULES \$(phplibdir)/dom.$suffix"
32215  fi
32216
32217  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_dom"
32218
32219  cat >>Makefile.objects<<EOF
32220\$(phplibdir)/dom.$suffix: $ext_builddir/dom.$suffix
32221	\$(LIBTOOL) --mode=install cp $ext_builddir/dom.$suffix \$(phplibdir)
32222
32223$ext_builddir/dom.$suffix: \$(shared_objects_dom) \$(DOM_SHARED_DEPENDENCIES)
32224	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_dom) \$(DOM_SHARED_LIBADD)
32225
32226EOF
32227
32228
32229printf "%s\n" "#define COMPILE_DL_DOM 1" >>confdefs.h
32230
32231    fi
32232  fi
32233
32234  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
32235    PHP_DOM_SHARED=no
32236    case "$PHP_SAPI" in
32237      cgi|embed|phpdbg)
32238
32239
32240  case $ext_dir in
32241  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
32242  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
32243  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
32244  esac
32245
32246
32247
32248  b_c_pre=$php_c_pre
32249  b_cxx_pre=$php_cxx_pre
32250  b_c_meta=$php_c_meta
32251  b_cxx_meta=$php_cxx_meta
32252  b_c_post=$php_c_post
32253  b_cxx_post=$php_cxx_post
32254  b_lo=$php_lo
32255
32256
32257  old_IFS=$IFS
32258  for ac_src in php_dom.c attr.c document.c \
32259                            domexception.c parentnode.c \
32260                            processinginstruction.c cdatasection.c \
32261                            documentfragment.c domimplementation.c \
32262                            element.c node.c characterdata.c \
32263                            documenttype.c entity.c \
32264                            nodelist.c text.c comment.c \
32265                            entityreference.c \
32266                            notation.c xpath.c dom_iterators.c \
32267                            namednodemap.c; do
32268
32269      IFS=.
32270      set $ac_src
32271      ac_obj=$1
32272      IFS=$old_IFS
32273
32274      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
32275
32276      case $ac_src in
32277        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32278        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32279        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32280        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
32281      esac
32282
32283      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
32284
32285    cat >>Makefile.objects<<EOF
32286-include $ac_bdir$ac_obj.dep
32287$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
32288	$ac_comp
32289EOF
32290  done
32291
32292
32293        EXT_STATIC="$EXT_STATIC dom;$ext_dir"
32294        ;;
32295      *)
32296
32297
32298  case $ext_dir in
32299  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
32300  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
32301  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
32302  esac
32303
32304
32305
32306  b_c_pre=$php_c_pre
32307  b_cxx_pre=$php_cxx_pre
32308  b_c_meta=$php_c_meta
32309  b_cxx_meta=$php_cxx_meta
32310  b_c_post=$php_c_post
32311  b_cxx_post=$php_cxx_post
32312  b_lo=$php_lo
32313
32314
32315  old_IFS=$IFS
32316  for ac_src in php_dom.c attr.c document.c \
32317                            domexception.c parentnode.c \
32318                            processinginstruction.c cdatasection.c \
32319                            documentfragment.c domimplementation.c \
32320                            element.c node.c characterdata.c \
32321                            documenttype.c entity.c \
32322                            nodelist.c text.c comment.c \
32323                            entityreference.c \
32324                            notation.c xpath.c dom_iterators.c \
32325                            namednodemap.c; do
32326
32327      IFS=.
32328      set $ac_src
32329      ac_obj=$1
32330      IFS=$old_IFS
32331
32332      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
32333
32334      case $ac_src in
32335        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32336        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32337        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
32338        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
32339      esac
32340
32341      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
32342
32343    cat >>Makefile.objects<<EOF
32344-include $ac_bdir$ac_obj.dep
32345$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
32346	$ac_comp
32347EOF
32348  done
32349
32350
32351        ;;
32352    esac
32353    EXT_CLI_STATIC="$EXT_CLI_STATIC dom;$ext_dir"
32354  fi
32355
32356
32357    BUILD_DIR="$BUILD_DIR $ext_builddir"
32358
32359
32360
32361  if test "$ext_builddir" = "."; then
32362    PHP_PECL_EXTENSION=dom
32363
32364  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
32365
32366  fi
32367
32368
32369  PHP_VAR_SUBST="$PHP_VAR_SUBST DOM_SHARED_LIBADD"
32370
32371
32372
32373    for header_file in ext/dom/xml_common.h; do
32374
32375
32376  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
32377
32378  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
32379  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32380    eval "INSTALLHEADERS$unique=set"
32381
32382        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
32383
32384  fi
32385
32386    done
32387
32388
32389
32390  am_i_shared=$PHP_DOM_SHARED
32391  is_it_shared=$PHP_LIBXML_SHARED
32392  is_it_enabled=$PHP_LIBXML
32393  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
32394    as_fn_error $? "
32395You've configured extension dom to build statically, but it
32396depends on extension libxml, which you've configured to build shared.
32397You either need to build dom shared or build libxml statically for the
32398build to be successful.
32399" "$LINENO" 5
32400  fi
32401  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
32402    as_fn_error $? "
32403You've configured extension dom, which depends on extension libxml,
32404but you've either not enabled libxml, or have disabled it.
32405" "$LINENO" 5
32406  fi
32407
32408
32409
32410fi
32411
32412
32413
32414
32415
32416php_with_enchant=no
32417
32418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with Enchant support" >&5
32419printf %s "checking whether to build with Enchant support... " >&6; }
32420
32421# Check whether --with-enchant was given.
32422if test ${with_enchant+y}
32423then :
32424  withval=$with_enchant; PHP_ENCHANT=$withval
32425else $as_nop
32426
32427  PHP_ENCHANT=no
32428  test "$PHP_ENABLE_ALL" && PHP_ENCHANT=$PHP_ENABLE_ALL
32429
32430fi
32431
32432
32433
32434ext_output="yes, shared"
32435ext_shared=yes
32436case $PHP_ENCHANT in
32437shared,*)
32438  PHP_ENCHANT=`echo "$PHP_ENCHANT"|$SED 's/^shared,//'`
32439  ;;
32440shared)
32441  PHP_ENCHANT=yes
32442  ;;
32443no)
32444  ext_output=no
32445  ext_shared=no
32446  ;;
32447*)
32448  ext_output=yes
32449  ext_shared=no
32450  ;;
32451esac
32452
32453
32454
32455{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
32456printf "%s\n" "$ext_output" >&6; }
32457
32458
32459
32460
32461if test "$PHP_ENCHANT" != "no"; then
32462
32463pkg_failed=no
32464{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for enchant-2" >&5
32465printf %s "checking for enchant-2... " >&6; }
32466
32467if test -n "$ENCHANT2_CFLAGS"; then
32468    pkg_cv_ENCHANT2_CFLAGS="$ENCHANT2_CFLAGS"
32469 elif test -n "$PKG_CONFIG"; then
32470    if test -n "$PKG_CONFIG" && \
32471    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"enchant-2\""; } >&5
32472  ($PKG_CONFIG --exists --print-errors "enchant-2") 2>&5
32473  ac_status=$?
32474  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32475  test $ac_status = 0; }; then
32476  pkg_cv_ENCHANT2_CFLAGS=`$PKG_CONFIG --cflags "enchant-2" 2>/dev/null`
32477		      test "x$?" != "x0" && pkg_failed=yes
32478else
32479  pkg_failed=yes
32480fi
32481 else
32482    pkg_failed=untried
32483fi
32484if test -n "$ENCHANT2_LIBS"; then
32485    pkg_cv_ENCHANT2_LIBS="$ENCHANT2_LIBS"
32486 elif test -n "$PKG_CONFIG"; then
32487    if test -n "$PKG_CONFIG" && \
32488    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"enchant-2\""; } >&5
32489  ($PKG_CONFIG --exists --print-errors "enchant-2") 2>&5
32490  ac_status=$?
32491  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32492  test $ac_status = 0; }; then
32493  pkg_cv_ENCHANT2_LIBS=`$PKG_CONFIG --libs "enchant-2" 2>/dev/null`
32494		      test "x$?" != "x0" && pkg_failed=yes
32495else
32496  pkg_failed=yes
32497fi
32498 else
32499    pkg_failed=untried
32500fi
32501
32502
32503
32504if test $pkg_failed = yes; then
32505        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32506printf "%s\n" "no" >&6; }
32507
32508if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
32509        _pkg_short_errors_supported=yes
32510else
32511        _pkg_short_errors_supported=no
32512fi
32513        if test $_pkg_short_errors_supported = yes; then
32514	        ENCHANT2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "enchant-2" 2>&1`
32515        else
32516	        ENCHANT2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "enchant-2" 2>&1`
32517        fi
32518	# Put the nasty error message in config.log where it belongs
32519	echo "$ENCHANT2_PKG_ERRORS" >&5
32520
32521	found_enchant_2=no
32522elif test $pkg_failed = untried; then
32523        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32524printf "%s\n" "no" >&6; }
32525	found_enchant_2=no
32526else
32527	ENCHANT2_CFLAGS=$pkg_cv_ENCHANT2_CFLAGS
32528	ENCHANT2_LIBS=$pkg_cv_ENCHANT2_LIBS
32529        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32530printf "%s\n" "yes" >&6; }
32531	found_enchant_2=yes
32532fi
32533
32534  if test "$found_enchant_2" = "yes"; then
32535
32536
32537  for ac_i in $ENCHANT2_CFLAGS; do
32538    case $ac_i in
32539    -I*)
32540      ac_ii=`echo $ac_i|cut -c 3-`
32541
32542  if test "$ac_ii" != "/usr/include"; then
32543
32544  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32545    ai_p=$ac_ii
32546  else
32547
32548    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32549
32550    ep_realdir=`(cd "$ep_dir" && pwd)`
32551    ai_p="$ep_realdir"/`basename "$ac_ii"`
32552  fi
32553
32554
32555
32556  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
32557
32558  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
32559  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32560    eval "INCLUDEPATH$unique=set"
32561
32562      if test ""; then
32563        INCLUDES="-I$ai_p $INCLUDES"
32564      else
32565        INCLUDES="$INCLUDES -I$ai_p"
32566      fi
32567
32568  fi
32569
32570  fi
32571
32572    ;;
32573    esac
32574  done
32575
32576
32577  for ac_i in $ENCHANT2_LIBS; do
32578    case $ac_i in
32579    -pthread)
32580      if test "$ext_shared" = "yes"; then
32581        ENCHANT_SHARED_LIBADD="$ENCHANT_SHARED_LIBADD -pthread"
32582      else
32583
32584
32585  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32586
32587  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
32588  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32589    eval "EXTRA_LDFLAGS$unique=set"
32590    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
32591  fi
32592
32593
32594
32595  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32596
32597  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
32598  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32599    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
32600    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
32601  fi
32602
32603      fi
32604    ;;
32605    -l*)
32606      ac_ii=`echo $ac_i|cut -c 3-`
32607
32608
32609  case $ac_ii in
32610  c|c_r) ;;
32611  *)
32612    if test "$ext_shared" = "yes"; then
32613        ENCHANT_SHARED_LIBADD="$ENCHANT_SHARED_LIBADD -l$ac_ii"
32614    else
32615
32616
32617  case $ac_ii in
32618  c|c_r) ;;
32619  *)
32620      LIBS="$LIBS -l$ac_ii"
32621   ;;
32622  esac
32623
32624
32625    fi
32626   ;;
32627  esac
32628
32629
32630    ;;
32631    -L*)
32632      ac_ii=`echo $ac_i|cut -c 3-`
32633
32634  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
32635
32636  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32637    ai_p=$ac_ii
32638  else
32639
32640    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32641
32642    ep_realdir=`(cd "$ep_dir" && pwd)`
32643    ai_p="$ep_realdir"/`basename "$ac_ii"`
32644  fi
32645
32646
32647      if test "$ext_shared" = "yes"; then
32648        ENCHANT_SHARED_LIBADD="-L$ai_p $ENCHANT_SHARED_LIBADD"
32649        test -n "$ld_runpath_switch" && ENCHANT_SHARED_LIBADD="$ld_runpath_switch$ai_p $ENCHANT_SHARED_LIBADD"
32650      else
32651
32652
32653
32654  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
32655
32656  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
32657  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32658    eval "LIBPATH$unique=set"
32659
32660    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
32661    LDFLAGS="$LDFLAGS -L$ai_p"
32662    PHP_RPATHS="$PHP_RPATHS $ai_p"
32663
32664  fi
32665
32666
32667      fi
32668
32669  fi
32670
32671    ;;
32672    esac
32673  done
32674
32675
32676
32677printf "%s\n" "#define HAVE_ENCHANT_GET_VERSION 1" >>confdefs.h
32678
32679
32680  else
32681    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: libenchant-2 not found trying with old libenchant" >&5
32682printf "%s\n" "$as_me: WARNING: libenchant-2 not found trying with old libenchant" >&2;}
32683
32684pkg_failed=no
32685{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for enchant >= 1.4.2" >&5
32686printf %s "checking for enchant >= 1.4.2... " >&6; }
32687
32688if test -n "$ENCHANT_CFLAGS"; then
32689    pkg_cv_ENCHANT_CFLAGS="$ENCHANT_CFLAGS"
32690 elif test -n "$PKG_CONFIG"; then
32691    if test -n "$PKG_CONFIG" && \
32692    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"enchant >= 1.4.2\""; } >&5
32693  ($PKG_CONFIG --exists --print-errors "enchant >= 1.4.2") 2>&5
32694  ac_status=$?
32695  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32696  test $ac_status = 0; }; then
32697  pkg_cv_ENCHANT_CFLAGS=`$PKG_CONFIG --cflags "enchant >= 1.4.2" 2>/dev/null`
32698		      test "x$?" != "x0" && pkg_failed=yes
32699else
32700  pkg_failed=yes
32701fi
32702 else
32703    pkg_failed=untried
32704fi
32705if test -n "$ENCHANT_LIBS"; then
32706    pkg_cv_ENCHANT_LIBS="$ENCHANT_LIBS"
32707 elif test -n "$PKG_CONFIG"; then
32708    if test -n "$PKG_CONFIG" && \
32709    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"enchant >= 1.4.2\""; } >&5
32710  ($PKG_CONFIG --exists --print-errors "enchant >= 1.4.2") 2>&5
32711  ac_status=$?
32712  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32713  test $ac_status = 0; }; then
32714  pkg_cv_ENCHANT_LIBS=`$PKG_CONFIG --libs "enchant >= 1.4.2" 2>/dev/null`
32715		      test "x$?" != "x0" && pkg_failed=yes
32716else
32717  pkg_failed=yes
32718fi
32719 else
32720    pkg_failed=untried
32721fi
32722
32723
32724
32725if test $pkg_failed = yes; then
32726        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32727printf "%s\n" "no" >&6; }
32728
32729if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
32730        _pkg_short_errors_supported=yes
32731else
32732        _pkg_short_errors_supported=no
32733fi
32734        if test $_pkg_short_errors_supported = yes; then
32735	        ENCHANT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "enchant >= 1.4.2" 2>&1`
32736        else
32737	        ENCHANT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "enchant >= 1.4.2" 2>&1`
32738        fi
32739	# Put the nasty error message in config.log where it belongs
32740	echo "$ENCHANT_PKG_ERRORS" >&5
32741
32742	as_fn_error $? "Package requirements (enchant >= 1.4.2) were not met:
32743
32744$ENCHANT_PKG_ERRORS
32745
32746Consider adjusting the PKG_CONFIG_PATH environment variable if you
32747installed software in a non-standard prefix.
32748
32749Alternatively, you may set the environment variables ENCHANT_CFLAGS
32750and ENCHANT_LIBS to avoid the need to call pkg-config.
32751See the pkg-config man page for more details." "$LINENO" 5
32752elif test $pkg_failed = untried; then
32753        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
32754printf "%s\n" "no" >&6; }
32755	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
32756printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
32757as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
32758is in your PATH or set the PKG_CONFIG environment variable to the full
32759path to pkg-config.
32760
32761Alternatively, you may set the environment variables ENCHANT_CFLAGS
32762and ENCHANT_LIBS to avoid the need to call pkg-config.
32763See the pkg-config man page for more details.
32764
32765To get pkg-config, see <http://pkg-config.freedesktop.org/>.
32766See \`config.log' for more details" "$LINENO" 5; }
32767else
32768	ENCHANT_CFLAGS=$pkg_cv_ENCHANT_CFLAGS
32769	ENCHANT_LIBS=$pkg_cv_ENCHANT_LIBS
32770        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32771printf "%s\n" "yes" >&6; }
32772
32773fi
32774
32775
32776  for ac_i in $ENCHANT_CFLAGS; do
32777    case $ac_i in
32778    -I*)
32779      ac_ii=`echo $ac_i|cut -c 3-`
32780
32781  if test "$ac_ii" != "/usr/include"; then
32782
32783  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32784    ai_p=$ac_ii
32785  else
32786
32787    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32788
32789    ep_realdir=`(cd "$ep_dir" && pwd)`
32790    ai_p="$ep_realdir"/`basename "$ac_ii"`
32791  fi
32792
32793
32794
32795  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
32796
32797  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
32798  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32799    eval "INCLUDEPATH$unique=set"
32800
32801      if test ""; then
32802        INCLUDES="-I$ai_p $INCLUDES"
32803      else
32804        INCLUDES="$INCLUDES -I$ai_p"
32805      fi
32806
32807  fi
32808
32809  fi
32810
32811    ;;
32812    esac
32813  done
32814
32815
32816  for ac_i in $ENCHANT_LIBS; do
32817    case $ac_i in
32818    -pthread)
32819      if test "$ext_shared" = "yes"; then
32820        ENCHANT_SHARED_LIBADD="$ENCHANT_SHARED_LIBADD -pthread"
32821      else
32822
32823
32824  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32825
32826  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
32827  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32828    eval "EXTRA_LDFLAGS$unique=set"
32829    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
32830  fi
32831
32832
32833
32834  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32835
32836  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
32837  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32838    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
32839    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
32840  fi
32841
32842      fi
32843    ;;
32844    -l*)
32845      ac_ii=`echo $ac_i|cut -c 3-`
32846
32847
32848  case $ac_ii in
32849  c|c_r) ;;
32850  *)
32851    if test "$ext_shared" = "yes"; then
32852        ENCHANT_SHARED_LIBADD="$ENCHANT_SHARED_LIBADD -l$ac_ii"
32853    else
32854
32855
32856  case $ac_ii in
32857  c|c_r) ;;
32858  *)
32859      LIBS="$LIBS -l$ac_ii"
32860   ;;
32861  esac
32862
32863
32864    fi
32865   ;;
32866  esac
32867
32868
32869    ;;
32870    -L*)
32871      ac_ii=`echo $ac_i|cut -c 3-`
32872
32873  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
32874
32875  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32876    ai_p=$ac_ii
32877  else
32878
32879    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32880
32881    ep_realdir=`(cd "$ep_dir" && pwd)`
32882    ai_p="$ep_realdir"/`basename "$ac_ii"`
32883  fi
32884
32885
32886      if test "$ext_shared" = "yes"; then
32887        ENCHANT_SHARED_LIBADD="-L$ai_p $ENCHANT_SHARED_LIBADD"
32888        test -n "$ld_runpath_switch" && ENCHANT_SHARED_LIBADD="$ld_runpath_switch$ai_p $ENCHANT_SHARED_LIBADD"
32889      else
32890
32891
32892
32893  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
32894
32895  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
32896  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32897    eval "LIBPATH$unique=set"
32898
32899    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
32900    LDFLAGS="$LDFLAGS -L$ai_p"
32901    PHP_RPATHS="$PHP_RPATHS $ai_p"
32902
32903  fi
32904
32905
32906      fi
32907
32908  fi
32909
32910    ;;
32911    esac
32912  done
32913
32914
32915
32916  save_old_LDFLAGS=$LDFLAGS
32917  ac_stuff="
32918      $ENCHANT_LIBS
32919    "
32920
32921  save_ext_shared=$ext_shared
32922  ext_shared=yes
32923
32924  for ac_i in $ac_stuff; do
32925    case $ac_i in
32926    -pthread)
32927      if test "$ext_shared" = "yes"; then
32928        LDFLAGS="$LDFLAGS -pthread"
32929      else
32930
32931
32932  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32933
32934  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
32935  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32936    eval "EXTRA_LDFLAGS$unique=set"
32937    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
32938  fi
32939
32940
32941
32942  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
32943
32944  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
32945  if test -n "$unique" && test "`eval $cmd`" = "" ; then
32946    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
32947    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
32948  fi
32949
32950      fi
32951    ;;
32952    -l*)
32953      ac_ii=`echo $ac_i|cut -c 3-`
32954
32955
32956  case $ac_ii in
32957  c|c_r) ;;
32958  *)
32959    if test "$ext_shared" = "yes"; then
32960        LDFLAGS="$LDFLAGS -l$ac_ii"
32961    else
32962
32963
32964  case $ac_ii in
32965  c|c_r) ;;
32966  *)
32967      LIBS="$LIBS -l$ac_ii"
32968   ;;
32969  esac
32970
32971
32972    fi
32973   ;;
32974  esac
32975
32976
32977    ;;
32978    -L*)
32979      ac_ii=`echo $ac_i|cut -c 3-`
32980
32981  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
32982
32983  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
32984    ai_p=$ac_ii
32985  else
32986
32987    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
32988
32989    ep_realdir=`(cd "$ep_dir" && pwd)`
32990    ai_p="$ep_realdir"/`basename "$ac_ii"`
32991  fi
32992
32993
32994      if test "$ext_shared" = "yes"; then
32995        LDFLAGS="-L$ai_p $LDFLAGS"
32996        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
32997      else
32998
32999
33000
33001  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
33002
33003  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
33004  if test -n "$unique" && test "`eval $cmd`" = "" ; then
33005    eval "LIBPATH$unique=set"
33006
33007    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
33008    LDFLAGS="$LDFLAGS -L$ai_p"
33009    PHP_RPATHS="$PHP_RPATHS $ai_p"
33010
33011  fi
33012
33013
33014      fi
33015
33016  fi
33017
33018    ;;
33019    esac
33020  done
33021
33022  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for enchant_get_version in -lenchant" >&5
33023printf %s "checking for enchant_get_version in -lenchant... " >&6; }
33024if test ${ac_cv_lib_enchant_enchant_get_version+y}
33025then :
33026  printf %s "(cached) " >&6
33027else $as_nop
33028  ac_check_lib_save_LIBS=$LIBS
33029LIBS="-lenchant  $LIBS"
33030cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33031/* end confdefs.h.  */
33032
33033/* Override any GCC internal prototype to avoid an error.
33034   Use char because int might match the return type of a GCC
33035   builtin and then its argument prototype would still apply.  */
33036char enchant_get_version ();
33037int
33038main (void)
33039{
33040return enchant_get_version ();
33041  ;
33042  return 0;
33043}
33044_ACEOF
33045if ac_fn_c_try_link "$LINENO"
33046then :
33047  ac_cv_lib_enchant_enchant_get_version=yes
33048else $as_nop
33049  ac_cv_lib_enchant_enchant_get_version=no
33050fi
33051rm -f core conftest.err conftest.$ac_objext conftest.beam \
33052    conftest$ac_exeext conftest.$ac_ext
33053LIBS=$ac_check_lib_save_LIBS
33054fi
33055{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_enchant_enchant_get_version" >&5
33056printf "%s\n" "$ac_cv_lib_enchant_enchant_get_version" >&6; }
33057if test "x$ac_cv_lib_enchant_enchant_get_version" = xyes
33058then :
33059
33060    LDFLAGS=$save_old_LDFLAGS
33061    ext_shared=$save_ext_shared
33062
33063
33064printf "%s\n" "#define HAVE_ENCHANT_GET_VERSION 1" >>confdefs.h
33065
33066
33067
33068else $as_nop
33069
33070    LDFLAGS=$save_old_LDFLAGS
33071    ext_shared=$save_ext_shared
33072    unset ac_cv_lib_enchant_enchant_get_version
33073
33074
33075fi
33076
33077
33078
33079  save_old_LDFLAGS=$LDFLAGS
33080  ac_stuff="
33081      $ENCHANT_LIBS
33082    "
33083
33084  save_ext_shared=$ext_shared
33085  ext_shared=yes
33086
33087  for ac_i in $ac_stuff; do
33088    case $ac_i in
33089    -pthread)
33090      if test "$ext_shared" = "yes"; then
33091        LDFLAGS="$LDFLAGS -pthread"
33092      else
33093
33094
33095  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
33096
33097  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
33098  if test -n "$unique" && test "`eval $cmd`" = "" ; then
33099    eval "EXTRA_LDFLAGS$unique=set"
33100    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
33101  fi
33102
33103
33104
33105  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
33106
33107  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
33108  if test -n "$unique" && test "`eval $cmd`" = "" ; then
33109    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
33110    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
33111  fi
33112
33113      fi
33114    ;;
33115    -l*)
33116      ac_ii=`echo $ac_i|cut -c 3-`
33117
33118
33119  case $ac_ii in
33120  c|c_r) ;;
33121  *)
33122    if test "$ext_shared" = "yes"; then
33123        LDFLAGS="$LDFLAGS -l$ac_ii"
33124    else
33125
33126
33127  case $ac_ii in
33128  c|c_r) ;;
33129  *)
33130      LIBS="$LIBS -l$ac_ii"
33131   ;;
33132  esac
33133
33134
33135    fi
33136   ;;
33137  esac
33138
33139
33140    ;;
33141    -L*)
33142      ac_ii=`echo $ac_i|cut -c 3-`
33143
33144  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
33145
33146  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
33147    ai_p=$ac_ii
33148  else
33149
33150    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
33151
33152    ep_realdir=`(cd "$ep_dir" && pwd)`
33153    ai_p="$ep_realdir"/`basename "$ac_ii"`
33154  fi
33155
33156
33157      if test "$ext_shared" = "yes"; then
33158        LDFLAGS="-L$ai_p $LDFLAGS"
33159        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
33160      else
33161
33162
33163
33164  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
33165
33166  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
33167  if test -n "$unique" && test "`eval $cmd`" = "" ; then
33168    eval "LIBPATH$unique=set"
33169
33170    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
33171    LDFLAGS="$LDFLAGS -L$ai_p"
33172    PHP_RPATHS="$PHP_RPATHS $ai_p"
33173
33174  fi
33175
33176
33177      fi
33178
33179  fi
33180
33181    ;;
33182    esac
33183  done
33184
33185  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for enchant_broker_set_param in -lenchant" >&5
33186printf %s "checking for enchant_broker_set_param in -lenchant... " >&6; }
33187if test ${ac_cv_lib_enchant_enchant_broker_set_param+y}
33188then :
33189  printf %s "(cached) " >&6
33190else $as_nop
33191  ac_check_lib_save_LIBS=$LIBS
33192LIBS="-lenchant  $LIBS"
33193cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33194/* end confdefs.h.  */
33195
33196/* Override any GCC internal prototype to avoid an error.
33197   Use char because int might match the return type of a GCC
33198   builtin and then its argument prototype would still apply.  */
33199char enchant_broker_set_param ();
33200int
33201main (void)
33202{
33203return enchant_broker_set_param ();
33204  ;
33205  return 0;
33206}
33207_ACEOF
33208if ac_fn_c_try_link "$LINENO"
33209then :
33210  ac_cv_lib_enchant_enchant_broker_set_param=yes
33211else $as_nop
33212  ac_cv_lib_enchant_enchant_broker_set_param=no
33213fi
33214rm -f core conftest.err conftest.$ac_objext conftest.beam \
33215    conftest$ac_exeext conftest.$ac_ext
33216LIBS=$ac_check_lib_save_LIBS
33217fi
33218{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_enchant_enchant_broker_set_param" >&5
33219printf "%s\n" "$ac_cv_lib_enchant_enchant_broker_set_param" >&6; }
33220if test "x$ac_cv_lib_enchant_enchant_broker_set_param" = xyes
33221then :
33222
33223    LDFLAGS=$save_old_LDFLAGS
33224    ext_shared=$save_ext_shared
33225
33226
33227printf "%s\n" "#define HAVE_ENCHANT_BROKER_SET_PARAM 1" >>confdefs.h
33228
33229
33230
33231else $as_nop
33232
33233    LDFLAGS=$save_old_LDFLAGS
33234    ext_shared=$save_ext_shared
33235    unset ac_cv_lib_enchant_enchant_broker_set_param
33236
33237
33238fi
33239
33240  fi
33241
33242
33243printf "%s\n" "#define HAVE_ENCHANT 1" >>confdefs.h
33244
33245
33246
33247  ext_builddir=ext/enchant
33248  ext_srcdir=$abs_srcdir/ext/enchant
33249  ext_dir=ext/enchant
33250
33251  ac_extra=
33252
33253  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
33254    PHP_ENCHANT_SHARED=no
33255
33256
33257  case $ext_dir in
33258  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33259  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33260  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33261  esac
33262
33263
33264
33265  b_c_pre=$php_c_pre
33266  b_cxx_pre=$php_cxx_pre
33267  b_c_meta=$php_c_meta
33268  b_cxx_meta=$php_cxx_meta
33269  b_c_post=$php_c_post
33270  b_cxx_post=$php_cxx_post
33271  b_lo=$php_lo
33272
33273
33274  old_IFS=$IFS
33275  for ac_src in enchant.c; do
33276
33277      IFS=.
33278      set $ac_src
33279      ac_obj=$1
33280      IFS=$old_IFS
33281
33282      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33283
33284      case $ac_src in
33285        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33286        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33287        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33288        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33289      esac
33290
33291      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33292
33293    cat >>Makefile.objects<<EOF
33294-include $ac_bdir$ac_obj.dep
33295$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33296	$ac_comp
33297EOF
33298  done
33299
33300
33301    EXT_STATIC="$EXT_STATIC enchant;$ext_dir"
33302    if test "$ext_shared" != "nocli"; then
33303      EXT_CLI_STATIC="$EXT_CLI_STATIC enchant;$ext_dir"
33304    fi
33305  else
33306    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
33307      PHP_ENCHANT_SHARED=yes
33308
33309  case $ext_dir in
33310  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33311  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33312  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33313  esac
33314
33315
33316
33317  b_c_pre=$shared_c_pre
33318  b_cxx_pre=$shared_cxx_pre
33319  b_c_meta=$shared_c_meta
33320  b_cxx_meta=$shared_cxx_meta
33321  b_c_post=$shared_c_post
33322  b_cxx_post=$shared_cxx_post
33323  b_lo=$shared_lo
33324
33325
33326  old_IFS=$IFS
33327  for ac_src in enchant.c; do
33328
33329      IFS=.
33330      set $ac_src
33331      ac_obj=$1
33332      IFS=$old_IFS
33333
33334      shared_objects_enchant="$shared_objects_enchant $ac_bdir$ac_obj.lo"
33335
33336      case $ac_src in
33337        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33338        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33339        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33340        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33341      esac
33342
33343      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33344
33345    cat >>Makefile.objects<<EOF
33346-include $ac_bdir$ac_obj.dep
33347$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33348	$ac_comp
33349EOF
33350  done
33351
33352
33353  install_modules="install-modules"
33354  suffix=la
33355
33356  case $host_alias in
33357    *aix*)
33358      additional_flags="-Wl,-G"
33359      ;;
33360  esac
33361
33362  if test "x" = "xyes"; then
33363    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/enchant.$suffix"
33364  else
33365    PHP_MODULES="$PHP_MODULES \$(phplibdir)/enchant.$suffix"
33366  fi
33367
33368  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_enchant"
33369
33370  cat >>Makefile.objects<<EOF
33371\$(phplibdir)/enchant.$suffix: $ext_builddir/enchant.$suffix
33372	\$(LIBTOOL) --mode=install cp $ext_builddir/enchant.$suffix \$(phplibdir)
33373
33374$ext_builddir/enchant.$suffix: \$(shared_objects_enchant) \$(ENCHANT_SHARED_DEPENDENCIES)
33375	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_enchant) \$(ENCHANT_SHARED_LIBADD)
33376
33377EOF
33378
33379
33380printf "%s\n" "#define COMPILE_DL_ENCHANT 1" >>confdefs.h
33381
33382    fi
33383  fi
33384
33385  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
33386    PHP_ENCHANT_SHARED=no
33387    case "$PHP_SAPI" in
33388      cgi|embed|phpdbg)
33389
33390
33391  case $ext_dir in
33392  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33393  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33394  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33395  esac
33396
33397
33398
33399  b_c_pre=$php_c_pre
33400  b_cxx_pre=$php_cxx_pre
33401  b_c_meta=$php_c_meta
33402  b_cxx_meta=$php_cxx_meta
33403  b_c_post=$php_c_post
33404  b_cxx_post=$php_cxx_post
33405  b_lo=$php_lo
33406
33407
33408  old_IFS=$IFS
33409  for ac_src in enchant.c; do
33410
33411      IFS=.
33412      set $ac_src
33413      ac_obj=$1
33414      IFS=$old_IFS
33415
33416      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33417
33418      case $ac_src in
33419        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33420        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33421        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33422        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33423      esac
33424
33425      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33426
33427    cat >>Makefile.objects<<EOF
33428-include $ac_bdir$ac_obj.dep
33429$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33430	$ac_comp
33431EOF
33432  done
33433
33434
33435        EXT_STATIC="$EXT_STATIC enchant;$ext_dir"
33436        ;;
33437      *)
33438
33439
33440  case $ext_dir in
33441  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33442  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33443  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33444  esac
33445
33446
33447
33448  b_c_pre=$php_c_pre
33449  b_cxx_pre=$php_cxx_pre
33450  b_c_meta=$php_c_meta
33451  b_cxx_meta=$php_cxx_meta
33452  b_c_post=$php_c_post
33453  b_cxx_post=$php_cxx_post
33454  b_lo=$php_lo
33455
33456
33457  old_IFS=$IFS
33458  for ac_src in enchant.c; do
33459
33460      IFS=.
33461      set $ac_src
33462      ac_obj=$1
33463      IFS=$old_IFS
33464
33465      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33466
33467      case $ac_src in
33468        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33469        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33470        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33471        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33472      esac
33473
33474      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33475
33476    cat >>Makefile.objects<<EOF
33477-include $ac_bdir$ac_obj.dep
33478$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33479	$ac_comp
33480EOF
33481  done
33482
33483
33484        ;;
33485    esac
33486    EXT_CLI_STATIC="$EXT_CLI_STATIC enchant;$ext_dir"
33487  fi
33488
33489
33490    BUILD_DIR="$BUILD_DIR $ext_builddir"
33491
33492
33493
33494  if test "$ext_builddir" = "."; then
33495    PHP_PECL_EXTENSION=enchant
33496
33497  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
33498
33499  fi
33500
33501
33502  PHP_VAR_SUBST="$PHP_VAR_SUBST ENCHANT_SHARED_LIBADD"
33503
33504fi
33505
33506
33507
33508
33509
33510php_enable_exif=no
33511
33512{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable EXIF (metadata from images) support" >&5
33513printf %s "checking whether to enable EXIF (metadata from images) support... " >&6; }
33514# Check whether --enable-exif was given.
33515if test ${enable_exif+y}
33516then :
33517  enableval=$enable_exif; PHP_EXIF=$enableval
33518else $as_nop
33519
33520  PHP_EXIF=no
33521  test "$PHP_ENABLE_ALL" && PHP_EXIF=$PHP_ENABLE_ALL
33522
33523fi
33524
33525
33526
33527ext_output="yes, shared"
33528ext_shared=yes
33529case $PHP_EXIF in
33530shared,*)
33531  PHP_EXIF=`echo "$PHP_EXIF"|$SED 's/^shared,//'`
33532  ;;
33533shared)
33534  PHP_EXIF=yes
33535  ;;
33536no)
33537  ext_output=no
33538  ext_shared=no
33539  ;;
33540*)
33541  ext_output=yes
33542  ext_shared=no
33543  ;;
33544esac
33545
33546
33547
33548{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
33549printf "%s\n" "$ext_output" >&6; }
33550
33551
33552
33553
33554if test "$PHP_EXIF" != "no"; then
33555
33556printf "%s\n" "#define HAVE_EXIF 1" >>confdefs.h
33557
33558
33559  ext_builddir=ext/exif
33560  ext_srcdir=$abs_srcdir/ext/exif
33561  ext_dir=ext/exif
33562
33563  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
33564
33565  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
33566    PHP_EXIF_SHARED=no
33567
33568
33569  case $ext_dir in
33570  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33571  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33572  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33573  esac
33574
33575
33576
33577  b_c_pre=$php_c_pre
33578  b_cxx_pre=$php_cxx_pre
33579  b_c_meta=$php_c_meta
33580  b_cxx_meta=$php_cxx_meta
33581  b_c_post=$php_c_post
33582  b_cxx_post=$php_cxx_post
33583  b_lo=$php_lo
33584
33585
33586  old_IFS=$IFS
33587  for ac_src in exif.c; do
33588
33589      IFS=.
33590      set $ac_src
33591      ac_obj=$1
33592      IFS=$old_IFS
33593
33594      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33595
33596      case $ac_src in
33597        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33598        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33599        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33600        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33601      esac
33602
33603      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33604
33605    cat >>Makefile.objects<<EOF
33606-include $ac_bdir$ac_obj.dep
33607$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33608	$ac_comp
33609EOF
33610  done
33611
33612
33613    EXT_STATIC="$EXT_STATIC exif;$ext_dir"
33614    if test "$ext_shared" != "nocli"; then
33615      EXT_CLI_STATIC="$EXT_CLI_STATIC exif;$ext_dir"
33616    fi
33617  else
33618    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
33619      PHP_EXIF_SHARED=yes
33620
33621  case $ext_dir in
33622  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33623  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33624  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33625  esac
33626
33627
33628
33629  b_c_pre=$shared_c_pre
33630  b_cxx_pre=$shared_cxx_pre
33631  b_c_meta=$shared_c_meta
33632  b_cxx_meta=$shared_cxx_meta
33633  b_c_post=$shared_c_post
33634  b_cxx_post=$shared_cxx_post
33635  b_lo=$shared_lo
33636
33637
33638  old_IFS=$IFS
33639  for ac_src in exif.c; do
33640
33641      IFS=.
33642      set $ac_src
33643      ac_obj=$1
33644      IFS=$old_IFS
33645
33646      shared_objects_exif="$shared_objects_exif $ac_bdir$ac_obj.lo"
33647
33648      case $ac_src in
33649        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33650        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33651        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33652        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33653      esac
33654
33655      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33656
33657    cat >>Makefile.objects<<EOF
33658-include $ac_bdir$ac_obj.dep
33659$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33660	$ac_comp
33661EOF
33662  done
33663
33664
33665  install_modules="install-modules"
33666  suffix=la
33667
33668  case $host_alias in
33669    *aix*)
33670      additional_flags="-Wl,-G"
33671      ;;
33672  esac
33673
33674  if test "x" = "xyes"; then
33675    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/exif.$suffix"
33676  else
33677    PHP_MODULES="$PHP_MODULES \$(phplibdir)/exif.$suffix"
33678  fi
33679
33680  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_exif"
33681
33682  cat >>Makefile.objects<<EOF
33683\$(phplibdir)/exif.$suffix: $ext_builddir/exif.$suffix
33684	\$(LIBTOOL) --mode=install cp $ext_builddir/exif.$suffix \$(phplibdir)
33685
33686$ext_builddir/exif.$suffix: \$(shared_objects_exif) \$(EXIF_SHARED_DEPENDENCIES)
33687	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_exif) \$(EXIF_SHARED_LIBADD)
33688
33689EOF
33690
33691
33692printf "%s\n" "#define COMPILE_DL_EXIF 1" >>confdefs.h
33693
33694    fi
33695  fi
33696
33697  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
33698    PHP_EXIF_SHARED=no
33699    case "$PHP_SAPI" in
33700      cgi|embed|phpdbg)
33701
33702
33703  case $ext_dir in
33704  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33705  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33706  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33707  esac
33708
33709
33710
33711  b_c_pre=$php_c_pre
33712  b_cxx_pre=$php_cxx_pre
33713  b_c_meta=$php_c_meta
33714  b_cxx_meta=$php_cxx_meta
33715  b_c_post=$php_c_post
33716  b_cxx_post=$php_cxx_post
33717  b_lo=$php_lo
33718
33719
33720  old_IFS=$IFS
33721  for ac_src in exif.c; do
33722
33723      IFS=.
33724      set $ac_src
33725      ac_obj=$1
33726      IFS=$old_IFS
33727
33728      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33729
33730      case $ac_src in
33731        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33732        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33733        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33734        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33735      esac
33736
33737      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33738
33739    cat >>Makefile.objects<<EOF
33740-include $ac_bdir$ac_obj.dep
33741$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33742	$ac_comp
33743EOF
33744  done
33745
33746
33747        EXT_STATIC="$EXT_STATIC exif;$ext_dir"
33748        ;;
33749      *)
33750
33751
33752  case $ext_dir in
33753  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
33754  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
33755  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
33756  esac
33757
33758
33759
33760  b_c_pre=$php_c_pre
33761  b_cxx_pre=$php_cxx_pre
33762  b_c_meta=$php_c_meta
33763  b_cxx_meta=$php_cxx_meta
33764  b_c_post=$php_c_post
33765  b_cxx_post=$php_cxx_post
33766  b_lo=$php_lo
33767
33768
33769  old_IFS=$IFS
33770  for ac_src in exif.c; do
33771
33772      IFS=.
33773      set $ac_src
33774      ac_obj=$1
33775      IFS=$old_IFS
33776
33777      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
33778
33779      case $ac_src in
33780        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33781        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33782        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
33783        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
33784      esac
33785
33786      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
33787
33788    cat >>Makefile.objects<<EOF
33789-include $ac_bdir$ac_obj.dep
33790$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
33791	$ac_comp
33792EOF
33793  done
33794
33795
33796        ;;
33797    esac
33798    EXT_CLI_STATIC="$EXT_CLI_STATIC exif;$ext_dir"
33799  fi
33800
33801
33802    BUILD_DIR="$BUILD_DIR $ext_builddir"
33803
33804
33805
33806  if test "$ext_builddir" = "."; then
33807    PHP_PECL_EXTENSION=exif
33808
33809  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
33810
33811  fi
33812
33813fi
33814
33815
33816
33817
33818
33819php_with_ffi=no
33820
33821{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FFI support" >&5
33822printf %s "checking for FFI support... " >&6; }
33823
33824# Check whether --with-ffi was given.
33825if test ${with_ffi+y}
33826then :
33827  withval=$with_ffi; PHP_FFI=$withval
33828else $as_nop
33829
33830  PHP_FFI=no
33831  test "$PHP_ENABLE_ALL" && PHP_FFI=$PHP_ENABLE_ALL
33832
33833fi
33834
33835
33836
33837ext_output="yes, shared"
33838ext_shared=yes
33839case $PHP_FFI in
33840shared,*)
33841  PHP_FFI=`echo "$PHP_FFI"|$SED 's/^shared,//'`
33842  ;;
33843shared)
33844  PHP_FFI=yes
33845  ;;
33846no)
33847  ext_output=no
33848  ext_shared=no
33849  ;;
33850*)
33851  ext_output=yes
33852  ext_shared=no
33853  ;;
33854esac
33855
33856
33857
33858{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
33859printf "%s\n" "$ext_output" >&6; }
33860
33861
33862
33863
33864if test "$PHP_FFI" != "no"; then
33865
33866pkg_failed=no
33867{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libffi >= 3.0.11" >&5
33868printf %s "checking for libffi >= 3.0.11... " >&6; }
33869
33870if test -n "$FFI_CFLAGS"; then
33871    pkg_cv_FFI_CFLAGS="$FFI_CFLAGS"
33872 elif test -n "$PKG_CONFIG"; then
33873    if test -n "$PKG_CONFIG" && \
33874    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi >= 3.0.11\""; } >&5
33875  ($PKG_CONFIG --exists --print-errors "libffi >= 3.0.11") 2>&5
33876  ac_status=$?
33877  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
33878  test $ac_status = 0; }; then
33879  pkg_cv_FFI_CFLAGS=`$PKG_CONFIG --cflags "libffi >= 3.0.11" 2>/dev/null`
33880		      test "x$?" != "x0" && pkg_failed=yes
33881else
33882  pkg_failed=yes
33883fi
33884 else
33885    pkg_failed=untried
33886fi
33887if test -n "$FFI_LIBS"; then
33888    pkg_cv_FFI_LIBS="$FFI_LIBS"
33889 elif test -n "$PKG_CONFIG"; then
33890    if test -n "$PKG_CONFIG" && \
33891    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi >= 3.0.11\""; } >&5
33892  ($PKG_CONFIG --exists --print-errors "libffi >= 3.0.11") 2>&5
33893  ac_status=$?
33894  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
33895  test $ac_status = 0; }; then
33896  pkg_cv_FFI_LIBS=`$PKG_CONFIG --libs "libffi >= 3.0.11" 2>/dev/null`
33897		      test "x$?" != "x0" && pkg_failed=yes
33898else
33899  pkg_failed=yes
33900fi
33901 else
33902    pkg_failed=untried
33903fi
33904
33905
33906
33907if test $pkg_failed = yes; then
33908        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33909printf "%s\n" "no" >&6; }
33910
33911if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
33912        _pkg_short_errors_supported=yes
33913else
33914        _pkg_short_errors_supported=no
33915fi
33916        if test $_pkg_short_errors_supported = yes; then
33917	        FFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libffi >= 3.0.11" 2>&1`
33918        else
33919	        FFI_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libffi >= 3.0.11" 2>&1`
33920        fi
33921	# Put the nasty error message in config.log where it belongs
33922	echo "$FFI_PKG_ERRORS" >&5
33923
33924	as_fn_error $? "Package requirements (libffi >= 3.0.11) were not met:
33925
33926$FFI_PKG_ERRORS
33927
33928Consider adjusting the PKG_CONFIG_PATH environment variable if you
33929installed software in a non-standard prefix.
33930
33931Alternatively, you may set the environment variables FFI_CFLAGS
33932and FFI_LIBS to avoid the need to call pkg-config.
33933See the pkg-config man page for more details." "$LINENO" 5
33934elif test $pkg_failed = untried; then
33935        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
33936printf "%s\n" "no" >&6; }
33937	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
33938printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
33939as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
33940is in your PATH or set the PKG_CONFIG environment variable to the full
33941path to pkg-config.
33942
33943Alternatively, you may set the environment variables FFI_CFLAGS
33944and FFI_LIBS to avoid the need to call pkg-config.
33945See the pkg-config man page for more details.
33946
33947To get pkg-config, see <http://pkg-config.freedesktop.org/>.
33948See \`config.log' for more details" "$LINENO" 5; }
33949else
33950	FFI_CFLAGS=$pkg_cv_FFI_CFLAGS
33951	FFI_LIBS=$pkg_cv_FFI_LIBS
33952        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33953printf "%s\n" "yes" >&6; }
33954
33955fi
33956
33957
33958  for ac_i in $FFI_CFLAGS; do
33959    case $ac_i in
33960    -I*)
33961      ac_ii=`echo $ac_i|cut -c 3-`
33962
33963  if test "$ac_ii" != "/usr/include"; then
33964
33965  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
33966    ai_p=$ac_ii
33967  else
33968
33969    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
33970
33971    ep_realdir=`(cd "$ep_dir" && pwd)`
33972    ai_p="$ep_realdir"/`basename "$ac_ii"`
33973  fi
33974
33975
33976
33977  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
33978
33979  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
33980  if test -n "$unique" && test "`eval $cmd`" = "" ; then
33981    eval "INCLUDEPATH$unique=set"
33982
33983      if test ""; then
33984        INCLUDES="-I$ai_p $INCLUDES"
33985      else
33986        INCLUDES="$INCLUDES -I$ai_p"
33987      fi
33988
33989  fi
33990
33991  fi
33992
33993    ;;
33994    esac
33995  done
33996
33997
33998  for ac_i in $FFI_LIBS; do
33999    case $ac_i in
34000    -pthread)
34001      if test "$ext_shared" = "yes"; then
34002        FFI_SHARED_LIBADD="$FFI_SHARED_LIBADD -pthread"
34003      else
34004
34005
34006  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
34007
34008  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
34009  if test -n "$unique" && test "`eval $cmd`" = "" ; then
34010    eval "EXTRA_LDFLAGS$unique=set"
34011    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
34012  fi
34013
34014
34015
34016  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
34017
34018  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
34019  if test -n "$unique" && test "`eval $cmd`" = "" ; then
34020    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
34021    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
34022  fi
34023
34024      fi
34025    ;;
34026    -l*)
34027      ac_ii=`echo $ac_i|cut -c 3-`
34028
34029
34030  case $ac_ii in
34031  c|c_r) ;;
34032  *)
34033    if test "$ext_shared" = "yes"; then
34034        FFI_SHARED_LIBADD="$FFI_SHARED_LIBADD -l$ac_ii"
34035    else
34036
34037
34038  case $ac_ii in
34039  c|c_r) ;;
34040  *)
34041      LIBS="$LIBS -l$ac_ii"
34042   ;;
34043  esac
34044
34045
34046    fi
34047   ;;
34048  esac
34049
34050
34051    ;;
34052    -L*)
34053      ac_ii=`echo $ac_i|cut -c 3-`
34054
34055  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
34056
34057  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
34058    ai_p=$ac_ii
34059  else
34060
34061    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
34062
34063    ep_realdir=`(cd "$ep_dir" && pwd)`
34064    ai_p="$ep_realdir"/`basename "$ac_ii"`
34065  fi
34066
34067
34068      if test "$ext_shared" = "yes"; then
34069        FFI_SHARED_LIBADD="-L$ai_p $FFI_SHARED_LIBADD"
34070        test -n "$ld_runpath_switch" && FFI_SHARED_LIBADD="$ld_runpath_switch$ai_p $FFI_SHARED_LIBADD"
34071      else
34072
34073
34074
34075  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
34076
34077  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
34078  if test -n "$unique" && test "`eval $cmd`" = "" ; then
34079    eval "LIBPATH$unique=set"
34080
34081    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
34082    LDFLAGS="$LDFLAGS -L$ai_p"
34083    PHP_RPATHS="$PHP_RPATHS $ai_p"
34084
34085  fi
34086
34087
34088      fi
34089
34090  fi
34091
34092    ;;
34093    esac
34094  done
34095
34096
34097
34098printf "%s\n" "#define HAVE_FFI 1" >>confdefs.h
34099
34100
34101  ac_fn_c_check_type "$LINENO" "long double" "ac_cv_type_long_double" "$ac_includes_default"
34102if test "x$ac_cv_type_long_double" = xyes
34103then :
34104
34105printf "%s\n" "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
34106
34107
34108fi
34109
34110
34111  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fastcall calling convention" >&5
34112printf %s "checking for fastcall calling convention... " >&6; }
34113if test ${ac_cv_ffi_fastcall+y}
34114then :
34115  printf %s "(cached) " >&6
34116else $as_nop
34117
34118      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34119/* end confdefs.h.  */
34120#include <ffi.h>
34121int
34122main (void)
34123{
34124return FFI_FASTCALL
34125  ;
34126  return 0;
34127}
34128
34129_ACEOF
34130if ac_fn_c_try_compile "$LINENO"
34131then :
34132  ac_cv_ffi_fastcall=yes
34133else $as_nop
34134  ac_cv_ffi_fastcall=no
34135fi
34136rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34137
34138fi
34139{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_fastcall" >&5
34140printf "%s\n" "$ac_cv_ffi_fastcall" >&6; }
34141
34142  if test "$ac_cv_ffi_fastcall" = yes; then
34143
34144printf "%s\n" "#define HAVE_FFI_FASTCALL 1" >>confdefs.h
34145
34146  fi
34147
34148  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for thiscall calling convention" >&5
34149printf %s "checking for thiscall calling convention... " >&6; }
34150if test ${ac_cv_ffi_thiscall+y}
34151then :
34152  printf %s "(cached) " >&6
34153else $as_nop
34154
34155      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34156/* end confdefs.h.  */
34157#include <ffi.h>
34158int
34159main (void)
34160{
34161return FFI_THISCALL
34162  ;
34163  return 0;
34164}
34165
34166_ACEOF
34167if ac_fn_c_try_compile "$LINENO"
34168then :
34169  ac_cv_ffi_thiscall=yes
34170else $as_nop
34171  ac_cv_ffi_thiscall=no
34172fi
34173rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34174
34175fi
34176{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_thiscall" >&5
34177printf "%s\n" "$ac_cv_ffi_thiscall" >&6; }
34178
34179  if test "$ac_cv_ffi_thiscall" = yes; then
34180
34181printf "%s\n" "#define HAVE_FFI_THISCALL 1" >>confdefs.h
34182
34183  fi
34184
34185  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdcall calling convention" >&5
34186printf %s "checking for stdcall calling convention... " >&6; }
34187if test ${ac_cv_ffi_stdcall+y}
34188then :
34189  printf %s "(cached) " >&6
34190else $as_nop
34191
34192      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34193/* end confdefs.h.  */
34194#include <ffi.h>
34195int
34196main (void)
34197{
34198return FFI_STDCALL
34199  ;
34200  return 0;
34201}
34202
34203_ACEOF
34204if ac_fn_c_try_compile "$LINENO"
34205then :
34206  ac_cv_ffi_stdcall=yes
34207else $as_nop
34208  ac_cv_ffi_stdcall=no
34209fi
34210rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34211
34212fi
34213{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_stdcall" >&5
34214printf "%s\n" "$ac_cv_ffi_stdcall" >&6; }
34215
34216  if test "$ac_cv_ffi_stdcall" = yes; then
34217
34218printf "%s\n" "#define HAVE_FFI_STDCALL 1" >>confdefs.h
34219
34220  fi
34221
34222  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pascal calling convention" >&5
34223printf %s "checking for pascal calling convention... " >&6; }
34224if test ${ac_cv_ffi_pascal+y}
34225then :
34226  printf %s "(cached) " >&6
34227else $as_nop
34228
34229      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34230/* end confdefs.h.  */
34231#include <ffi.h>
34232int
34233main (void)
34234{
34235return FFI_PASCAL
34236  ;
34237  return 0;
34238}
34239
34240_ACEOF
34241if ac_fn_c_try_compile "$LINENO"
34242then :
34243  ac_cv_ffi_pascal=yes
34244else $as_nop
34245  ac_cv_ffi_pascal=no
34246fi
34247rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34248
34249fi
34250{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_pascal" >&5
34251printf "%s\n" "$ac_cv_ffi_pascal" >&6; }
34252
34253  if test "$ac_cv_ffi_pascal" = yes; then
34254
34255printf "%s\n" "#define HAVE_FFI_PASCAL 1" >>confdefs.h
34256
34257  fi
34258
34259  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for register calling convention" >&5
34260printf %s "checking for register calling convention... " >&6; }
34261if test ${ac_cv_ffi_register+y}
34262then :
34263  printf %s "(cached) " >&6
34264else $as_nop
34265
34266      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34267/* end confdefs.h.  */
34268#include <ffi.h>
34269int
34270main (void)
34271{
34272return FFI_REGISTER
34273  ;
34274  return 0;
34275}
34276
34277_ACEOF
34278if ac_fn_c_try_compile "$LINENO"
34279then :
34280  ac_cv_ffi_register=yes
34281else $as_nop
34282  ac_cv_ffi_register=no
34283fi
34284rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34285
34286fi
34287{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_register" >&5
34288printf "%s\n" "$ac_cv_ffi_register" >&6; }
34289
34290  if test "$ac_cv_ffi_register" = yes; then
34291
34292printf "%s\n" "#define HAVE_FFI_REGISTER 1" >>confdefs.h
34293
34294  fi
34295
34296  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ms_cdecl calling convention" >&5
34297printf %s "checking for ms_cdecl calling convention... " >&6; }
34298if test ${ac_cv_ffi_ms_cdecl+y}
34299then :
34300  printf %s "(cached) " >&6
34301else $as_nop
34302
34303      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34304/* end confdefs.h.  */
34305#include <ffi.h>
34306int
34307main (void)
34308{
34309return FFI_MS_CDECL
34310  ;
34311  return 0;
34312}
34313
34314_ACEOF
34315if ac_fn_c_try_compile "$LINENO"
34316then :
34317  ac_cv_ffi_ms_cdecl=yes
34318else $as_nop
34319  ac_cv_ffi_ms_cdecl=no
34320fi
34321rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34322
34323fi
34324{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_ms_cdecl" >&5
34325printf "%s\n" "$ac_cv_ffi_ms_cdecl" >&6; }
34326
34327  if test "$ac_cv_ffi_ms_cdecl" = yes; then
34328
34329printf "%s\n" "#define HAVE_FFI_MS_CDECL 1" >>confdefs.h
34330
34331  fi
34332
34333  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysv calling convention" >&5
34334printf %s "checking for sysv calling convention... " >&6; }
34335if test ${ac_cv_ffi_sysv+y}
34336then :
34337  printf %s "(cached) " >&6
34338else $as_nop
34339
34340      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34341/* end confdefs.h.  */
34342#include <ffi.h>
34343int
34344main (void)
34345{
34346return FFI_SYSV
34347  ;
34348  return 0;
34349}
34350
34351_ACEOF
34352if ac_fn_c_try_compile "$LINENO"
34353then :
34354  ac_cv_ffi_sysv=yes
34355else $as_nop
34356  ac_cv_ffi_sysv=no
34357fi
34358rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
34359
34360fi
34361{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ffi_sysv" >&5
34362printf "%s\n" "$ac_cv_ffi_sysv" >&6; }
34363
34364  if test "$ac_cv_ffi_sysv" = yes; then
34365
34366printf "%s\n" "#define HAVE_FFI_SYSV 1" >>confdefs.h
34367
34368  fi
34369
34370
34371  ext_builddir=ext/ffi
34372  ext_srcdir=$abs_srcdir/ext/ffi
34373  ext_dir=ext/ffi
34374
34375  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
34376
34377  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
34378    PHP_FFI_SHARED=no
34379
34380
34381  case $ext_dir in
34382  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34383  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34384  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34385  esac
34386
34387
34388
34389  b_c_pre=$php_c_pre
34390  b_cxx_pre=$php_cxx_pre
34391  b_c_meta=$php_c_meta
34392  b_cxx_meta=$php_cxx_meta
34393  b_c_post=$php_c_post
34394  b_cxx_post=$php_cxx_post
34395  b_lo=$php_lo
34396
34397
34398  old_IFS=$IFS
34399  for ac_src in ffi.c ffi_parser.c; do
34400
34401      IFS=.
34402      set $ac_src
34403      ac_obj=$1
34404      IFS=$old_IFS
34405
34406      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34407
34408      case $ac_src in
34409        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34410        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34411        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34412        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34413      esac
34414
34415      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34416
34417    cat >>Makefile.objects<<EOF
34418-include $ac_bdir$ac_obj.dep
34419$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34420	$ac_comp
34421EOF
34422  done
34423
34424
34425    EXT_STATIC="$EXT_STATIC ffi;$ext_dir"
34426    if test "$ext_shared" != "nocli"; then
34427      EXT_CLI_STATIC="$EXT_CLI_STATIC ffi;$ext_dir"
34428    fi
34429  else
34430    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
34431      PHP_FFI_SHARED=yes
34432
34433  case $ext_dir in
34434  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34435  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34436  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34437  esac
34438
34439
34440
34441  b_c_pre=$shared_c_pre
34442  b_cxx_pre=$shared_cxx_pre
34443  b_c_meta=$shared_c_meta
34444  b_cxx_meta=$shared_cxx_meta
34445  b_c_post=$shared_c_post
34446  b_cxx_post=$shared_cxx_post
34447  b_lo=$shared_lo
34448
34449
34450  old_IFS=$IFS
34451  for ac_src in ffi.c ffi_parser.c; do
34452
34453      IFS=.
34454      set $ac_src
34455      ac_obj=$1
34456      IFS=$old_IFS
34457
34458      shared_objects_ffi="$shared_objects_ffi $ac_bdir$ac_obj.lo"
34459
34460      case $ac_src in
34461        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34462        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34463        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34464        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34465      esac
34466
34467      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34468
34469    cat >>Makefile.objects<<EOF
34470-include $ac_bdir$ac_obj.dep
34471$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34472	$ac_comp
34473EOF
34474  done
34475
34476
34477  install_modules="install-modules"
34478  suffix=la
34479
34480  case $host_alias in
34481    *aix*)
34482      additional_flags="-Wl,-G"
34483      ;;
34484  esac
34485
34486  if test "x" = "xyes"; then
34487    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/ffi.$suffix"
34488  else
34489    PHP_MODULES="$PHP_MODULES \$(phplibdir)/ffi.$suffix"
34490  fi
34491
34492  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_ffi"
34493
34494  cat >>Makefile.objects<<EOF
34495\$(phplibdir)/ffi.$suffix: $ext_builddir/ffi.$suffix
34496	\$(LIBTOOL) --mode=install cp $ext_builddir/ffi.$suffix \$(phplibdir)
34497
34498$ext_builddir/ffi.$suffix: \$(shared_objects_ffi) \$(FFI_SHARED_DEPENDENCIES)
34499	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_ffi) \$(FFI_SHARED_LIBADD)
34500
34501EOF
34502
34503
34504printf "%s\n" "#define COMPILE_DL_FFI 1" >>confdefs.h
34505
34506    fi
34507  fi
34508
34509  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
34510    PHP_FFI_SHARED=no
34511    case "$PHP_SAPI" in
34512      cgi|embed|phpdbg)
34513
34514
34515  case $ext_dir in
34516  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34517  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34518  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34519  esac
34520
34521
34522
34523  b_c_pre=$php_c_pre
34524  b_cxx_pre=$php_cxx_pre
34525  b_c_meta=$php_c_meta
34526  b_cxx_meta=$php_cxx_meta
34527  b_c_post=$php_c_post
34528  b_cxx_post=$php_cxx_post
34529  b_lo=$php_lo
34530
34531
34532  old_IFS=$IFS
34533  for ac_src in ffi.c ffi_parser.c; do
34534
34535      IFS=.
34536      set $ac_src
34537      ac_obj=$1
34538      IFS=$old_IFS
34539
34540      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34541
34542      case $ac_src in
34543        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34544        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34545        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34546        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34547      esac
34548
34549      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34550
34551    cat >>Makefile.objects<<EOF
34552-include $ac_bdir$ac_obj.dep
34553$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34554	$ac_comp
34555EOF
34556  done
34557
34558
34559        EXT_STATIC="$EXT_STATIC ffi;$ext_dir"
34560        ;;
34561      *)
34562
34563
34564  case $ext_dir in
34565  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34566  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34567  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34568  esac
34569
34570
34571
34572  b_c_pre=$php_c_pre
34573  b_cxx_pre=$php_cxx_pre
34574  b_c_meta=$php_c_meta
34575  b_cxx_meta=$php_cxx_meta
34576  b_c_post=$php_c_post
34577  b_cxx_post=$php_cxx_post
34578  b_lo=$php_lo
34579
34580
34581  old_IFS=$IFS
34582  for ac_src in ffi.c ffi_parser.c; do
34583
34584      IFS=.
34585      set $ac_src
34586      ac_obj=$1
34587      IFS=$old_IFS
34588
34589      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34590
34591      case $ac_src in
34592        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34593        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34594        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34595        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34596      esac
34597
34598      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34599
34600    cat >>Makefile.objects<<EOF
34601-include $ac_bdir$ac_obj.dep
34602$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34603	$ac_comp
34604EOF
34605  done
34606
34607
34608        ;;
34609    esac
34610    EXT_CLI_STATIC="$EXT_CLI_STATIC ffi;$ext_dir"
34611  fi
34612
34613
34614    BUILD_DIR="$BUILD_DIR $ext_builddir"
34615
34616
34617
34618  if test "$ext_builddir" = "."; then
34619    PHP_PECL_EXTENSION=ffi
34620
34621  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
34622
34623  fi
34624
34625
34626  PHP_VAR_SUBST="$PHP_VAR_SUBST FFI_SHARED_LIBADD"
34627
34628fi
34629
34630
34631
34632
34633
34634php_enable_fileinfo=yes
34635
34636{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fileinfo support" >&5
34637printf %s "checking for fileinfo support... " >&6; }
34638# Check whether --enable-fileinfo was given.
34639if test ${enable_fileinfo+y}
34640then :
34641  enableval=$enable_fileinfo; PHP_FILEINFO=$enableval
34642else $as_nop
34643
34644  PHP_FILEINFO=yes
34645  test "$PHP_ENABLE_ALL" && PHP_FILEINFO=$PHP_ENABLE_ALL
34646
34647fi
34648
34649
34650
34651ext_output="yes, shared"
34652ext_shared=yes
34653case $PHP_FILEINFO in
34654shared,*)
34655  PHP_FILEINFO=`echo "$PHP_FILEINFO"|$SED 's/^shared,//'`
34656  ;;
34657shared)
34658  PHP_FILEINFO=yes
34659  ;;
34660no)
34661  ext_output=no
34662  ext_shared=no
34663  ;;
34664*)
34665  ext_output=yes
34666  ext_shared=no
34667  ;;
34668esac
34669
34670
34671
34672{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
34673printf "%s\n" "$ext_output" >&6; }
34674
34675
34676
34677
34678if test "$PHP_FILEINFO" != "no"; then
34679
34680  libmagic_sources=" \
34681    libmagic/apprentice.c libmagic/apptype.c libmagic/ascmagic.c \
34682    libmagic/cdf.c libmagic/cdf_time.c libmagic/compress.c \
34683    libmagic/encoding.c libmagic/fsmagic.c libmagic/funcs.c \
34684    libmagic/is_json.c libmagic/is_tar.c libmagic/magic.c libmagic/print.c \
34685    libmagic/readcdf.c libmagic/softmagic.c libmagic/der.c \
34686    libmagic/buffer.c libmagic/is_csv.c"
34687
34688  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for strcasestr" >&5
34689printf %s "checking for strcasestr... " >&6; }
34690  if test "$cross_compiling" = yes
34691then :
34692  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: skipped, cross-compiling" >&5
34693printf "%s\n" "skipped, cross-compiling" >&6; }
34694else $as_nop
34695  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34696/* end confdefs.h.  */
34697
34698#include <string.h>
34699#include <strings.h>
34700#include <stdlib.h>
34701
34702int main(void)
34703{
34704        char *s0, *s1, *ret;
34705
34706        s0 = (char *) malloc(42);
34707        s1 = (char *) malloc(8);
34708
34709        memset(s0, 'X', 42);
34710        s0[24] = 'Y';
34711        s0[26] = 'Z';
34712        s0[41] = '\0';
34713        memset(s1, 'x', 8);
34714        s1[0] = 'y';
34715        s1[2] = 'Z';
34716        s1[7] = '\0';
34717
34718        ret = strcasestr(s0, s1);
34719
34720        return !(NULL != ret);
34721}
34722
34723_ACEOF
34724if ac_fn_c_try_run "$LINENO"
34725then :
34726
34727        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34728printf "%s\n" "yes" >&6; }
34729
34730else $as_nop
34731
34732    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
34733printf "%s\n" "no" >&6; }
34734    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: using libmagic strcasestr implementation" >&5
34735printf "%s\n" "$as_me: using libmagic strcasestr implementation" >&6;}
34736    libmagic_sources="$libmagic_sources libmagic/strcasestr.c"
34737
34738fi
34739rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34740  conftest.$ac_objext conftest.beam conftest.$ac_ext
34741fi
34742
34743
34744
34745  ext_builddir=ext/fileinfo
34746  ext_srcdir=$abs_srcdir/ext/fileinfo
34747  ext_dir=ext/fileinfo
34748
34749  ac_extra=`echo "-I@ext_srcdir@/libmagic"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
34750
34751  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
34752    PHP_FILEINFO_SHARED=no
34753
34754
34755  case $ext_dir in
34756  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34757  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34758  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34759  esac
34760
34761
34762
34763  b_c_pre=$php_c_pre
34764  b_cxx_pre=$php_cxx_pre
34765  b_c_meta=$php_c_meta
34766  b_cxx_meta=$php_cxx_meta
34767  b_c_post=$php_c_post
34768  b_cxx_post=$php_cxx_post
34769  b_lo=$php_lo
34770
34771
34772  old_IFS=$IFS
34773  for ac_src in fileinfo.c $libmagic_sources; do
34774
34775      IFS=.
34776      set $ac_src
34777      ac_obj=$1
34778      IFS=$old_IFS
34779
34780      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34781
34782      case $ac_src in
34783        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34784        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34785        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34786        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34787      esac
34788
34789      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34790
34791    cat >>Makefile.objects<<EOF
34792-include $ac_bdir$ac_obj.dep
34793$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34794	$ac_comp
34795EOF
34796  done
34797
34798
34799    EXT_STATIC="$EXT_STATIC fileinfo;$ext_dir"
34800    if test "$ext_shared" != "nocli"; then
34801      EXT_CLI_STATIC="$EXT_CLI_STATIC fileinfo;$ext_dir"
34802    fi
34803  else
34804    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
34805      PHP_FILEINFO_SHARED=yes
34806
34807  case $ext_dir in
34808  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34809  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34810  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34811  esac
34812
34813
34814
34815  b_c_pre=$shared_c_pre
34816  b_cxx_pre=$shared_cxx_pre
34817  b_c_meta=$shared_c_meta
34818  b_cxx_meta=$shared_cxx_meta
34819  b_c_post=$shared_c_post
34820  b_cxx_post=$shared_cxx_post
34821  b_lo=$shared_lo
34822
34823
34824  old_IFS=$IFS
34825  for ac_src in fileinfo.c $libmagic_sources; do
34826
34827      IFS=.
34828      set $ac_src
34829      ac_obj=$1
34830      IFS=$old_IFS
34831
34832      shared_objects_fileinfo="$shared_objects_fileinfo $ac_bdir$ac_obj.lo"
34833
34834      case $ac_src in
34835        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34836        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34837        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34838        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34839      esac
34840
34841      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34842
34843    cat >>Makefile.objects<<EOF
34844-include $ac_bdir$ac_obj.dep
34845$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34846	$ac_comp
34847EOF
34848  done
34849
34850
34851  install_modules="install-modules"
34852  suffix=la
34853
34854  case $host_alias in
34855    *aix*)
34856      additional_flags="-Wl,-G"
34857      ;;
34858  esac
34859
34860  if test "x" = "xyes"; then
34861    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/fileinfo.$suffix"
34862  else
34863    PHP_MODULES="$PHP_MODULES \$(phplibdir)/fileinfo.$suffix"
34864  fi
34865
34866  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_fileinfo"
34867
34868  cat >>Makefile.objects<<EOF
34869\$(phplibdir)/fileinfo.$suffix: $ext_builddir/fileinfo.$suffix
34870	\$(LIBTOOL) --mode=install cp $ext_builddir/fileinfo.$suffix \$(phplibdir)
34871
34872$ext_builddir/fileinfo.$suffix: \$(shared_objects_fileinfo) \$(FILEINFO_SHARED_DEPENDENCIES)
34873	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_fileinfo) \$(FILEINFO_SHARED_LIBADD)
34874
34875EOF
34876
34877
34878printf "%s\n" "#define COMPILE_DL_FILEINFO 1" >>confdefs.h
34879
34880    fi
34881  fi
34882
34883  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
34884    PHP_FILEINFO_SHARED=no
34885    case "$PHP_SAPI" in
34886      cgi|embed|phpdbg)
34887
34888
34889  case $ext_dir in
34890  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34891  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34892  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34893  esac
34894
34895
34896
34897  b_c_pre=$php_c_pre
34898  b_cxx_pre=$php_cxx_pre
34899  b_c_meta=$php_c_meta
34900  b_cxx_meta=$php_cxx_meta
34901  b_c_post=$php_c_post
34902  b_cxx_post=$php_cxx_post
34903  b_lo=$php_lo
34904
34905
34906  old_IFS=$IFS
34907  for ac_src in fileinfo.c $libmagic_sources; do
34908
34909      IFS=.
34910      set $ac_src
34911      ac_obj=$1
34912      IFS=$old_IFS
34913
34914      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34915
34916      case $ac_src in
34917        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34918        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34919        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34920        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34921      esac
34922
34923      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34924
34925    cat >>Makefile.objects<<EOF
34926-include $ac_bdir$ac_obj.dep
34927$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34928	$ac_comp
34929EOF
34930  done
34931
34932
34933        EXT_STATIC="$EXT_STATIC fileinfo;$ext_dir"
34934        ;;
34935      *)
34936
34937
34938  case $ext_dir in
34939  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
34940  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
34941  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
34942  esac
34943
34944
34945
34946  b_c_pre=$php_c_pre
34947  b_cxx_pre=$php_cxx_pre
34948  b_c_meta=$php_c_meta
34949  b_cxx_meta=$php_cxx_meta
34950  b_c_post=$php_c_post
34951  b_cxx_post=$php_cxx_post
34952  b_lo=$php_lo
34953
34954
34955  old_IFS=$IFS
34956  for ac_src in fileinfo.c $libmagic_sources; do
34957
34958      IFS=.
34959      set $ac_src
34960      ac_obj=$1
34961      IFS=$old_IFS
34962
34963      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
34964
34965      case $ac_src in
34966        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34967        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34968        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
34969        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
34970      esac
34971
34972      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
34973
34974    cat >>Makefile.objects<<EOF
34975-include $ac_bdir$ac_obj.dep
34976$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
34977	$ac_comp
34978EOF
34979  done
34980
34981
34982        ;;
34983    esac
34984    EXT_CLI_STATIC="$EXT_CLI_STATIC fileinfo;$ext_dir"
34985  fi
34986
34987
34988    BUILD_DIR="$BUILD_DIR $ext_builddir"
34989
34990
34991
34992  if test "$ext_builddir" = "."; then
34993    PHP_PECL_EXTENSION=fileinfo
34994
34995  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
34996
34997  fi
34998
34999
35000
35001    BUILD_DIR="$BUILD_DIR $ext_builddir/libmagic"
35002
35003
35004
35005  ac_fn_c_check_func "$LINENO" "utimes" "ac_cv_func_utimes"
35006if test "x$ac_cv_func_utimes" = xyes
35007then :
35008  printf "%s\n" "#define HAVE_UTIMES 1" >>confdefs.h
35009
35010fi
35011ac_fn_c_check_func "$LINENO" "strndup" "ac_cv_func_strndup"
35012if test "x$ac_cv_func_strndup" = xyes
35013then :
35014  printf "%s\n" "#define HAVE_STRNDUP 1" >>confdefs.h
35015
35016fi
35017
35018
35019
35020  src=$ext_srcdir/Makefile.frag
35021  ac_srcdir=$ext_srcdir
35022  ac_builddir=$ext_builddir
35023  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
35024
35025fi
35026
35027
35028
35029
35030
35031php_enable_filter=yes
35032
35033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable input filter support" >&5
35034printf %s "checking whether to enable input filter support... " >&6; }
35035# Check whether --enable-filter was given.
35036if test ${enable_filter+y}
35037then :
35038  enableval=$enable_filter; PHP_FILTER=$enableval
35039else $as_nop
35040
35041  PHP_FILTER=yes
35042  test "$PHP_ENABLE_ALL" && PHP_FILTER=$PHP_ENABLE_ALL
35043
35044fi
35045
35046
35047
35048ext_output="yes, shared"
35049ext_shared=yes
35050case $PHP_FILTER in
35051shared,*)
35052  PHP_FILTER=`echo "$PHP_FILTER"|$SED 's/^shared,//'`
35053  ;;
35054shared)
35055  PHP_FILTER=yes
35056  ;;
35057no)
35058  ext_output=no
35059  ext_shared=no
35060  ;;
35061*)
35062  ext_output=yes
35063  ext_shared=no
35064  ;;
35065esac
35066
35067
35068
35069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
35070printf "%s\n" "$ext_output" >&6; }
35071
35072
35073
35074
35075if test "$PHP_FILTER" != "no"; then
35076
35077  ext_builddir=ext/filter
35078  ext_srcdir=$abs_srcdir/ext/filter
35079  ext_dir=ext/filter
35080
35081  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
35082
35083  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
35084    PHP_FILTER_SHARED=no
35085
35086
35087  case $ext_dir in
35088  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35089  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35090  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35091  esac
35092
35093
35094
35095  b_c_pre=$php_c_pre
35096  b_cxx_pre=$php_cxx_pre
35097  b_c_meta=$php_c_meta
35098  b_cxx_meta=$php_cxx_meta
35099  b_c_post=$php_c_post
35100  b_cxx_post=$php_cxx_post
35101  b_lo=$php_lo
35102
35103
35104  old_IFS=$IFS
35105  for ac_src in filter.c sanitizing_filters.c logical_filters.c callback_filter.c; do
35106
35107      IFS=.
35108      set $ac_src
35109      ac_obj=$1
35110      IFS=$old_IFS
35111
35112      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35113
35114      case $ac_src in
35115        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35116        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35117        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35118        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35119      esac
35120
35121      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35122
35123    cat >>Makefile.objects<<EOF
35124-include $ac_bdir$ac_obj.dep
35125$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35126	$ac_comp
35127EOF
35128  done
35129
35130
35131    EXT_STATIC="$EXT_STATIC filter;$ext_dir"
35132    if test "$ext_shared" != "nocli"; then
35133      EXT_CLI_STATIC="$EXT_CLI_STATIC filter;$ext_dir"
35134    fi
35135  else
35136    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
35137      PHP_FILTER_SHARED=yes
35138
35139  case $ext_dir in
35140  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35141  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35142  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35143  esac
35144
35145
35146
35147  b_c_pre=$shared_c_pre
35148  b_cxx_pre=$shared_cxx_pre
35149  b_c_meta=$shared_c_meta
35150  b_cxx_meta=$shared_cxx_meta
35151  b_c_post=$shared_c_post
35152  b_cxx_post=$shared_cxx_post
35153  b_lo=$shared_lo
35154
35155
35156  old_IFS=$IFS
35157  for ac_src in filter.c sanitizing_filters.c logical_filters.c callback_filter.c; do
35158
35159      IFS=.
35160      set $ac_src
35161      ac_obj=$1
35162      IFS=$old_IFS
35163
35164      shared_objects_filter="$shared_objects_filter $ac_bdir$ac_obj.lo"
35165
35166      case $ac_src in
35167        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35168        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35169        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35170        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35171      esac
35172
35173      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35174
35175    cat >>Makefile.objects<<EOF
35176-include $ac_bdir$ac_obj.dep
35177$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35178	$ac_comp
35179EOF
35180  done
35181
35182
35183  install_modules="install-modules"
35184  suffix=la
35185
35186  case $host_alias in
35187    *aix*)
35188      additional_flags="-Wl,-G"
35189      ;;
35190  esac
35191
35192  if test "x" = "xyes"; then
35193    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/filter.$suffix"
35194  else
35195    PHP_MODULES="$PHP_MODULES \$(phplibdir)/filter.$suffix"
35196  fi
35197
35198  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_filter"
35199
35200  cat >>Makefile.objects<<EOF
35201\$(phplibdir)/filter.$suffix: $ext_builddir/filter.$suffix
35202	\$(LIBTOOL) --mode=install cp $ext_builddir/filter.$suffix \$(phplibdir)
35203
35204$ext_builddir/filter.$suffix: \$(shared_objects_filter) \$(FILTER_SHARED_DEPENDENCIES)
35205	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_filter) \$(FILTER_SHARED_LIBADD)
35206
35207EOF
35208
35209
35210printf "%s\n" "#define COMPILE_DL_FILTER 1" >>confdefs.h
35211
35212    fi
35213  fi
35214
35215  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
35216    PHP_FILTER_SHARED=no
35217    case "$PHP_SAPI" in
35218      cgi|embed|phpdbg)
35219
35220
35221  case $ext_dir in
35222  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35223  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35224  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35225  esac
35226
35227
35228
35229  b_c_pre=$php_c_pre
35230  b_cxx_pre=$php_cxx_pre
35231  b_c_meta=$php_c_meta
35232  b_cxx_meta=$php_cxx_meta
35233  b_c_post=$php_c_post
35234  b_cxx_post=$php_cxx_post
35235  b_lo=$php_lo
35236
35237
35238  old_IFS=$IFS
35239  for ac_src in filter.c sanitizing_filters.c logical_filters.c callback_filter.c; do
35240
35241      IFS=.
35242      set $ac_src
35243      ac_obj=$1
35244      IFS=$old_IFS
35245
35246      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35247
35248      case $ac_src in
35249        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35250        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35251        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35252        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35253      esac
35254
35255      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35256
35257    cat >>Makefile.objects<<EOF
35258-include $ac_bdir$ac_obj.dep
35259$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35260	$ac_comp
35261EOF
35262  done
35263
35264
35265        EXT_STATIC="$EXT_STATIC filter;$ext_dir"
35266        ;;
35267      *)
35268
35269
35270  case $ext_dir in
35271  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35272  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35273  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35274  esac
35275
35276
35277
35278  b_c_pre=$php_c_pre
35279  b_cxx_pre=$php_cxx_pre
35280  b_c_meta=$php_c_meta
35281  b_cxx_meta=$php_cxx_meta
35282  b_c_post=$php_c_post
35283  b_cxx_post=$php_cxx_post
35284  b_lo=$php_lo
35285
35286
35287  old_IFS=$IFS
35288  for ac_src in filter.c sanitizing_filters.c logical_filters.c callback_filter.c; do
35289
35290      IFS=.
35291      set $ac_src
35292      ac_obj=$1
35293      IFS=$old_IFS
35294
35295      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35296
35297      case $ac_src in
35298        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35299        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35300        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35301        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35302      esac
35303
35304      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35305
35306    cat >>Makefile.objects<<EOF
35307-include $ac_bdir$ac_obj.dep
35308$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35309	$ac_comp
35310EOF
35311  done
35312
35313
35314        ;;
35315    esac
35316    EXT_CLI_STATIC="$EXT_CLI_STATIC filter;$ext_dir"
35317  fi
35318
35319
35320    BUILD_DIR="$BUILD_DIR $ext_builddir"
35321
35322
35323
35324  if test "$ext_builddir" = "."; then
35325    PHP_PECL_EXTENSION=filter
35326
35327  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
35328
35329  fi
35330
35331
35332  PHP_VAR_SUBST="$PHP_VAR_SUBST FILTER_SHARED_LIBADD"
35333
35334
35335
35336
35337    for header_file in ext/filter/php_filter.h; do
35338
35339
35340  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
35341
35342  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
35343  if test -n "$unique" && test "`eval $cmd`" = "" ; then
35344    eval "INSTALLHEADERS$unique=set"
35345
35346        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
35347
35348  fi
35349
35350    done
35351
35352
35353
35354  am_i_shared=$PHP_FILTER_SHARED
35355  is_it_shared=$PHP_PCRE_SHARED
35356  is_it_enabled=$PHP_PCRE
35357  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
35358    as_fn_error $? "
35359You've configured extension filter to build statically, but it
35360depends on extension pcre, which you've configured to build shared.
35361You either need to build filter shared or build pcre statically for the
35362build to be successful.
35363" "$LINENO" 5
35364  fi
35365  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
35366    as_fn_error $? "
35367You've configured extension filter, which depends on extension pcre,
35368but you've either not enabled pcre, or have disabled it.
35369" "$LINENO" 5
35370  fi
35371
35372fi
35373
35374
35375
35376
35377
35378php_enable_ftp=no
35379
35380{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable FTP support" >&5
35381printf %s "checking whether to enable FTP support... " >&6; }
35382# Check whether --enable-ftp was given.
35383if test ${enable_ftp+y}
35384then :
35385  enableval=$enable_ftp; PHP_FTP=$enableval
35386else $as_nop
35387
35388  PHP_FTP=no
35389  test "$PHP_ENABLE_ALL" && PHP_FTP=$PHP_ENABLE_ALL
35390
35391fi
35392
35393
35394
35395ext_output="yes, shared"
35396ext_shared=yes
35397case $PHP_FTP in
35398shared,*)
35399  PHP_FTP=`echo "$PHP_FTP"|$SED 's/^shared,//'`
35400  ;;
35401shared)
35402  PHP_FTP=yes
35403  ;;
35404no)
35405  ext_output=no
35406  ext_shared=no
35407  ;;
35408*)
35409  ext_output=yes
35410  ext_shared=no
35411  ;;
35412esac
35413
35414
35415
35416{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
35417printf "%s\n" "$ext_output" >&6; }
35418
35419
35420
35421
35422
35423php_with_openssl_dir=no
35424
35425{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to explicitly enable FTP SSL support" >&5
35426printf %s "checking whether to explicitly enable FTP SSL support... " >&6; }
35427
35428# Check whether --with-openssl-dir was given.
35429if test ${with_openssl_dir+y}
35430then :
35431  withval=$with_openssl_dir; PHP_OPENSSL_DIR=$withval
35432else $as_nop
35433
35434  PHP_OPENSSL_DIR=no
35435
35436
35437fi
35438
35439
35440ext_output=$PHP_OPENSSL_DIR
35441{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
35442printf "%s\n" "$ext_output" >&6; }
35443
35444
35445
35446
35447if test "$PHP_FTP" = "yes"; then
35448
35449printf "%s\n" "#define HAVE_FTP 1" >>confdefs.h
35450
35451
35452  ext_builddir=ext/ftp
35453  ext_srcdir=$abs_srcdir/ext/ftp
35454  ext_dir=ext/ftp
35455
35456  ac_extra=
35457
35458  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
35459    PHP_FTP_SHARED=no
35460
35461
35462  case $ext_dir in
35463  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35464  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35465  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35466  esac
35467
35468
35469
35470  b_c_pre=$php_c_pre
35471  b_cxx_pre=$php_cxx_pre
35472  b_c_meta=$php_c_meta
35473  b_cxx_meta=$php_cxx_meta
35474  b_c_post=$php_c_post
35475  b_cxx_post=$php_cxx_post
35476  b_lo=$php_lo
35477
35478
35479  old_IFS=$IFS
35480  for ac_src in php_ftp.c ftp.c; do
35481
35482      IFS=.
35483      set $ac_src
35484      ac_obj=$1
35485      IFS=$old_IFS
35486
35487      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35488
35489      case $ac_src in
35490        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35491        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35492        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35493        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35494      esac
35495
35496      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35497
35498    cat >>Makefile.objects<<EOF
35499-include $ac_bdir$ac_obj.dep
35500$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35501	$ac_comp
35502EOF
35503  done
35504
35505
35506    EXT_STATIC="$EXT_STATIC ftp;$ext_dir"
35507    if test "$ext_shared" != "nocli"; then
35508      EXT_CLI_STATIC="$EXT_CLI_STATIC ftp;$ext_dir"
35509    fi
35510  else
35511    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
35512      PHP_FTP_SHARED=yes
35513
35514  case $ext_dir in
35515  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35516  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35517  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35518  esac
35519
35520
35521
35522  b_c_pre=$shared_c_pre
35523  b_cxx_pre=$shared_cxx_pre
35524  b_c_meta=$shared_c_meta
35525  b_cxx_meta=$shared_cxx_meta
35526  b_c_post=$shared_c_post
35527  b_cxx_post=$shared_cxx_post
35528  b_lo=$shared_lo
35529
35530
35531  old_IFS=$IFS
35532  for ac_src in php_ftp.c ftp.c; do
35533
35534      IFS=.
35535      set $ac_src
35536      ac_obj=$1
35537      IFS=$old_IFS
35538
35539      shared_objects_ftp="$shared_objects_ftp $ac_bdir$ac_obj.lo"
35540
35541      case $ac_src in
35542        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35543        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35544        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35545        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35546      esac
35547
35548      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35549
35550    cat >>Makefile.objects<<EOF
35551-include $ac_bdir$ac_obj.dep
35552$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35553	$ac_comp
35554EOF
35555  done
35556
35557
35558  install_modules="install-modules"
35559  suffix=la
35560
35561  case $host_alias in
35562    *aix*)
35563      additional_flags="-Wl,-G"
35564      ;;
35565  esac
35566
35567  if test "x" = "xyes"; then
35568    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/ftp.$suffix"
35569  else
35570    PHP_MODULES="$PHP_MODULES \$(phplibdir)/ftp.$suffix"
35571  fi
35572
35573  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_ftp"
35574
35575  cat >>Makefile.objects<<EOF
35576\$(phplibdir)/ftp.$suffix: $ext_builddir/ftp.$suffix
35577	\$(LIBTOOL) --mode=install cp $ext_builddir/ftp.$suffix \$(phplibdir)
35578
35579$ext_builddir/ftp.$suffix: \$(shared_objects_ftp) \$(FTP_SHARED_DEPENDENCIES)
35580	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_ftp) \$(FTP_SHARED_LIBADD)
35581
35582EOF
35583
35584
35585printf "%s\n" "#define COMPILE_DL_FTP 1" >>confdefs.h
35586
35587    fi
35588  fi
35589
35590  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
35591    PHP_FTP_SHARED=no
35592    case "$PHP_SAPI" in
35593      cgi|embed|phpdbg)
35594
35595
35596  case $ext_dir in
35597  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35598  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35599  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35600  esac
35601
35602
35603
35604  b_c_pre=$php_c_pre
35605  b_cxx_pre=$php_cxx_pre
35606  b_c_meta=$php_c_meta
35607  b_cxx_meta=$php_cxx_meta
35608  b_c_post=$php_c_post
35609  b_cxx_post=$php_cxx_post
35610  b_lo=$php_lo
35611
35612
35613  old_IFS=$IFS
35614  for ac_src in php_ftp.c ftp.c; do
35615
35616      IFS=.
35617      set $ac_src
35618      ac_obj=$1
35619      IFS=$old_IFS
35620
35621      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35622
35623      case $ac_src in
35624        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35625        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35626        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35627        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35628      esac
35629
35630      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35631
35632    cat >>Makefile.objects<<EOF
35633-include $ac_bdir$ac_obj.dep
35634$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35635	$ac_comp
35636EOF
35637  done
35638
35639
35640        EXT_STATIC="$EXT_STATIC ftp;$ext_dir"
35641        ;;
35642      *)
35643
35644
35645  case $ext_dir in
35646  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
35647  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
35648  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
35649  esac
35650
35651
35652
35653  b_c_pre=$php_c_pre
35654  b_cxx_pre=$php_cxx_pre
35655  b_c_meta=$php_c_meta
35656  b_cxx_meta=$php_cxx_meta
35657  b_c_post=$php_c_post
35658  b_cxx_post=$php_cxx_post
35659  b_lo=$php_lo
35660
35661
35662  old_IFS=$IFS
35663  for ac_src in php_ftp.c ftp.c; do
35664
35665      IFS=.
35666      set $ac_src
35667      ac_obj=$1
35668      IFS=$old_IFS
35669
35670      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
35671
35672      case $ac_src in
35673        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35674        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35675        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
35676        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
35677      esac
35678
35679      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
35680
35681    cat >>Makefile.objects<<EOF
35682-include $ac_bdir$ac_obj.dep
35683$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
35684	$ac_comp
35685EOF
35686  done
35687
35688
35689        ;;
35690    esac
35691    EXT_CLI_STATIC="$EXT_CLI_STATIC ftp;$ext_dir"
35692  fi
35693
35694
35695    BUILD_DIR="$BUILD_DIR $ext_builddir"
35696
35697
35698
35699  if test "$ext_builddir" = "."; then
35700    PHP_PECL_EXTENSION=ftp
35701
35702  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
35703
35704  fi
35705
35706
35707    test -z "$PHP_OPENSSL" && PHP_OPENSSL=no
35708
35709  if test "$PHP_OPENSSL" != "no" || test "$PHP_OPENSSL_DIR" != "no"; then
35710
35711  found_openssl=no
35712
35713
35714pkg_failed=no
35715{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl >= 1.0.2" >&5
35716printf %s "checking for openssl >= 1.0.2... " >&6; }
35717
35718if test -n "$OPENSSL_CFLAGS"; then
35719    pkg_cv_OPENSSL_CFLAGS="$OPENSSL_CFLAGS"
35720 elif test -n "$PKG_CONFIG"; then
35721    if test -n "$PKG_CONFIG" && \
35722    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
35723  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
35724  ac_status=$?
35725  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
35726  test $ac_status = 0; }; then
35727  pkg_cv_OPENSSL_CFLAGS=`$PKG_CONFIG --cflags "openssl >= 1.0.2" 2>/dev/null`
35728		      test "x$?" != "x0" && pkg_failed=yes
35729else
35730  pkg_failed=yes
35731fi
35732 else
35733    pkg_failed=untried
35734fi
35735if test -n "$OPENSSL_LIBS"; then
35736    pkg_cv_OPENSSL_LIBS="$OPENSSL_LIBS"
35737 elif test -n "$PKG_CONFIG"; then
35738    if test -n "$PKG_CONFIG" && \
35739    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
35740  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
35741  ac_status=$?
35742  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
35743  test $ac_status = 0; }; then
35744  pkg_cv_OPENSSL_LIBS=`$PKG_CONFIG --libs "openssl >= 1.0.2" 2>/dev/null`
35745		      test "x$?" != "x0" && pkg_failed=yes
35746else
35747  pkg_failed=yes
35748fi
35749 else
35750    pkg_failed=untried
35751fi
35752
35753
35754
35755if test $pkg_failed = yes; then
35756        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
35757printf "%s\n" "no" >&6; }
35758
35759if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
35760        _pkg_short_errors_supported=yes
35761else
35762        _pkg_short_errors_supported=no
35763fi
35764        if test $_pkg_short_errors_supported = yes; then
35765	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
35766        else
35767	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
35768        fi
35769	# Put the nasty error message in config.log where it belongs
35770	echo "$OPENSSL_PKG_ERRORS" >&5
35771
35772	as_fn_error $? "Package requirements (openssl >= 1.0.2) were not met:
35773
35774$OPENSSL_PKG_ERRORS
35775
35776Consider adjusting the PKG_CONFIG_PATH environment variable if you
35777installed software in a non-standard prefix.
35778
35779Alternatively, you may set the environment variables OPENSSL_CFLAGS
35780and OPENSSL_LIBS to avoid the need to call pkg-config.
35781See the pkg-config man page for more details." "$LINENO" 5
35782elif test $pkg_failed = untried; then
35783        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
35784printf "%s\n" "no" >&6; }
35785	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35786printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
35787as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
35788is in your PATH or set the PKG_CONFIG environment variable to the full
35789path to pkg-config.
35790
35791Alternatively, you may set the environment variables OPENSSL_CFLAGS
35792and OPENSSL_LIBS to avoid the need to call pkg-config.
35793See the pkg-config man page for more details.
35794
35795To get pkg-config, see <http://pkg-config.freedesktop.org/>.
35796See \`config.log' for more details" "$LINENO" 5; }
35797else
35798	OPENSSL_CFLAGS=$pkg_cv_OPENSSL_CFLAGS
35799	OPENSSL_LIBS=$pkg_cv_OPENSSL_LIBS
35800        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35801printf "%s\n" "yes" >&6; }
35802	found_openssl=yes
35803fi
35804
35805  if test "$found_openssl" = "yes"; then
35806
35807  for ac_i in $OPENSSL_LIBS; do
35808    case $ac_i in
35809    -pthread)
35810      if test "$ext_shared" = "yes"; then
35811        FTP_SHARED_LIBADD="$FTP_SHARED_LIBADD -pthread"
35812      else
35813
35814
35815  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
35816
35817  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
35818  if test -n "$unique" && test "`eval $cmd`" = "" ; then
35819    eval "EXTRA_LDFLAGS$unique=set"
35820    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
35821  fi
35822
35823
35824
35825  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
35826
35827  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
35828  if test -n "$unique" && test "`eval $cmd`" = "" ; then
35829    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
35830    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
35831  fi
35832
35833      fi
35834    ;;
35835    -l*)
35836      ac_ii=`echo $ac_i|cut -c 3-`
35837
35838
35839  case $ac_ii in
35840  c|c_r) ;;
35841  *)
35842    if test "$ext_shared" = "yes"; then
35843        FTP_SHARED_LIBADD="$FTP_SHARED_LIBADD -l$ac_ii"
35844    else
35845
35846
35847  case $ac_ii in
35848  c|c_r) ;;
35849  *)
35850      LIBS="$LIBS -l$ac_ii"
35851   ;;
35852  esac
35853
35854
35855    fi
35856   ;;
35857  esac
35858
35859
35860    ;;
35861    -L*)
35862      ac_ii=`echo $ac_i|cut -c 3-`
35863
35864  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
35865
35866  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
35867    ai_p=$ac_ii
35868  else
35869
35870    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
35871
35872    ep_realdir=`(cd "$ep_dir" && pwd)`
35873    ai_p="$ep_realdir"/`basename "$ac_ii"`
35874  fi
35875
35876
35877      if test "$ext_shared" = "yes"; then
35878        FTP_SHARED_LIBADD="-L$ai_p $FTP_SHARED_LIBADD"
35879        test -n "$ld_runpath_switch" && FTP_SHARED_LIBADD="$ld_runpath_switch$ai_p $FTP_SHARED_LIBADD"
35880      else
35881
35882
35883
35884  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
35885
35886  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
35887  if test -n "$unique" && test "`eval $cmd`" = "" ; then
35888    eval "LIBPATH$unique=set"
35889
35890    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
35891    LDFLAGS="$LDFLAGS -L$ai_p"
35892    PHP_RPATHS="$PHP_RPATHS $ai_p"
35893
35894  fi
35895
35896
35897      fi
35898
35899  fi
35900
35901    ;;
35902    esac
35903  done
35904
35905
35906  for ac_i in $OPENSSL_CFLAGS; do
35907    case $ac_i in
35908    -I*)
35909      ac_ii=`echo $ac_i|cut -c 3-`
35910
35911  if test "$ac_ii" != "/usr/include"; then
35912
35913  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
35914    ai_p=$ac_ii
35915  else
35916
35917    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
35918
35919    ep_realdir=`(cd "$ep_dir" && pwd)`
35920    ai_p="$ep_realdir"/`basename "$ac_ii"`
35921  fi
35922
35923
35924
35925  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
35926
35927  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
35928  if test -n "$unique" && test "`eval $cmd`" = "" ; then
35929    eval "INCLUDEPATH$unique=set"
35930
35931      if test ""; then
35932        INCLUDES="-I$ai_p $INCLUDES"
35933      else
35934        INCLUDES="$INCLUDES -I$ai_p"
35935      fi
35936
35937  fi
35938
35939  fi
35940
35941    ;;
35942    esac
35943  done
35944
35945:
35946
35947  fi
35948
35949
35950  PHP_VAR_SUBST="$PHP_VAR_SUBST FTP_SHARED_LIBADD"
35951
35952
35953printf "%s\n" "#define HAVE_FTP_SSL 1" >>confdefs.h
35954
35955  fi
35956fi
35957
35958
35959
35960
35961
35962php_enable_gd=no
35963
35964{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GD support" >&5
35965printf %s "checking for GD support... " >&6; }
35966# Check whether --enable-gd was given.
35967if test ${enable_gd+y}
35968then :
35969  enableval=$enable_gd; PHP_GD=$enableval
35970else $as_nop
35971
35972  PHP_GD=no
35973  test "$PHP_ENABLE_ALL" && PHP_GD=$PHP_ENABLE_ALL
35974
35975fi
35976
35977
35978
35979ext_output="yes, shared"
35980ext_shared=yes
35981case $PHP_GD in
35982shared,*)
35983  PHP_GD=`echo "$PHP_GD"|$SED 's/^shared,//'`
35984  ;;
35985shared)
35986  PHP_GD=yes
35987  ;;
35988no)
35989  ext_output=no
35990  ext_shared=no
35991  ;;
35992*)
35993  ext_output=yes
35994  ext_shared=no
35995  ;;
35996esac
35997
35998
35999
36000{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36001printf "%s\n" "$ext_output" >&6; }
36002
36003
36004
36005
36006
36007php_with_external_gd=no
36008
36009{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for external libgd" >&5
36010printf %s "checking for external libgd... " >&6; }
36011
36012# Check whether --with-external-gd was given.
36013if test ${with_external_gd+y}
36014then :
36015  withval=$with_external_gd; PHP_EXTERNAL_GD=$withval
36016else $as_nop
36017
36018  PHP_EXTERNAL_GD=no
36019
36020
36021fi
36022
36023
36024ext_output=$PHP_EXTERNAL_GD
36025{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36026printf "%s\n" "$ext_output" >&6; }
36027
36028
36029
36030
36031if test -z "$PHP_AVIF"; then
36032
36033php_with_avif=no
36034
36035{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libavif" >&5
36036printf %s "checking for libavif... " >&6; }
36037
36038# Check whether --with-avif was given.
36039if test ${with_avif+y}
36040then :
36041  withval=$with_avif; PHP_AVIF=$withval
36042else $as_nop
36043
36044  PHP_AVIF=no
36045
36046
36047fi
36048
36049
36050ext_output=$PHP_AVIF
36051{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36052printf "%s\n" "$ext_output" >&6; }
36053
36054
36055
36056fi
36057
36058if test -z "$PHP_WEBP"; then
36059
36060php_with_webp=no
36061
36062{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libwebp" >&5
36063printf %s "checking for libwebp... " >&6; }
36064
36065# Check whether --with-webp was given.
36066if test ${with_webp+y}
36067then :
36068  withval=$with_webp; PHP_WEBP=$withval
36069else $as_nop
36070
36071  PHP_WEBP=no
36072
36073
36074fi
36075
36076
36077ext_output=$PHP_WEBP
36078{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36079printf "%s\n" "$ext_output" >&6; }
36080
36081
36082
36083fi
36084
36085if test -z "$PHP_JPEG"; then
36086
36087php_with_jpeg=no
36088
36089{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libjpeg" >&5
36090printf %s "checking for libjpeg... " >&6; }
36091
36092# Check whether --with-jpeg was given.
36093if test ${with_jpeg+y}
36094then :
36095  withval=$with_jpeg; PHP_JPEG=$withval
36096else $as_nop
36097
36098  PHP_JPEG=no
36099
36100
36101fi
36102
36103
36104ext_output=$PHP_JPEG
36105{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36106printf "%s\n" "$ext_output" >&6; }
36107
36108
36109
36110fi
36111
36112
36113php_with_xpm=no
36114
36115{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libXpm" >&5
36116printf %s "checking for libXpm... " >&6; }
36117
36118# Check whether --with-xpm was given.
36119if test ${with_xpm+y}
36120then :
36121  withval=$with_xpm; PHP_XPM=$withval
36122else $as_nop
36123
36124  PHP_XPM=no
36125
36126
36127fi
36128
36129
36130ext_output=$PHP_XPM
36131{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36132printf "%s\n" "$ext_output" >&6; }
36133
36134
36135
36136
36137
36138php_with_freetype=no
36139
36140{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FreeType 2" >&5
36141printf %s "checking for FreeType 2... " >&6; }
36142
36143# Check whether --with-freetype was given.
36144if test ${with_freetype+y}
36145then :
36146  withval=$with_freetype; PHP_FREETYPE=$withval
36147else $as_nop
36148
36149  PHP_FREETYPE=no
36150
36151
36152fi
36153
36154
36155ext_output=$PHP_FREETYPE
36156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36157printf "%s\n" "$ext_output" >&6; }
36158
36159
36160
36161
36162
36163php_enable_gd_jis_conv=no
36164
36165{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable JIS-mapped Japanese font support in GD" >&5
36166printf %s "checking whether to enable JIS-mapped Japanese font support in GD... " >&6; }
36167# Check whether --enable-gd-jis-conv was given.
36168if test ${enable_gd_jis_conv+y}
36169then :
36170  enableval=$enable_gd_jis_conv; PHP_GD_JIS_CONV=$enableval
36171else $as_nop
36172
36173  PHP_GD_JIS_CONV=no
36174
36175
36176fi
36177
36178
36179ext_output=$PHP_GD_JIS_CONV
36180{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
36181printf "%s\n" "$ext_output" >&6; }
36182
36183
36184
36185
36186
36187
36188
36189
36190
36191
36192
36193
36194
36195
36196
36197
36198
36199
36200
36201
36202
36203
36204
36205
36206if test "$PHP_GD" != "no"; then
36207
36208  if test "$PHP_EXTERNAL_GD" = "no"; then
36209    extra_sources="libgd/gd.c libgd/gd_gd.c libgd/gd_gd2.c libgd/gd_io.c libgd/gd_io_dp.c \
36210                  libgd/gd_io_file.c libgd/gd_ss.c libgd/gd_io_ss.c libgd/gd_webp.c libgd/gd_avif.c \
36211                  libgd/gd_png.c libgd/gd_jpeg.c libgd/gdxpm.c libgd/gdfontt.c libgd/gdfonts.c \
36212                  libgd/gdfontmb.c libgd/gdfontl.c libgd/gdfontg.c libgd/gdtables.c libgd/gdft.c \
36213                  libgd/gdcache.c libgd/gdkanji.c libgd/wbmp.c libgd/gd_wbmp.c libgd/gdhelpers.c \
36214                  libgd/gd_topal.c libgd/gd_gif_in.c libgd/gd_xbm.c libgd/gd_gif_out.c libgd/gd_security.c \
36215                  libgd/gd_filter.c libgd/gd_pixelate.c libgd/gd_rotate.c libgd/gd_color_match.c \
36216                  libgd/gd_transform.c libgd/gd_crop.c libgd/gd_interpolation.c libgd/gd_matrix.c \
36217                  libgd/gd_bmp.c libgd/gd_tga.c"
36218
36219    ac_fn_c_check_func "$LINENO" "fabsf" "ac_cv_func_fabsf"
36220if test "x$ac_cv_func_fabsf" = xyes
36221then :
36222  printf "%s\n" "#define HAVE_FABSF 1" >>confdefs.h
36223
36224fi
36225ac_fn_c_check_func "$LINENO" "floorf" "ac_cv_func_floorf"
36226if test "x$ac_cv_func_floorf" = xyes
36227then :
36228  printf "%s\n" "#define HAVE_FLOORF 1" >>confdefs.h
36229
36230fi
36231
36232
36233
36234printf "%s\n" "#define HAVE_GD_BUNDLED 1" >>confdefs.h
36235
36236
36237printf "%s\n" "#define HAVE_GD_PNG 1" >>confdefs.h
36238
36239
36240printf "%s\n" "#define HAVE_GD_BMP 1" >>confdefs.h
36241
36242
36243printf "%s\n" "#define HAVE_GD_TGA 1" >>confdefs.h
36244
36245
36246
36247
36248pkg_failed=no
36249{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zlib" >&5
36250printf %s "checking for zlib... " >&6; }
36251
36252if test -n "$ZLIB_CFLAGS"; then
36253    pkg_cv_ZLIB_CFLAGS="$ZLIB_CFLAGS"
36254 elif test -n "$PKG_CONFIG"; then
36255    if test -n "$PKG_CONFIG" && \
36256    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib\""; } >&5
36257  ($PKG_CONFIG --exists --print-errors "zlib") 2>&5
36258  ac_status=$?
36259  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36260  test $ac_status = 0; }; then
36261  pkg_cv_ZLIB_CFLAGS=`$PKG_CONFIG --cflags "zlib" 2>/dev/null`
36262		      test "x$?" != "x0" && pkg_failed=yes
36263else
36264  pkg_failed=yes
36265fi
36266 else
36267    pkg_failed=untried
36268fi
36269if test -n "$ZLIB_LIBS"; then
36270    pkg_cv_ZLIB_LIBS="$ZLIB_LIBS"
36271 elif test -n "$PKG_CONFIG"; then
36272    if test -n "$PKG_CONFIG" && \
36273    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib\""; } >&5
36274  ($PKG_CONFIG --exists --print-errors "zlib") 2>&5
36275  ac_status=$?
36276  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36277  test $ac_status = 0; }; then
36278  pkg_cv_ZLIB_LIBS=`$PKG_CONFIG --libs "zlib" 2>/dev/null`
36279		      test "x$?" != "x0" && pkg_failed=yes
36280else
36281  pkg_failed=yes
36282fi
36283 else
36284    pkg_failed=untried
36285fi
36286
36287
36288
36289if test $pkg_failed = yes; then
36290        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36291printf "%s\n" "no" >&6; }
36292
36293if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
36294        _pkg_short_errors_supported=yes
36295else
36296        _pkg_short_errors_supported=no
36297fi
36298        if test $_pkg_short_errors_supported = yes; then
36299	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "zlib" 2>&1`
36300        else
36301	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "zlib" 2>&1`
36302        fi
36303	# Put the nasty error message in config.log where it belongs
36304	echo "$ZLIB_PKG_ERRORS" >&5
36305
36306	as_fn_error $? "Package requirements (zlib) were not met:
36307
36308$ZLIB_PKG_ERRORS
36309
36310Consider adjusting the PKG_CONFIG_PATH environment variable if you
36311installed software in a non-standard prefix.
36312
36313Alternatively, you may set the environment variables ZLIB_CFLAGS
36314and ZLIB_LIBS to avoid the need to call pkg-config.
36315See the pkg-config man page for more details." "$LINENO" 5
36316elif test $pkg_failed = untried; then
36317        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36318printf "%s\n" "no" >&6; }
36319	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36320printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
36321as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
36322is in your PATH or set the PKG_CONFIG environment variable to the full
36323path to pkg-config.
36324
36325Alternatively, you may set the environment variables ZLIB_CFLAGS
36326and ZLIB_LIBS to avoid the need to call pkg-config.
36327See the pkg-config man page for more details.
36328
36329To get pkg-config, see <http://pkg-config.freedesktop.org/>.
36330See \`config.log' for more details" "$LINENO" 5; }
36331else
36332	ZLIB_CFLAGS=$pkg_cv_ZLIB_CFLAGS
36333	ZLIB_LIBS=$pkg_cv_ZLIB_LIBS
36334        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36335printf "%s\n" "yes" >&6; }
36336
36337fi
36338
36339  for ac_i in $ZLIB_LIBS; do
36340    case $ac_i in
36341    -pthread)
36342      if test "$ext_shared" = "yes"; then
36343        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
36344      else
36345
36346
36347  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36348
36349  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
36350  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36351    eval "EXTRA_LDFLAGS$unique=set"
36352    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
36353  fi
36354
36355
36356
36357  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36358
36359  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
36360  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36361    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
36362    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
36363  fi
36364
36365      fi
36366    ;;
36367    -l*)
36368      ac_ii=`echo $ac_i|cut -c 3-`
36369
36370
36371  case $ac_ii in
36372  c|c_r) ;;
36373  *)
36374    if test "$ext_shared" = "yes"; then
36375        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
36376    else
36377
36378
36379  case $ac_ii in
36380  c|c_r) ;;
36381  *)
36382      LIBS="$LIBS -l$ac_ii"
36383   ;;
36384  esac
36385
36386
36387    fi
36388   ;;
36389  esac
36390
36391
36392    ;;
36393    -L*)
36394      ac_ii=`echo $ac_i|cut -c 3-`
36395
36396  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
36397
36398  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36399    ai_p=$ac_ii
36400  else
36401
36402    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36403
36404    ep_realdir=`(cd "$ep_dir" && pwd)`
36405    ai_p="$ep_realdir"/`basename "$ac_ii"`
36406  fi
36407
36408
36409      if test "$ext_shared" = "yes"; then
36410        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
36411        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
36412      else
36413
36414
36415
36416  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36417
36418  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
36419  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36420    eval "LIBPATH$unique=set"
36421
36422    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
36423    LDFLAGS="$LDFLAGS -L$ai_p"
36424    PHP_RPATHS="$PHP_RPATHS $ai_p"
36425
36426  fi
36427
36428
36429      fi
36430
36431  fi
36432
36433    ;;
36434    esac
36435  done
36436
36437
36438  for ac_i in $ZLIB_CFLAGS; do
36439    case $ac_i in
36440    -I*)
36441      ac_ii=`echo $ac_i|cut -c 3-`
36442
36443  if test "$ac_ii" != "/usr/include"; then
36444
36445  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36446    ai_p=$ac_ii
36447  else
36448
36449    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36450
36451    ep_realdir=`(cd "$ep_dir" && pwd)`
36452    ai_p="$ep_realdir"/`basename "$ac_ii"`
36453  fi
36454
36455
36456
36457  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36458
36459  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
36460  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36461    eval "INCLUDEPATH$unique=set"
36462
36463      if test ""; then
36464        INCLUDES="-I$ai_p $INCLUDES"
36465      else
36466        INCLUDES="$INCLUDES -I$ai_p"
36467      fi
36468
36469  fi
36470
36471  fi
36472
36473    ;;
36474    esac
36475  done
36476
36477
36478
36479
36480pkg_failed=no
36481{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libpng" >&5
36482printf %s "checking for libpng... " >&6; }
36483
36484if test -n "$PNG_CFLAGS"; then
36485    pkg_cv_PNG_CFLAGS="$PNG_CFLAGS"
36486 elif test -n "$PKG_CONFIG"; then
36487    if test -n "$PKG_CONFIG" && \
36488    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
36489  ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
36490  ac_status=$?
36491  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36492  test $ac_status = 0; }; then
36493  pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null`
36494		      test "x$?" != "x0" && pkg_failed=yes
36495else
36496  pkg_failed=yes
36497fi
36498 else
36499    pkg_failed=untried
36500fi
36501if test -n "$PNG_LIBS"; then
36502    pkg_cv_PNG_LIBS="$PNG_LIBS"
36503 elif test -n "$PKG_CONFIG"; then
36504    if test -n "$PKG_CONFIG" && \
36505    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
36506  ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
36507  ac_status=$?
36508  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36509  test $ac_status = 0; }; then
36510  pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null`
36511		      test "x$?" != "x0" && pkg_failed=yes
36512else
36513  pkg_failed=yes
36514fi
36515 else
36516    pkg_failed=untried
36517fi
36518
36519
36520
36521if test $pkg_failed = yes; then
36522        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36523printf "%s\n" "no" >&6; }
36524
36525if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
36526        _pkg_short_errors_supported=yes
36527else
36528        _pkg_short_errors_supported=no
36529fi
36530        if test $_pkg_short_errors_supported = yes; then
36531	        PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpng" 2>&1`
36532        else
36533	        PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpng" 2>&1`
36534        fi
36535	# Put the nasty error message in config.log where it belongs
36536	echo "$PNG_PKG_ERRORS" >&5
36537
36538	as_fn_error $? "Package requirements (libpng) were not met:
36539
36540$PNG_PKG_ERRORS
36541
36542Consider adjusting the PKG_CONFIG_PATH environment variable if you
36543installed software in a non-standard prefix.
36544
36545Alternatively, you may set the environment variables PNG_CFLAGS
36546and PNG_LIBS to avoid the need to call pkg-config.
36547See the pkg-config man page for more details." "$LINENO" 5
36548elif test $pkg_failed = untried; then
36549        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36550printf "%s\n" "no" >&6; }
36551	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36552printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
36553as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
36554is in your PATH or set the PKG_CONFIG environment variable to the full
36555path to pkg-config.
36556
36557Alternatively, you may set the environment variables PNG_CFLAGS
36558and PNG_LIBS to avoid the need to call pkg-config.
36559See the pkg-config man page for more details.
36560
36561To get pkg-config, see <http://pkg-config.freedesktop.org/>.
36562See \`config.log' for more details" "$LINENO" 5; }
36563else
36564	PNG_CFLAGS=$pkg_cv_PNG_CFLAGS
36565	PNG_LIBS=$pkg_cv_PNG_LIBS
36566        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36567printf "%s\n" "yes" >&6; }
36568
36569fi
36570
36571  for ac_i in $PNG_LIBS; do
36572    case $ac_i in
36573    -pthread)
36574      if test "$ext_shared" = "yes"; then
36575        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
36576      else
36577
36578
36579  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36580
36581  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
36582  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36583    eval "EXTRA_LDFLAGS$unique=set"
36584    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
36585  fi
36586
36587
36588
36589  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36590
36591  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
36592  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36593    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
36594    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
36595  fi
36596
36597      fi
36598    ;;
36599    -l*)
36600      ac_ii=`echo $ac_i|cut -c 3-`
36601
36602
36603  case $ac_ii in
36604  c|c_r) ;;
36605  *)
36606    if test "$ext_shared" = "yes"; then
36607        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
36608    else
36609
36610
36611  case $ac_ii in
36612  c|c_r) ;;
36613  *)
36614      LIBS="$LIBS -l$ac_ii"
36615   ;;
36616  esac
36617
36618
36619    fi
36620   ;;
36621  esac
36622
36623
36624    ;;
36625    -L*)
36626      ac_ii=`echo $ac_i|cut -c 3-`
36627
36628  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
36629
36630  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36631    ai_p=$ac_ii
36632  else
36633
36634    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36635
36636    ep_realdir=`(cd "$ep_dir" && pwd)`
36637    ai_p="$ep_realdir"/`basename "$ac_ii"`
36638  fi
36639
36640
36641      if test "$ext_shared" = "yes"; then
36642        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
36643        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
36644      else
36645
36646
36647
36648  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36649
36650  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
36651  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36652    eval "LIBPATH$unique=set"
36653
36654    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
36655    LDFLAGS="$LDFLAGS -L$ai_p"
36656    PHP_RPATHS="$PHP_RPATHS $ai_p"
36657
36658  fi
36659
36660
36661      fi
36662
36663  fi
36664
36665    ;;
36666    esac
36667  done
36668
36669
36670  for ac_i in $PNG_CFLAGS; do
36671    case $ac_i in
36672    -I*)
36673      ac_ii=`echo $ac_i|cut -c 3-`
36674
36675  if test "$ac_ii" != "/usr/include"; then
36676
36677  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36678    ai_p=$ac_ii
36679  else
36680
36681    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36682
36683    ep_realdir=`(cd "$ep_dir" && pwd)`
36684    ai_p="$ep_realdir"/`basename "$ac_ii"`
36685  fi
36686
36687
36688
36689  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36690
36691  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
36692  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36693    eval "INCLUDEPATH$unique=set"
36694
36695      if test ""; then
36696        INCLUDES="-I$ai_p $INCLUDES"
36697      else
36698        INCLUDES="$INCLUDES -I$ai_p"
36699      fi
36700
36701  fi
36702
36703  fi
36704
36705    ;;
36706    esac
36707  done
36708
36709
36710printf "%s\n" "#define HAVE_LIBPNG 1" >>confdefs.h
36711
36712
36713
36714  if test "$PHP_AVIF" != "no"; then
36715
36716pkg_failed=no
36717{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libavif >= 0.8.2" >&5
36718printf %s "checking for libavif >= 0.8.2... " >&6; }
36719
36720if test -n "$AVIF_CFLAGS"; then
36721    pkg_cv_AVIF_CFLAGS="$AVIF_CFLAGS"
36722 elif test -n "$PKG_CONFIG"; then
36723    if test -n "$PKG_CONFIG" && \
36724    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libavif >= 0.8.2\""; } >&5
36725  ($PKG_CONFIG --exists --print-errors "libavif >= 0.8.2") 2>&5
36726  ac_status=$?
36727  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36728  test $ac_status = 0; }; then
36729  pkg_cv_AVIF_CFLAGS=`$PKG_CONFIG --cflags "libavif >= 0.8.2" 2>/dev/null`
36730		      test "x$?" != "x0" && pkg_failed=yes
36731else
36732  pkg_failed=yes
36733fi
36734 else
36735    pkg_failed=untried
36736fi
36737if test -n "$AVIF_LIBS"; then
36738    pkg_cv_AVIF_LIBS="$AVIF_LIBS"
36739 elif test -n "$PKG_CONFIG"; then
36740    if test -n "$PKG_CONFIG" && \
36741    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libavif >= 0.8.2\""; } >&5
36742  ($PKG_CONFIG --exists --print-errors "libavif >= 0.8.2") 2>&5
36743  ac_status=$?
36744  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36745  test $ac_status = 0; }; then
36746  pkg_cv_AVIF_LIBS=`$PKG_CONFIG --libs "libavif >= 0.8.2" 2>/dev/null`
36747		      test "x$?" != "x0" && pkg_failed=yes
36748else
36749  pkg_failed=yes
36750fi
36751 else
36752    pkg_failed=untried
36753fi
36754
36755
36756
36757if test $pkg_failed = yes; then
36758        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36759printf "%s\n" "no" >&6; }
36760
36761if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
36762        _pkg_short_errors_supported=yes
36763else
36764        _pkg_short_errors_supported=no
36765fi
36766        if test $_pkg_short_errors_supported = yes; then
36767	        AVIF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libavif >= 0.8.2" 2>&1`
36768        else
36769	        AVIF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libavif >= 0.8.2" 2>&1`
36770        fi
36771	# Put the nasty error message in config.log where it belongs
36772	echo "$AVIF_PKG_ERRORS" >&5
36773
36774	as_fn_error $? "Package requirements (libavif >= 0.8.2) were not met:
36775
36776$AVIF_PKG_ERRORS
36777
36778Consider adjusting the PKG_CONFIG_PATH environment variable if you
36779installed software in a non-standard prefix.
36780
36781Alternatively, you may set the environment variables AVIF_CFLAGS
36782and AVIF_LIBS to avoid the need to call pkg-config.
36783See the pkg-config man page for more details." "$LINENO" 5
36784elif test $pkg_failed = untried; then
36785        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36786printf "%s\n" "no" >&6; }
36787	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36788printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
36789as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
36790is in your PATH or set the PKG_CONFIG environment variable to the full
36791path to pkg-config.
36792
36793Alternatively, you may set the environment variables AVIF_CFLAGS
36794and AVIF_LIBS to avoid the need to call pkg-config.
36795See the pkg-config man page for more details.
36796
36797To get pkg-config, see <http://pkg-config.freedesktop.org/>.
36798See \`config.log' for more details" "$LINENO" 5; }
36799else
36800	AVIF_CFLAGS=$pkg_cv_AVIF_CFLAGS
36801	AVIF_LIBS=$pkg_cv_AVIF_LIBS
36802        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36803printf "%s\n" "yes" >&6; }
36804
36805fi
36806
36807  for ac_i in $AVIF_LIBS; do
36808    case $ac_i in
36809    -pthread)
36810      if test "$ext_shared" = "yes"; then
36811        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
36812      else
36813
36814
36815  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36816
36817  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
36818  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36819    eval "EXTRA_LDFLAGS$unique=set"
36820    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
36821  fi
36822
36823
36824
36825  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
36826
36827  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
36828  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36829    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
36830    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
36831  fi
36832
36833      fi
36834    ;;
36835    -l*)
36836      ac_ii=`echo $ac_i|cut -c 3-`
36837
36838
36839  case $ac_ii in
36840  c|c_r) ;;
36841  *)
36842    if test "$ext_shared" = "yes"; then
36843        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
36844    else
36845
36846
36847  case $ac_ii in
36848  c|c_r) ;;
36849  *)
36850      LIBS="$LIBS -l$ac_ii"
36851   ;;
36852  esac
36853
36854
36855    fi
36856   ;;
36857  esac
36858
36859
36860    ;;
36861    -L*)
36862      ac_ii=`echo $ac_i|cut -c 3-`
36863
36864  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
36865
36866  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36867    ai_p=$ac_ii
36868  else
36869
36870    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36871
36872    ep_realdir=`(cd "$ep_dir" && pwd)`
36873    ai_p="$ep_realdir"/`basename "$ac_ii"`
36874  fi
36875
36876
36877      if test "$ext_shared" = "yes"; then
36878        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
36879        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
36880      else
36881
36882
36883
36884  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36885
36886  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
36887  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36888    eval "LIBPATH$unique=set"
36889
36890    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
36891    LDFLAGS="$LDFLAGS -L$ai_p"
36892    PHP_RPATHS="$PHP_RPATHS $ai_p"
36893
36894  fi
36895
36896
36897      fi
36898
36899  fi
36900
36901    ;;
36902    esac
36903  done
36904
36905
36906  for ac_i in $AVIF_CFLAGS; do
36907    case $ac_i in
36908    -I*)
36909      ac_ii=`echo $ac_i|cut -c 3-`
36910
36911  if test "$ac_ii" != "/usr/include"; then
36912
36913  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
36914    ai_p=$ac_ii
36915  else
36916
36917    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
36918
36919    ep_realdir=`(cd "$ep_dir" && pwd)`
36920    ai_p="$ep_realdir"/`basename "$ac_ii"`
36921  fi
36922
36923
36924
36925  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
36926
36927  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
36928  if test -n "$unique" && test "`eval $cmd`" = "" ; then
36929    eval "INCLUDEPATH$unique=set"
36930
36931      if test ""; then
36932        INCLUDES="-I$ai_p $INCLUDES"
36933      else
36934        INCLUDES="$INCLUDES -I$ai_p"
36935      fi
36936
36937  fi
36938
36939  fi
36940
36941    ;;
36942    esac
36943  done
36944
36945
36946printf "%s\n" "#define HAVE_LIBAVIF 1" >>confdefs.h
36947
36948
36949printf "%s\n" "#define HAVE_GD_AVIF 1" >>confdefs.h
36950
36951  fi
36952
36953
36954  if test "$PHP_WEBP" != "no"; then
36955
36956pkg_failed=no
36957{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libwebp >= 0.2.0" >&5
36958printf %s "checking for libwebp >= 0.2.0... " >&6; }
36959
36960if test -n "$WEBP_CFLAGS"; then
36961    pkg_cv_WEBP_CFLAGS="$WEBP_CFLAGS"
36962 elif test -n "$PKG_CONFIG"; then
36963    if test -n "$PKG_CONFIG" && \
36964    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libwebp >= 0.2.0\""; } >&5
36965  ($PKG_CONFIG --exists --print-errors "libwebp >= 0.2.0") 2>&5
36966  ac_status=$?
36967  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36968  test $ac_status = 0; }; then
36969  pkg_cv_WEBP_CFLAGS=`$PKG_CONFIG --cflags "libwebp >= 0.2.0" 2>/dev/null`
36970		      test "x$?" != "x0" && pkg_failed=yes
36971else
36972  pkg_failed=yes
36973fi
36974 else
36975    pkg_failed=untried
36976fi
36977if test -n "$WEBP_LIBS"; then
36978    pkg_cv_WEBP_LIBS="$WEBP_LIBS"
36979 elif test -n "$PKG_CONFIG"; then
36980    if test -n "$PKG_CONFIG" && \
36981    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libwebp >= 0.2.0\""; } >&5
36982  ($PKG_CONFIG --exists --print-errors "libwebp >= 0.2.0") 2>&5
36983  ac_status=$?
36984  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
36985  test $ac_status = 0; }; then
36986  pkg_cv_WEBP_LIBS=`$PKG_CONFIG --libs "libwebp >= 0.2.0" 2>/dev/null`
36987		      test "x$?" != "x0" && pkg_failed=yes
36988else
36989  pkg_failed=yes
36990fi
36991 else
36992    pkg_failed=untried
36993fi
36994
36995
36996
36997if test $pkg_failed = yes; then
36998        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
36999printf "%s\n" "no" >&6; }
37000
37001if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
37002        _pkg_short_errors_supported=yes
37003else
37004        _pkg_short_errors_supported=no
37005fi
37006        if test $_pkg_short_errors_supported = yes; then
37007	        WEBP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libwebp >= 0.2.0" 2>&1`
37008        else
37009	        WEBP_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libwebp >= 0.2.0" 2>&1`
37010        fi
37011	# Put the nasty error message in config.log where it belongs
37012	echo "$WEBP_PKG_ERRORS" >&5
37013
37014	as_fn_error $? "Package requirements (libwebp >= 0.2.0) were not met:
37015
37016$WEBP_PKG_ERRORS
37017
37018Consider adjusting the PKG_CONFIG_PATH environment variable if you
37019installed software in a non-standard prefix.
37020
37021Alternatively, you may set the environment variables WEBP_CFLAGS
37022and WEBP_LIBS to avoid the need to call pkg-config.
37023See the pkg-config man page for more details." "$LINENO" 5
37024elif test $pkg_failed = untried; then
37025        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37026printf "%s\n" "no" >&6; }
37027	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37028printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
37029as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
37030is in your PATH or set the PKG_CONFIG environment variable to the full
37031path to pkg-config.
37032
37033Alternatively, you may set the environment variables WEBP_CFLAGS
37034and WEBP_LIBS to avoid the need to call pkg-config.
37035See the pkg-config man page for more details.
37036
37037To get pkg-config, see <http://pkg-config.freedesktop.org/>.
37038See \`config.log' for more details" "$LINENO" 5; }
37039else
37040	WEBP_CFLAGS=$pkg_cv_WEBP_CFLAGS
37041	WEBP_LIBS=$pkg_cv_WEBP_LIBS
37042        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37043printf "%s\n" "yes" >&6; }
37044
37045fi
37046
37047  for ac_i in $WEBP_LIBS; do
37048    case $ac_i in
37049    -pthread)
37050      if test "$ext_shared" = "yes"; then
37051        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
37052      else
37053
37054
37055  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37056
37057  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
37058  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37059    eval "EXTRA_LDFLAGS$unique=set"
37060    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
37061  fi
37062
37063
37064
37065  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37066
37067  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
37068  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37069    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
37070    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
37071  fi
37072
37073      fi
37074    ;;
37075    -l*)
37076      ac_ii=`echo $ac_i|cut -c 3-`
37077
37078
37079  case $ac_ii in
37080  c|c_r) ;;
37081  *)
37082    if test "$ext_shared" = "yes"; then
37083        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
37084    else
37085
37086
37087  case $ac_ii in
37088  c|c_r) ;;
37089  *)
37090      LIBS="$LIBS -l$ac_ii"
37091   ;;
37092  esac
37093
37094
37095    fi
37096   ;;
37097  esac
37098
37099
37100    ;;
37101    -L*)
37102      ac_ii=`echo $ac_i|cut -c 3-`
37103
37104  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
37105
37106  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37107    ai_p=$ac_ii
37108  else
37109
37110    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37111
37112    ep_realdir=`(cd "$ep_dir" && pwd)`
37113    ai_p="$ep_realdir"/`basename "$ac_ii"`
37114  fi
37115
37116
37117      if test "$ext_shared" = "yes"; then
37118        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
37119        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
37120      else
37121
37122
37123
37124  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37125
37126  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
37127  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37128    eval "LIBPATH$unique=set"
37129
37130    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
37131    LDFLAGS="$LDFLAGS -L$ai_p"
37132    PHP_RPATHS="$PHP_RPATHS $ai_p"
37133
37134  fi
37135
37136
37137      fi
37138
37139  fi
37140
37141    ;;
37142    esac
37143  done
37144
37145
37146  for ac_i in $WEBP_CFLAGS; do
37147    case $ac_i in
37148    -I*)
37149      ac_ii=`echo $ac_i|cut -c 3-`
37150
37151  if test "$ac_ii" != "/usr/include"; then
37152
37153  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37154    ai_p=$ac_ii
37155  else
37156
37157    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37158
37159    ep_realdir=`(cd "$ep_dir" && pwd)`
37160    ai_p="$ep_realdir"/`basename "$ac_ii"`
37161  fi
37162
37163
37164
37165  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37166
37167  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
37168  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37169    eval "INCLUDEPATH$unique=set"
37170
37171      if test ""; then
37172        INCLUDES="-I$ai_p $INCLUDES"
37173      else
37174        INCLUDES="$INCLUDES -I$ai_p"
37175      fi
37176
37177  fi
37178
37179  fi
37180
37181    ;;
37182    esac
37183  done
37184
37185
37186printf "%s\n" "#define HAVE_LIBWEBP 1" >>confdefs.h
37187
37188
37189printf "%s\n" "#define HAVE_GD_WEBP 1" >>confdefs.h
37190
37191  fi
37192
37193
37194  if test "$PHP_JPEG" != "no"; then
37195
37196pkg_failed=no
37197{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libjpeg" >&5
37198printf %s "checking for libjpeg... " >&6; }
37199
37200if test -n "$JPEG_CFLAGS"; then
37201    pkg_cv_JPEG_CFLAGS="$JPEG_CFLAGS"
37202 elif test -n "$PKG_CONFIG"; then
37203    if test -n "$PKG_CONFIG" && \
37204    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libjpeg\""; } >&5
37205  ($PKG_CONFIG --exists --print-errors "libjpeg") 2>&5
37206  ac_status=$?
37207  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37208  test $ac_status = 0; }; then
37209  pkg_cv_JPEG_CFLAGS=`$PKG_CONFIG --cflags "libjpeg" 2>/dev/null`
37210		      test "x$?" != "x0" && pkg_failed=yes
37211else
37212  pkg_failed=yes
37213fi
37214 else
37215    pkg_failed=untried
37216fi
37217if test -n "$JPEG_LIBS"; then
37218    pkg_cv_JPEG_LIBS="$JPEG_LIBS"
37219 elif test -n "$PKG_CONFIG"; then
37220    if test -n "$PKG_CONFIG" && \
37221    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libjpeg\""; } >&5
37222  ($PKG_CONFIG --exists --print-errors "libjpeg") 2>&5
37223  ac_status=$?
37224  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37225  test $ac_status = 0; }; then
37226  pkg_cv_JPEG_LIBS=`$PKG_CONFIG --libs "libjpeg" 2>/dev/null`
37227		      test "x$?" != "x0" && pkg_failed=yes
37228else
37229  pkg_failed=yes
37230fi
37231 else
37232    pkg_failed=untried
37233fi
37234
37235
37236
37237if test $pkg_failed = yes; then
37238        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37239printf "%s\n" "no" >&6; }
37240
37241if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
37242        _pkg_short_errors_supported=yes
37243else
37244        _pkg_short_errors_supported=no
37245fi
37246        if test $_pkg_short_errors_supported = yes; then
37247	        JPEG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libjpeg" 2>&1`
37248        else
37249	        JPEG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libjpeg" 2>&1`
37250        fi
37251	# Put the nasty error message in config.log where it belongs
37252	echo "$JPEG_PKG_ERRORS" >&5
37253
37254	as_fn_error $? "Package requirements (libjpeg) were not met:
37255
37256$JPEG_PKG_ERRORS
37257
37258Consider adjusting the PKG_CONFIG_PATH environment variable if you
37259installed software in a non-standard prefix.
37260
37261Alternatively, you may set the environment variables JPEG_CFLAGS
37262and JPEG_LIBS to avoid the need to call pkg-config.
37263See the pkg-config man page for more details." "$LINENO" 5
37264elif test $pkg_failed = untried; then
37265        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37266printf "%s\n" "no" >&6; }
37267	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37268printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
37269as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
37270is in your PATH or set the PKG_CONFIG environment variable to the full
37271path to pkg-config.
37272
37273Alternatively, you may set the environment variables JPEG_CFLAGS
37274and JPEG_LIBS to avoid the need to call pkg-config.
37275See the pkg-config man page for more details.
37276
37277To get pkg-config, see <http://pkg-config.freedesktop.org/>.
37278See \`config.log' for more details" "$LINENO" 5; }
37279else
37280	JPEG_CFLAGS=$pkg_cv_JPEG_CFLAGS
37281	JPEG_LIBS=$pkg_cv_JPEG_LIBS
37282        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37283printf "%s\n" "yes" >&6; }
37284
37285fi
37286
37287  for ac_i in $JPEG_LIBS; do
37288    case $ac_i in
37289    -pthread)
37290      if test "$ext_shared" = "yes"; then
37291        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
37292      else
37293
37294
37295  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37296
37297  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
37298  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37299    eval "EXTRA_LDFLAGS$unique=set"
37300    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
37301  fi
37302
37303
37304
37305  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37306
37307  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
37308  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37309    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
37310    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
37311  fi
37312
37313      fi
37314    ;;
37315    -l*)
37316      ac_ii=`echo $ac_i|cut -c 3-`
37317
37318
37319  case $ac_ii in
37320  c|c_r) ;;
37321  *)
37322    if test "$ext_shared" = "yes"; then
37323        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
37324    else
37325
37326
37327  case $ac_ii in
37328  c|c_r) ;;
37329  *)
37330      LIBS="$LIBS -l$ac_ii"
37331   ;;
37332  esac
37333
37334
37335    fi
37336   ;;
37337  esac
37338
37339
37340    ;;
37341    -L*)
37342      ac_ii=`echo $ac_i|cut -c 3-`
37343
37344  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
37345
37346  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37347    ai_p=$ac_ii
37348  else
37349
37350    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37351
37352    ep_realdir=`(cd "$ep_dir" && pwd)`
37353    ai_p="$ep_realdir"/`basename "$ac_ii"`
37354  fi
37355
37356
37357      if test "$ext_shared" = "yes"; then
37358        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
37359        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
37360      else
37361
37362
37363
37364  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37365
37366  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
37367  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37368    eval "LIBPATH$unique=set"
37369
37370    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
37371    LDFLAGS="$LDFLAGS -L$ai_p"
37372    PHP_RPATHS="$PHP_RPATHS $ai_p"
37373
37374  fi
37375
37376
37377      fi
37378
37379  fi
37380
37381    ;;
37382    esac
37383  done
37384
37385
37386  for ac_i in $JPEG_CFLAGS; do
37387    case $ac_i in
37388    -I*)
37389      ac_ii=`echo $ac_i|cut -c 3-`
37390
37391  if test "$ac_ii" != "/usr/include"; then
37392
37393  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37394    ai_p=$ac_ii
37395  else
37396
37397    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37398
37399    ep_realdir=`(cd "$ep_dir" && pwd)`
37400    ai_p="$ep_realdir"/`basename "$ac_ii"`
37401  fi
37402
37403
37404
37405  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37406
37407  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
37408  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37409    eval "INCLUDEPATH$unique=set"
37410
37411      if test ""; then
37412        INCLUDES="-I$ai_p $INCLUDES"
37413      else
37414        INCLUDES="$INCLUDES -I$ai_p"
37415      fi
37416
37417  fi
37418
37419  fi
37420
37421    ;;
37422    esac
37423  done
37424
37425
37426printf "%s\n" "#define HAVE_LIBJPEG 1" >>confdefs.h
37427
37428
37429printf "%s\n" "#define HAVE_GD_JPG 1" >>confdefs.h
37430
37431  fi
37432
37433
37434  if test "$PHP_XPM" != "no"; then
37435
37436pkg_failed=no
37437{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for xpm" >&5
37438printf %s "checking for xpm... " >&6; }
37439
37440if test -n "$XPM_CFLAGS"; then
37441    pkg_cv_XPM_CFLAGS="$XPM_CFLAGS"
37442 elif test -n "$PKG_CONFIG"; then
37443    if test -n "$PKG_CONFIG" && \
37444    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xpm\""; } >&5
37445  ($PKG_CONFIG --exists --print-errors "xpm") 2>&5
37446  ac_status=$?
37447  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37448  test $ac_status = 0; }; then
37449  pkg_cv_XPM_CFLAGS=`$PKG_CONFIG --cflags "xpm" 2>/dev/null`
37450		      test "x$?" != "x0" && pkg_failed=yes
37451else
37452  pkg_failed=yes
37453fi
37454 else
37455    pkg_failed=untried
37456fi
37457if test -n "$XPM_LIBS"; then
37458    pkg_cv_XPM_LIBS="$XPM_LIBS"
37459 elif test -n "$PKG_CONFIG"; then
37460    if test -n "$PKG_CONFIG" && \
37461    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xpm\""; } >&5
37462  ($PKG_CONFIG --exists --print-errors "xpm") 2>&5
37463  ac_status=$?
37464  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37465  test $ac_status = 0; }; then
37466  pkg_cv_XPM_LIBS=`$PKG_CONFIG --libs "xpm" 2>/dev/null`
37467		      test "x$?" != "x0" && pkg_failed=yes
37468else
37469  pkg_failed=yes
37470fi
37471 else
37472    pkg_failed=untried
37473fi
37474
37475
37476
37477if test $pkg_failed = yes; then
37478        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37479printf "%s\n" "no" >&6; }
37480
37481if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
37482        _pkg_short_errors_supported=yes
37483else
37484        _pkg_short_errors_supported=no
37485fi
37486        if test $_pkg_short_errors_supported = yes; then
37487	        XPM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "xpm" 2>&1`
37488        else
37489	        XPM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "xpm" 2>&1`
37490        fi
37491	# Put the nasty error message in config.log where it belongs
37492	echo "$XPM_PKG_ERRORS" >&5
37493
37494	as_fn_error $? "Package requirements (xpm) were not met:
37495
37496$XPM_PKG_ERRORS
37497
37498Consider adjusting the PKG_CONFIG_PATH environment variable if you
37499installed software in a non-standard prefix.
37500
37501Alternatively, you may set the environment variables XPM_CFLAGS
37502and XPM_LIBS to avoid the need to call pkg-config.
37503See the pkg-config man page for more details." "$LINENO" 5
37504elif test $pkg_failed = untried; then
37505        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37506printf "%s\n" "no" >&6; }
37507	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37508printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
37509as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
37510is in your PATH or set the PKG_CONFIG environment variable to the full
37511path to pkg-config.
37512
37513Alternatively, you may set the environment variables XPM_CFLAGS
37514and XPM_LIBS to avoid the need to call pkg-config.
37515See the pkg-config man page for more details.
37516
37517To get pkg-config, see <http://pkg-config.freedesktop.org/>.
37518See \`config.log' for more details" "$LINENO" 5; }
37519else
37520	XPM_CFLAGS=$pkg_cv_XPM_CFLAGS
37521	XPM_LIBS=$pkg_cv_XPM_LIBS
37522        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37523printf "%s\n" "yes" >&6; }
37524
37525fi
37526
37527  for ac_i in $XPM_LIBS; do
37528    case $ac_i in
37529    -pthread)
37530      if test "$ext_shared" = "yes"; then
37531        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
37532      else
37533
37534
37535  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37536
37537  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
37538  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37539    eval "EXTRA_LDFLAGS$unique=set"
37540    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
37541  fi
37542
37543
37544
37545  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37546
37547  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
37548  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37549    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
37550    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
37551  fi
37552
37553      fi
37554    ;;
37555    -l*)
37556      ac_ii=`echo $ac_i|cut -c 3-`
37557
37558
37559  case $ac_ii in
37560  c|c_r) ;;
37561  *)
37562    if test "$ext_shared" = "yes"; then
37563        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
37564    else
37565
37566
37567  case $ac_ii in
37568  c|c_r) ;;
37569  *)
37570      LIBS="$LIBS -l$ac_ii"
37571   ;;
37572  esac
37573
37574
37575    fi
37576   ;;
37577  esac
37578
37579
37580    ;;
37581    -L*)
37582      ac_ii=`echo $ac_i|cut -c 3-`
37583
37584  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
37585
37586  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37587    ai_p=$ac_ii
37588  else
37589
37590    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37591
37592    ep_realdir=`(cd "$ep_dir" && pwd)`
37593    ai_p="$ep_realdir"/`basename "$ac_ii"`
37594  fi
37595
37596
37597      if test "$ext_shared" = "yes"; then
37598        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
37599        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
37600      else
37601
37602
37603
37604  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37605
37606  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
37607  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37608    eval "LIBPATH$unique=set"
37609
37610    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
37611    LDFLAGS="$LDFLAGS -L$ai_p"
37612    PHP_RPATHS="$PHP_RPATHS $ai_p"
37613
37614  fi
37615
37616
37617      fi
37618
37619  fi
37620
37621    ;;
37622    esac
37623  done
37624
37625
37626  for ac_i in $XPM_CFLAGS; do
37627    case $ac_i in
37628    -I*)
37629      ac_ii=`echo $ac_i|cut -c 3-`
37630
37631  if test "$ac_ii" != "/usr/include"; then
37632
37633  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37634    ai_p=$ac_ii
37635  else
37636
37637    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37638
37639    ep_realdir=`(cd "$ep_dir" && pwd)`
37640    ai_p="$ep_realdir"/`basename "$ac_ii"`
37641  fi
37642
37643
37644
37645  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37646
37647  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
37648  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37649    eval "INCLUDEPATH$unique=set"
37650
37651      if test ""; then
37652        INCLUDES="-I$ai_p $INCLUDES"
37653      else
37654        INCLUDES="$INCLUDES -I$ai_p"
37655      fi
37656
37657  fi
37658
37659  fi
37660
37661    ;;
37662    esac
37663  done
37664
37665
37666printf "%s\n" "#define HAVE_XPM 1" >>confdefs.h
37667
37668
37669printf "%s\n" "#define HAVE_GD_XPM 1" >>confdefs.h
37670
37671  fi
37672
37673
37674  if test "$PHP_FREETYPE" != "no"; then
37675
37676pkg_failed=no
37677{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
37678printf %s "checking for freetype2... " >&6; }
37679
37680if test -n "$FREETYPE2_CFLAGS"; then
37681    pkg_cv_FREETYPE2_CFLAGS="$FREETYPE2_CFLAGS"
37682 elif test -n "$PKG_CONFIG"; then
37683    if test -n "$PKG_CONFIG" && \
37684    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
37685  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
37686  ac_status=$?
37687  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37688  test $ac_status = 0; }; then
37689  pkg_cv_FREETYPE2_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
37690		      test "x$?" != "x0" && pkg_failed=yes
37691else
37692  pkg_failed=yes
37693fi
37694 else
37695    pkg_failed=untried
37696fi
37697if test -n "$FREETYPE2_LIBS"; then
37698    pkg_cv_FREETYPE2_LIBS="$FREETYPE2_LIBS"
37699 elif test -n "$PKG_CONFIG"; then
37700    if test -n "$PKG_CONFIG" && \
37701    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
37702  ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
37703  ac_status=$?
37704  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
37705  test $ac_status = 0; }; then
37706  pkg_cv_FREETYPE2_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
37707		      test "x$?" != "x0" && pkg_failed=yes
37708else
37709  pkg_failed=yes
37710fi
37711 else
37712    pkg_failed=untried
37713fi
37714
37715
37716
37717if test $pkg_failed = yes; then
37718        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37719printf "%s\n" "no" >&6; }
37720
37721if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
37722        _pkg_short_errors_supported=yes
37723else
37724        _pkg_short_errors_supported=no
37725fi
37726        if test $_pkg_short_errors_supported = yes; then
37727	        FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "freetype2" 2>&1`
37728        else
37729	        FREETYPE2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "freetype2" 2>&1`
37730        fi
37731	# Put the nasty error message in config.log where it belongs
37732	echo "$FREETYPE2_PKG_ERRORS" >&5
37733
37734	as_fn_error $? "Package requirements (freetype2) were not met:
37735
37736$FREETYPE2_PKG_ERRORS
37737
37738Consider adjusting the PKG_CONFIG_PATH environment variable if you
37739installed software in a non-standard prefix.
37740
37741Alternatively, you may set the environment variables FREETYPE2_CFLAGS
37742and FREETYPE2_LIBS to avoid the need to call pkg-config.
37743See the pkg-config man page for more details." "$LINENO" 5
37744elif test $pkg_failed = untried; then
37745        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
37746printf "%s\n" "no" >&6; }
37747	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37748printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
37749as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
37750is in your PATH or set the PKG_CONFIG environment variable to the full
37751path to pkg-config.
37752
37753Alternatively, you may set the environment variables FREETYPE2_CFLAGS
37754and FREETYPE2_LIBS to avoid the need to call pkg-config.
37755See the pkg-config man page for more details.
37756
37757To get pkg-config, see <http://pkg-config.freedesktop.org/>.
37758See \`config.log' for more details" "$LINENO" 5; }
37759else
37760	FREETYPE2_CFLAGS=$pkg_cv_FREETYPE2_CFLAGS
37761	FREETYPE2_LIBS=$pkg_cv_FREETYPE2_LIBS
37762        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37763printf "%s\n" "yes" >&6; }
37764	FREETYPE2_FOUND=true
37765fi
37766
37767
37768  for ac_i in $FREETYPE2_CFLAGS; do
37769    case $ac_i in
37770    -I*)
37771      ac_ii=`echo $ac_i|cut -c 3-`
37772
37773  if test "$ac_ii" != "/usr/include"; then
37774
37775  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37776    ai_p=$ac_ii
37777  else
37778
37779    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37780
37781    ep_realdir=`(cd "$ep_dir" && pwd)`
37782    ai_p="$ep_realdir"/`basename "$ac_ii"`
37783  fi
37784
37785
37786
37787  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37788
37789  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
37790  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37791    eval "INCLUDEPATH$unique=set"
37792
37793      if test ""; then
37794        INCLUDES="-I$ai_p $INCLUDES"
37795      else
37796        INCLUDES="$INCLUDES -I$ai_p"
37797      fi
37798
37799  fi
37800
37801  fi
37802
37803    ;;
37804    esac
37805  done
37806
37807
37808  for ac_i in $FREETYPE2_LIBS; do
37809    case $ac_i in
37810    -pthread)
37811      if test "$ext_shared" = "yes"; then
37812        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
37813      else
37814
37815
37816  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37817
37818  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
37819  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37820    eval "EXTRA_LDFLAGS$unique=set"
37821    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
37822  fi
37823
37824
37825
37826  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
37827
37828  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
37829  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37830    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
37831    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
37832  fi
37833
37834      fi
37835    ;;
37836    -l*)
37837      ac_ii=`echo $ac_i|cut -c 3-`
37838
37839
37840  case $ac_ii in
37841  c|c_r) ;;
37842  *)
37843    if test "$ext_shared" = "yes"; then
37844        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
37845    else
37846
37847
37848  case $ac_ii in
37849  c|c_r) ;;
37850  *)
37851      LIBS="$LIBS -l$ac_ii"
37852   ;;
37853  esac
37854
37855
37856    fi
37857   ;;
37858  esac
37859
37860
37861    ;;
37862    -L*)
37863      ac_ii=`echo $ac_i|cut -c 3-`
37864
37865  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
37866
37867  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
37868    ai_p=$ac_ii
37869  else
37870
37871    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
37872
37873    ep_realdir=`(cd "$ep_dir" && pwd)`
37874    ai_p="$ep_realdir"/`basename "$ac_ii"`
37875  fi
37876
37877
37878      if test "$ext_shared" = "yes"; then
37879        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
37880        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
37881      else
37882
37883
37884
37885  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
37886
37887  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
37888  if test -n "$unique" && test "`eval $cmd`" = "" ; then
37889    eval "LIBPATH$unique=set"
37890
37891    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
37892    LDFLAGS="$LDFLAGS -L$ai_p"
37893    PHP_RPATHS="$PHP_RPATHS $ai_p"
37894
37895  fi
37896
37897
37898      fi
37899
37900  fi
37901
37902    ;;
37903    esac
37904  done
37905
37906
37907printf "%s\n" "#define HAVE_LIBFREETYPE 1" >>confdefs.h
37908
37909
37910printf "%s\n" "#define HAVE_GD_FREETYPE 1" >>confdefs.h
37911
37912  fi
37913
37914
37915  if test "$PHP_GD_JIS_CONV" = "yes"; then
37916
37917printf "%s\n" "#define USE_GD_JISX0208 1" >>confdefs.h
37918
37919
37920printf "%s\n" "#define JISX0208 1" >>confdefs.h
37921
37922  fi
37923
37924
37925
37926  ext_builddir=ext/gd
37927  ext_srcdir=$abs_srcdir/ext/gd
37928  ext_dir=ext/gd
37929
37930  ac_extra=`echo "\\$(GD_CFLAGS)"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
37931
37932  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
37933    PHP_GD_SHARED=no
37934
37935
37936  case $ext_dir in
37937  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
37938  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
37939  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
37940  esac
37941
37942
37943
37944  b_c_pre=$php_c_pre
37945  b_cxx_pre=$php_cxx_pre
37946  b_c_meta=$php_c_meta
37947  b_cxx_meta=$php_cxx_meta
37948  b_c_post=$php_c_post
37949  b_cxx_post=$php_cxx_post
37950  b_lo=$php_lo
37951
37952
37953  old_IFS=$IFS
37954  for ac_src in gd.c $extra_sources; do
37955
37956      IFS=.
37957      set $ac_src
37958      ac_obj=$1
37959      IFS=$old_IFS
37960
37961      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
37962
37963      case $ac_src in
37964        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
37965        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
37966        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
37967        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
37968      esac
37969
37970      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
37971
37972    cat >>Makefile.objects<<EOF
37973-include $ac_bdir$ac_obj.dep
37974$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
37975	$ac_comp
37976EOF
37977  done
37978
37979
37980    EXT_STATIC="$EXT_STATIC gd;$ext_dir"
37981    if test "$ext_shared" != "nocli"; then
37982      EXT_CLI_STATIC="$EXT_CLI_STATIC gd;$ext_dir"
37983    fi
37984  else
37985    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
37986      PHP_GD_SHARED=yes
37987
37988  case $ext_dir in
37989  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
37990  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
37991  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
37992  esac
37993
37994
37995
37996  b_c_pre=$shared_c_pre
37997  b_cxx_pre=$shared_cxx_pre
37998  b_c_meta=$shared_c_meta
37999  b_cxx_meta=$shared_cxx_meta
38000  b_c_post=$shared_c_post
38001  b_cxx_post=$shared_cxx_post
38002  b_lo=$shared_lo
38003
38004
38005  old_IFS=$IFS
38006  for ac_src in gd.c $extra_sources; do
38007
38008      IFS=.
38009      set $ac_src
38010      ac_obj=$1
38011      IFS=$old_IFS
38012
38013      shared_objects_gd="$shared_objects_gd $ac_bdir$ac_obj.lo"
38014
38015      case $ac_src in
38016        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38017        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38018        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38019        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
38020      esac
38021
38022      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
38023
38024    cat >>Makefile.objects<<EOF
38025-include $ac_bdir$ac_obj.dep
38026$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
38027	$ac_comp
38028EOF
38029  done
38030
38031
38032  install_modules="install-modules"
38033  suffix=la
38034
38035  case $host_alias in
38036    *aix*)
38037      additional_flags="-Wl,-G"
38038      ;;
38039  esac
38040
38041  if test "x" = "xyes"; then
38042    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/gd.$suffix"
38043  else
38044    PHP_MODULES="$PHP_MODULES \$(phplibdir)/gd.$suffix"
38045  fi
38046
38047  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_gd"
38048
38049  cat >>Makefile.objects<<EOF
38050\$(phplibdir)/gd.$suffix: $ext_builddir/gd.$suffix
38051	\$(LIBTOOL) --mode=install cp $ext_builddir/gd.$suffix \$(phplibdir)
38052
38053$ext_builddir/gd.$suffix: \$(shared_objects_gd) \$(GD_SHARED_DEPENDENCIES)
38054	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_gd) \$(GD_SHARED_LIBADD)
38055
38056EOF
38057
38058
38059printf "%s\n" "#define COMPILE_DL_GD 1" >>confdefs.h
38060
38061    fi
38062  fi
38063
38064  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
38065    PHP_GD_SHARED=no
38066    case "$PHP_SAPI" in
38067      cgi|embed|phpdbg)
38068
38069
38070  case $ext_dir in
38071  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
38072  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
38073  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
38074  esac
38075
38076
38077
38078  b_c_pre=$php_c_pre
38079  b_cxx_pre=$php_cxx_pre
38080  b_c_meta=$php_c_meta
38081  b_cxx_meta=$php_cxx_meta
38082  b_c_post=$php_c_post
38083  b_cxx_post=$php_cxx_post
38084  b_lo=$php_lo
38085
38086
38087  old_IFS=$IFS
38088  for ac_src in gd.c $extra_sources; do
38089
38090      IFS=.
38091      set $ac_src
38092      ac_obj=$1
38093      IFS=$old_IFS
38094
38095      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
38096
38097      case $ac_src in
38098        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38099        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38100        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38101        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
38102      esac
38103
38104      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
38105
38106    cat >>Makefile.objects<<EOF
38107-include $ac_bdir$ac_obj.dep
38108$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
38109	$ac_comp
38110EOF
38111  done
38112
38113
38114        EXT_STATIC="$EXT_STATIC gd;$ext_dir"
38115        ;;
38116      *)
38117
38118
38119  case $ext_dir in
38120  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
38121  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
38122  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
38123  esac
38124
38125
38126
38127  b_c_pre=$php_c_pre
38128  b_cxx_pre=$php_cxx_pre
38129  b_c_meta=$php_c_meta
38130  b_cxx_meta=$php_cxx_meta
38131  b_c_post=$php_c_post
38132  b_cxx_post=$php_cxx_post
38133  b_lo=$php_lo
38134
38135
38136  old_IFS=$IFS
38137  for ac_src in gd.c $extra_sources; do
38138
38139      IFS=.
38140      set $ac_src
38141      ac_obj=$1
38142      IFS=$old_IFS
38143
38144      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
38145
38146      case $ac_src in
38147        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38148        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38149        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
38150        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
38151      esac
38152
38153      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
38154
38155    cat >>Makefile.objects<<EOF
38156-include $ac_bdir$ac_obj.dep
38157$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
38158	$ac_comp
38159EOF
38160  done
38161
38162
38163        ;;
38164    esac
38165    EXT_CLI_STATIC="$EXT_CLI_STATIC gd;$ext_dir"
38166  fi
38167
38168
38169    BUILD_DIR="$BUILD_DIR $ext_builddir"
38170
38171
38172
38173  if test "$ext_builddir" = "."; then
38174    PHP_PECL_EXTENSION=gd
38175
38176  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
38177
38178  fi
38179
38180
38181
38182    BUILD_DIR="$BUILD_DIR $ext_builddir/libgd"
38183
38184
38185    GD_CFLAGS="-I$ext_srcdir/libgd $GD_CFLAGS"
38186    GD_HEADER_DIRS="ext/gd/ ext/gd/libgd/"
38187
38188
38189  old_LIBS=$LIBS
38190  LIBS=" $GD_SHARED_LIBADD  $LIBS"
38191  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38192/* end confdefs.h.  */
38193
38194    char foobar () {}
38195    char foobar();
38196    int main() {
38197      foobar();
38198      return 0;
38199    }
38200
38201_ACEOF
38202if ac_fn_c_try_link "$LINENO"
38203then :
38204
38205    LIBS=$old_LIBS
38206
38207
38208else $as_nop
38209
38210    LIBS=$old_LIBS
38211
38212      as_fn_error $? "GD build test failed. Please check the config.log for details." "$LINENO" 5
38213
38214
38215fi
38216rm -f core conftest.err conftest.$ac_objext conftest.beam \
38217    conftest$ac_exeext conftest.$ac_ext
38218
38219
38220  else
38221    extra_sources="gd_compat.c"
38222
38223pkg_failed=no
38224{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdlib >= 2.1.0" >&5
38225printf %s "checking for gdlib >= 2.1.0... " >&6; }
38226
38227if test -n "$GDLIB_CFLAGS"; then
38228    pkg_cv_GDLIB_CFLAGS="$GDLIB_CFLAGS"
38229 elif test -n "$PKG_CONFIG"; then
38230    if test -n "$PKG_CONFIG" && \
38231    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gdlib >= 2.1.0\""; } >&5
38232  ($PKG_CONFIG --exists --print-errors "gdlib >= 2.1.0") 2>&5
38233  ac_status=$?
38234  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38235  test $ac_status = 0; }; then
38236  pkg_cv_GDLIB_CFLAGS=`$PKG_CONFIG --cflags "gdlib >= 2.1.0" 2>/dev/null`
38237		      test "x$?" != "x0" && pkg_failed=yes
38238else
38239  pkg_failed=yes
38240fi
38241 else
38242    pkg_failed=untried
38243fi
38244if test -n "$GDLIB_LIBS"; then
38245    pkg_cv_GDLIB_LIBS="$GDLIB_LIBS"
38246 elif test -n "$PKG_CONFIG"; then
38247    if test -n "$PKG_CONFIG" && \
38248    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gdlib >= 2.1.0\""; } >&5
38249  ($PKG_CONFIG --exists --print-errors "gdlib >= 2.1.0") 2>&5
38250  ac_status=$?
38251  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38252  test $ac_status = 0; }; then
38253  pkg_cv_GDLIB_LIBS=`$PKG_CONFIG --libs "gdlib >= 2.1.0" 2>/dev/null`
38254		      test "x$?" != "x0" && pkg_failed=yes
38255else
38256  pkg_failed=yes
38257fi
38258 else
38259    pkg_failed=untried
38260fi
38261
38262
38263
38264if test $pkg_failed = yes; then
38265        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
38266printf "%s\n" "no" >&6; }
38267
38268if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
38269        _pkg_short_errors_supported=yes
38270else
38271        _pkg_short_errors_supported=no
38272fi
38273        if test $_pkg_short_errors_supported = yes; then
38274	        GDLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gdlib >= 2.1.0" 2>&1`
38275        else
38276	        GDLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gdlib >= 2.1.0" 2>&1`
38277        fi
38278	# Put the nasty error message in config.log where it belongs
38279	echo "$GDLIB_PKG_ERRORS" >&5
38280
38281	as_fn_error $? "Package requirements (gdlib >= 2.1.0) were not met:
38282
38283$GDLIB_PKG_ERRORS
38284
38285Consider adjusting the PKG_CONFIG_PATH environment variable if you
38286installed software in a non-standard prefix.
38287
38288Alternatively, you may set the environment variables GDLIB_CFLAGS
38289and GDLIB_LIBS to avoid the need to call pkg-config.
38290See the pkg-config man page for more details." "$LINENO" 5
38291elif test $pkg_failed = untried; then
38292        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
38293printf "%s\n" "no" >&6; }
38294	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
38295printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
38296as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
38297is in your PATH or set the PKG_CONFIG environment variable to the full
38298path to pkg-config.
38299
38300Alternatively, you may set the environment variables GDLIB_CFLAGS
38301and GDLIB_LIBS to avoid the need to call pkg-config.
38302See the pkg-config man page for more details.
38303
38304To get pkg-config, see <http://pkg-config.freedesktop.org/>.
38305See \`config.log' for more details" "$LINENO" 5; }
38306else
38307	GDLIB_CFLAGS=$pkg_cv_GDLIB_CFLAGS
38308	GDLIB_LIBS=$pkg_cv_GDLIB_LIBS
38309        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38310printf "%s\n" "yes" >&6; }
38311
38312fi
38313
38314  for ac_i in $GDLIB_LIBS; do
38315    case $ac_i in
38316    -pthread)
38317      if test "$ext_shared" = "yes"; then
38318        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -pthread"
38319      else
38320
38321
38322  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38323
38324  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
38325  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38326    eval "EXTRA_LDFLAGS$unique=set"
38327    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
38328  fi
38329
38330
38331
38332  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38333
38334  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
38335  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38336    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
38337    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
38338  fi
38339
38340      fi
38341    ;;
38342    -l*)
38343      ac_ii=`echo $ac_i|cut -c 3-`
38344
38345
38346  case $ac_ii in
38347  c|c_r) ;;
38348  *)
38349    if test "$ext_shared" = "yes"; then
38350        GD_SHARED_LIBADD="$GD_SHARED_LIBADD -l$ac_ii"
38351    else
38352
38353
38354  case $ac_ii in
38355  c|c_r) ;;
38356  *)
38357      LIBS="$LIBS -l$ac_ii"
38358   ;;
38359  esac
38360
38361
38362    fi
38363   ;;
38364  esac
38365
38366
38367    ;;
38368    -L*)
38369      ac_ii=`echo $ac_i|cut -c 3-`
38370
38371  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
38372
38373  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38374    ai_p=$ac_ii
38375  else
38376
38377    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
38378
38379    ep_realdir=`(cd "$ep_dir" && pwd)`
38380    ai_p="$ep_realdir"/`basename "$ac_ii"`
38381  fi
38382
38383
38384      if test "$ext_shared" = "yes"; then
38385        GD_SHARED_LIBADD="-L$ai_p $GD_SHARED_LIBADD"
38386        test -n "$ld_runpath_switch" && GD_SHARED_LIBADD="$ld_runpath_switch$ai_p $GD_SHARED_LIBADD"
38387      else
38388
38389
38390
38391  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
38392
38393  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
38394  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38395    eval "LIBPATH$unique=set"
38396
38397    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
38398    LDFLAGS="$LDFLAGS -L$ai_p"
38399    PHP_RPATHS="$PHP_RPATHS $ai_p"
38400
38401  fi
38402
38403
38404      fi
38405
38406  fi
38407
38408    ;;
38409    esac
38410  done
38411
38412
38413  for ac_i in $GDLIB_CFLAGS; do
38414    case $ac_i in
38415    -I*)
38416      ac_ii=`echo $ac_i|cut -c 3-`
38417
38418  if test "$ac_ii" != "/usr/include"; then
38419
38420  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38421    ai_p=$ac_ii
38422  else
38423
38424    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
38425
38426    ep_realdir=`(cd "$ep_dir" && pwd)`
38427    ai_p="$ep_realdir"/`basename "$ac_ii"`
38428  fi
38429
38430
38431
38432  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
38433
38434  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
38435  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38436    eval "INCLUDEPATH$unique=set"
38437
38438      if test ""; then
38439        INCLUDES="-I$ai_p $INCLUDES"
38440      else
38441        INCLUDES="$INCLUDES -I$ai_p"
38442      fi
38443
38444  fi
38445
38446  fi
38447
38448    ;;
38449    esac
38450  done
38451
38452
38453printf "%s\n" "#define HAVE_LIBGD 1" >>confdefs.h
38454
38455
38456
38457  save_old_LDFLAGS=$LDFLAGS
38458  ac_stuff=" $GD_SHARED_LIBADD "
38459
38460  save_ext_shared=$ext_shared
38461  ext_shared=yes
38462
38463  for ac_i in $ac_stuff; do
38464    case $ac_i in
38465    -pthread)
38466      if test "$ext_shared" = "yes"; then
38467        LDFLAGS="$LDFLAGS -pthread"
38468      else
38469
38470
38471  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38472
38473  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
38474  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38475    eval "EXTRA_LDFLAGS$unique=set"
38476    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
38477  fi
38478
38479
38480
38481  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38482
38483  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
38484  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38485    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
38486    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
38487  fi
38488
38489      fi
38490    ;;
38491    -l*)
38492      ac_ii=`echo $ac_i|cut -c 3-`
38493
38494
38495  case $ac_ii in
38496  c|c_r) ;;
38497  *)
38498    if test "$ext_shared" = "yes"; then
38499        LDFLAGS="$LDFLAGS -l$ac_ii"
38500    else
38501
38502
38503  case $ac_ii in
38504  c|c_r) ;;
38505  *)
38506      LIBS="$LIBS -l$ac_ii"
38507   ;;
38508  esac
38509
38510
38511    fi
38512   ;;
38513  esac
38514
38515
38516    ;;
38517    -L*)
38518      ac_ii=`echo $ac_i|cut -c 3-`
38519
38520  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
38521
38522  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38523    ai_p=$ac_ii
38524  else
38525
38526    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
38527
38528    ep_realdir=`(cd "$ep_dir" && pwd)`
38529    ai_p="$ep_realdir"/`basename "$ac_ii"`
38530  fi
38531
38532
38533      if test "$ext_shared" = "yes"; then
38534        LDFLAGS="-L$ai_p $LDFLAGS"
38535        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
38536      else
38537
38538
38539
38540  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
38541
38542  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
38543  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38544    eval "LIBPATH$unique=set"
38545
38546    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
38547    LDFLAGS="$LDFLAGS -L$ai_p"
38548    PHP_RPATHS="$PHP_RPATHS $ai_p"
38549
38550  fi
38551
38552
38553      fi
38554
38555  fi
38556
38557    ;;
38558    esac
38559  done
38560
38561  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromPng in -lgd" >&5
38562printf %s "checking for gdImageCreateFromPng in -lgd... " >&6; }
38563if test ${ac_cv_lib_gd_gdImageCreateFromPng+y}
38564then :
38565  printf %s "(cached) " >&6
38566else $as_nop
38567  ac_check_lib_save_LIBS=$LIBS
38568LIBS="-lgd  $LIBS"
38569cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38570/* end confdefs.h.  */
38571
38572/* Override any GCC internal prototype to avoid an error.
38573   Use char because int might match the return type of a GCC
38574   builtin and then its argument prototype would still apply.  */
38575char gdImageCreateFromPng ();
38576int
38577main (void)
38578{
38579return gdImageCreateFromPng ();
38580  ;
38581  return 0;
38582}
38583_ACEOF
38584if ac_fn_c_try_link "$LINENO"
38585then :
38586  ac_cv_lib_gd_gdImageCreateFromPng=yes
38587else $as_nop
38588  ac_cv_lib_gd_gdImageCreateFromPng=no
38589fi
38590rm -f core conftest.err conftest.$ac_objext conftest.beam \
38591    conftest$ac_exeext conftest.$ac_ext
38592LIBS=$ac_check_lib_save_LIBS
38593fi
38594{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromPng" >&5
38595printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromPng" >&6; }
38596if test "x$ac_cv_lib_gd_gdImageCreateFromPng" = xyes
38597then :
38598
38599    LDFLAGS=$save_old_LDFLAGS
38600    ext_shared=$save_ext_shared
38601
38602printf "%s\n" "#define HAVE_GD_PNG 1" >>confdefs.h
38603
38604
38605else $as_nop
38606
38607    LDFLAGS=$save_old_LDFLAGS
38608    ext_shared=$save_ext_shared
38609    unset ac_cv_lib_gd_gdImageCreateFromPng
38610
38611
38612fi
38613
38614
38615  save_old_LDFLAGS=$LDFLAGS
38616  ac_stuff=" $GD_SHARED_LIBADD "
38617
38618  save_ext_shared=$ext_shared
38619  ext_shared=yes
38620
38621  for ac_i in $ac_stuff; do
38622    case $ac_i in
38623    -pthread)
38624      if test "$ext_shared" = "yes"; then
38625        LDFLAGS="$LDFLAGS -pthread"
38626      else
38627
38628
38629  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38630
38631  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
38632  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38633    eval "EXTRA_LDFLAGS$unique=set"
38634    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
38635  fi
38636
38637
38638
38639  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38640
38641  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
38642  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38643    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
38644    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
38645  fi
38646
38647      fi
38648    ;;
38649    -l*)
38650      ac_ii=`echo $ac_i|cut -c 3-`
38651
38652
38653  case $ac_ii in
38654  c|c_r) ;;
38655  *)
38656    if test "$ext_shared" = "yes"; then
38657        LDFLAGS="$LDFLAGS -l$ac_ii"
38658    else
38659
38660
38661  case $ac_ii in
38662  c|c_r) ;;
38663  *)
38664      LIBS="$LIBS -l$ac_ii"
38665   ;;
38666  esac
38667
38668
38669    fi
38670   ;;
38671  esac
38672
38673
38674    ;;
38675    -L*)
38676      ac_ii=`echo $ac_i|cut -c 3-`
38677
38678  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
38679
38680  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38681    ai_p=$ac_ii
38682  else
38683
38684    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
38685
38686    ep_realdir=`(cd "$ep_dir" && pwd)`
38687    ai_p="$ep_realdir"/`basename "$ac_ii"`
38688  fi
38689
38690
38691      if test "$ext_shared" = "yes"; then
38692        LDFLAGS="-L$ai_p $LDFLAGS"
38693        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
38694      else
38695
38696
38697
38698  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
38699
38700  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
38701  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38702    eval "LIBPATH$unique=set"
38703
38704    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
38705    LDFLAGS="$LDFLAGS -L$ai_p"
38706    PHP_RPATHS="$PHP_RPATHS $ai_p"
38707
38708  fi
38709
38710
38711      fi
38712
38713  fi
38714
38715    ;;
38716    esac
38717  done
38718
38719  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromAvif in -lgd" >&5
38720printf %s "checking for gdImageCreateFromAvif in -lgd... " >&6; }
38721if test ${ac_cv_lib_gd_gdImageCreateFromAvif+y}
38722then :
38723  printf %s "(cached) " >&6
38724else $as_nop
38725  ac_check_lib_save_LIBS=$LIBS
38726LIBS="-lgd  $LIBS"
38727cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38728/* end confdefs.h.  */
38729
38730/* Override any GCC internal prototype to avoid an error.
38731   Use char because int might match the return type of a GCC
38732   builtin and then its argument prototype would still apply.  */
38733char gdImageCreateFromAvif ();
38734int
38735main (void)
38736{
38737return gdImageCreateFromAvif ();
38738  ;
38739  return 0;
38740}
38741_ACEOF
38742if ac_fn_c_try_link "$LINENO"
38743then :
38744  ac_cv_lib_gd_gdImageCreateFromAvif=yes
38745else $as_nop
38746  ac_cv_lib_gd_gdImageCreateFromAvif=no
38747fi
38748rm -f core conftest.err conftest.$ac_objext conftest.beam \
38749    conftest$ac_exeext conftest.$ac_ext
38750LIBS=$ac_check_lib_save_LIBS
38751fi
38752{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromAvif" >&5
38753printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromAvif" >&6; }
38754if test "x$ac_cv_lib_gd_gdImageCreateFromAvif" = xyes
38755then :
38756
38757    LDFLAGS=$save_old_LDFLAGS
38758    ext_shared=$save_ext_shared
38759
38760printf "%s\n" "#define HAVE_GD_AVIF 1" >>confdefs.h
38761
38762
38763else $as_nop
38764
38765    LDFLAGS=$save_old_LDFLAGS
38766    ext_shared=$save_ext_shared
38767    unset ac_cv_lib_gd_gdImageCreateFromAvif
38768
38769
38770fi
38771
38772
38773  save_old_LDFLAGS=$LDFLAGS
38774  ac_stuff=" $GD_SHARED_LIBADD "
38775
38776  save_ext_shared=$ext_shared
38777  ext_shared=yes
38778
38779  for ac_i in $ac_stuff; do
38780    case $ac_i in
38781    -pthread)
38782      if test "$ext_shared" = "yes"; then
38783        LDFLAGS="$LDFLAGS -pthread"
38784      else
38785
38786
38787  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38788
38789  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
38790  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38791    eval "EXTRA_LDFLAGS$unique=set"
38792    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
38793  fi
38794
38795
38796
38797  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38798
38799  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
38800  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38801    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
38802    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
38803  fi
38804
38805      fi
38806    ;;
38807    -l*)
38808      ac_ii=`echo $ac_i|cut -c 3-`
38809
38810
38811  case $ac_ii in
38812  c|c_r) ;;
38813  *)
38814    if test "$ext_shared" = "yes"; then
38815        LDFLAGS="$LDFLAGS -l$ac_ii"
38816    else
38817
38818
38819  case $ac_ii in
38820  c|c_r) ;;
38821  *)
38822      LIBS="$LIBS -l$ac_ii"
38823   ;;
38824  esac
38825
38826
38827    fi
38828   ;;
38829  esac
38830
38831
38832    ;;
38833    -L*)
38834      ac_ii=`echo $ac_i|cut -c 3-`
38835
38836  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
38837
38838  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38839    ai_p=$ac_ii
38840  else
38841
38842    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
38843
38844    ep_realdir=`(cd "$ep_dir" && pwd)`
38845    ai_p="$ep_realdir"/`basename "$ac_ii"`
38846  fi
38847
38848
38849      if test "$ext_shared" = "yes"; then
38850        LDFLAGS="-L$ai_p $LDFLAGS"
38851        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
38852      else
38853
38854
38855
38856  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
38857
38858  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
38859  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38860    eval "LIBPATH$unique=set"
38861
38862    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
38863    LDFLAGS="$LDFLAGS -L$ai_p"
38864    PHP_RPATHS="$PHP_RPATHS $ai_p"
38865
38866  fi
38867
38868
38869      fi
38870
38871  fi
38872
38873    ;;
38874    esac
38875  done
38876
38877  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromWebp in -lgd" >&5
38878printf %s "checking for gdImageCreateFromWebp in -lgd... " >&6; }
38879if test ${ac_cv_lib_gd_gdImageCreateFromWebp+y}
38880then :
38881  printf %s "(cached) " >&6
38882else $as_nop
38883  ac_check_lib_save_LIBS=$LIBS
38884LIBS="-lgd  $LIBS"
38885cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38886/* end confdefs.h.  */
38887
38888/* Override any GCC internal prototype to avoid an error.
38889   Use char because int might match the return type of a GCC
38890   builtin and then its argument prototype would still apply.  */
38891char gdImageCreateFromWebp ();
38892int
38893main (void)
38894{
38895return gdImageCreateFromWebp ();
38896  ;
38897  return 0;
38898}
38899_ACEOF
38900if ac_fn_c_try_link "$LINENO"
38901then :
38902  ac_cv_lib_gd_gdImageCreateFromWebp=yes
38903else $as_nop
38904  ac_cv_lib_gd_gdImageCreateFromWebp=no
38905fi
38906rm -f core conftest.err conftest.$ac_objext conftest.beam \
38907    conftest$ac_exeext conftest.$ac_ext
38908LIBS=$ac_check_lib_save_LIBS
38909fi
38910{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromWebp" >&5
38911printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromWebp" >&6; }
38912if test "x$ac_cv_lib_gd_gdImageCreateFromWebp" = xyes
38913then :
38914
38915    LDFLAGS=$save_old_LDFLAGS
38916    ext_shared=$save_ext_shared
38917
38918printf "%s\n" "#define HAVE_GD_WEBP 1" >>confdefs.h
38919
38920
38921else $as_nop
38922
38923    LDFLAGS=$save_old_LDFLAGS
38924    ext_shared=$save_ext_shared
38925    unset ac_cv_lib_gd_gdImageCreateFromWebp
38926
38927
38928fi
38929
38930
38931  save_old_LDFLAGS=$LDFLAGS
38932  ac_stuff=" $GD_SHARED_LIBADD "
38933
38934  save_ext_shared=$ext_shared
38935  ext_shared=yes
38936
38937  for ac_i in $ac_stuff; do
38938    case $ac_i in
38939    -pthread)
38940      if test "$ext_shared" = "yes"; then
38941        LDFLAGS="$LDFLAGS -pthread"
38942      else
38943
38944
38945  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38946
38947  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
38948  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38949    eval "EXTRA_LDFLAGS$unique=set"
38950    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
38951  fi
38952
38953
38954
38955  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
38956
38957  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
38958  if test -n "$unique" && test "`eval $cmd`" = "" ; then
38959    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
38960    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
38961  fi
38962
38963      fi
38964    ;;
38965    -l*)
38966      ac_ii=`echo $ac_i|cut -c 3-`
38967
38968
38969  case $ac_ii in
38970  c|c_r) ;;
38971  *)
38972    if test "$ext_shared" = "yes"; then
38973        LDFLAGS="$LDFLAGS -l$ac_ii"
38974    else
38975
38976
38977  case $ac_ii in
38978  c|c_r) ;;
38979  *)
38980      LIBS="$LIBS -l$ac_ii"
38981   ;;
38982  esac
38983
38984
38985    fi
38986   ;;
38987  esac
38988
38989
38990    ;;
38991    -L*)
38992      ac_ii=`echo $ac_i|cut -c 3-`
38993
38994  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
38995
38996  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
38997    ai_p=$ac_ii
38998  else
38999
39000    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39001
39002    ep_realdir=`(cd "$ep_dir" && pwd)`
39003    ai_p="$ep_realdir"/`basename "$ac_ii"`
39004  fi
39005
39006
39007      if test "$ext_shared" = "yes"; then
39008        LDFLAGS="-L$ai_p $LDFLAGS"
39009        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39010      else
39011
39012
39013
39014  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39015
39016  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39017  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39018    eval "LIBPATH$unique=set"
39019
39020    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39021    LDFLAGS="$LDFLAGS -L$ai_p"
39022    PHP_RPATHS="$PHP_RPATHS $ai_p"
39023
39024  fi
39025
39026
39027      fi
39028
39029  fi
39030
39031    ;;
39032    esac
39033  done
39034
39035  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromJpeg in -lgd" >&5
39036printf %s "checking for gdImageCreateFromJpeg in -lgd... " >&6; }
39037if test ${ac_cv_lib_gd_gdImageCreateFromJpeg+y}
39038then :
39039  printf %s "(cached) " >&6
39040else $as_nop
39041  ac_check_lib_save_LIBS=$LIBS
39042LIBS="-lgd  $LIBS"
39043cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39044/* end confdefs.h.  */
39045
39046/* Override any GCC internal prototype to avoid an error.
39047   Use char because int might match the return type of a GCC
39048   builtin and then its argument prototype would still apply.  */
39049char gdImageCreateFromJpeg ();
39050int
39051main (void)
39052{
39053return gdImageCreateFromJpeg ();
39054  ;
39055  return 0;
39056}
39057_ACEOF
39058if ac_fn_c_try_link "$LINENO"
39059then :
39060  ac_cv_lib_gd_gdImageCreateFromJpeg=yes
39061else $as_nop
39062  ac_cv_lib_gd_gdImageCreateFromJpeg=no
39063fi
39064rm -f core conftest.err conftest.$ac_objext conftest.beam \
39065    conftest$ac_exeext conftest.$ac_ext
39066LIBS=$ac_check_lib_save_LIBS
39067fi
39068{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromJpeg" >&5
39069printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromJpeg" >&6; }
39070if test "x$ac_cv_lib_gd_gdImageCreateFromJpeg" = xyes
39071then :
39072
39073    LDFLAGS=$save_old_LDFLAGS
39074    ext_shared=$save_ext_shared
39075
39076printf "%s\n" "#define HAVE_GD_JPG 1" >>confdefs.h
39077
39078
39079else $as_nop
39080
39081    LDFLAGS=$save_old_LDFLAGS
39082    ext_shared=$save_ext_shared
39083    unset ac_cv_lib_gd_gdImageCreateFromJpeg
39084
39085
39086fi
39087
39088
39089  save_old_LDFLAGS=$LDFLAGS
39090  ac_stuff=" $GD_SHARED_LIBADD "
39091
39092  save_ext_shared=$ext_shared
39093  ext_shared=yes
39094
39095  for ac_i in $ac_stuff; do
39096    case $ac_i in
39097    -pthread)
39098      if test "$ext_shared" = "yes"; then
39099        LDFLAGS="$LDFLAGS -pthread"
39100      else
39101
39102
39103  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39104
39105  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39106  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39107    eval "EXTRA_LDFLAGS$unique=set"
39108    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39109  fi
39110
39111
39112
39113  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39114
39115  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39116  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39117    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39118    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39119  fi
39120
39121      fi
39122    ;;
39123    -l*)
39124      ac_ii=`echo $ac_i|cut -c 3-`
39125
39126
39127  case $ac_ii in
39128  c|c_r) ;;
39129  *)
39130    if test "$ext_shared" = "yes"; then
39131        LDFLAGS="$LDFLAGS -l$ac_ii"
39132    else
39133
39134
39135  case $ac_ii in
39136  c|c_r) ;;
39137  *)
39138      LIBS="$LIBS -l$ac_ii"
39139   ;;
39140  esac
39141
39142
39143    fi
39144   ;;
39145  esac
39146
39147
39148    ;;
39149    -L*)
39150      ac_ii=`echo $ac_i|cut -c 3-`
39151
39152  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39153
39154  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39155    ai_p=$ac_ii
39156  else
39157
39158    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39159
39160    ep_realdir=`(cd "$ep_dir" && pwd)`
39161    ai_p="$ep_realdir"/`basename "$ac_ii"`
39162  fi
39163
39164
39165      if test "$ext_shared" = "yes"; then
39166        LDFLAGS="-L$ai_p $LDFLAGS"
39167        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39168      else
39169
39170
39171
39172  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39173
39174  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39175  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39176    eval "LIBPATH$unique=set"
39177
39178    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39179    LDFLAGS="$LDFLAGS -L$ai_p"
39180    PHP_RPATHS="$PHP_RPATHS $ai_p"
39181
39182  fi
39183
39184
39185      fi
39186
39187  fi
39188
39189    ;;
39190    esac
39191  done
39192
39193  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromXpm in -lgd" >&5
39194printf %s "checking for gdImageCreateFromXpm in -lgd... " >&6; }
39195if test ${ac_cv_lib_gd_gdImageCreateFromXpm+y}
39196then :
39197  printf %s "(cached) " >&6
39198else $as_nop
39199  ac_check_lib_save_LIBS=$LIBS
39200LIBS="-lgd  $LIBS"
39201cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39202/* end confdefs.h.  */
39203
39204/* Override any GCC internal prototype to avoid an error.
39205   Use char because int might match the return type of a GCC
39206   builtin and then its argument prototype would still apply.  */
39207char gdImageCreateFromXpm ();
39208int
39209main (void)
39210{
39211return gdImageCreateFromXpm ();
39212  ;
39213  return 0;
39214}
39215_ACEOF
39216if ac_fn_c_try_link "$LINENO"
39217then :
39218  ac_cv_lib_gd_gdImageCreateFromXpm=yes
39219else $as_nop
39220  ac_cv_lib_gd_gdImageCreateFromXpm=no
39221fi
39222rm -f core conftest.err conftest.$ac_objext conftest.beam \
39223    conftest$ac_exeext conftest.$ac_ext
39224LIBS=$ac_check_lib_save_LIBS
39225fi
39226{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromXpm" >&5
39227printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromXpm" >&6; }
39228if test "x$ac_cv_lib_gd_gdImageCreateFromXpm" = xyes
39229then :
39230
39231    LDFLAGS=$save_old_LDFLAGS
39232    ext_shared=$save_ext_shared
39233
39234printf "%s\n" "#define HAVE_GD_XPM 1" >>confdefs.h
39235
39236
39237else $as_nop
39238
39239    LDFLAGS=$save_old_LDFLAGS
39240    ext_shared=$save_ext_shared
39241    unset ac_cv_lib_gd_gdImageCreateFromXpm
39242
39243
39244fi
39245
39246
39247  save_old_LDFLAGS=$LDFLAGS
39248  ac_stuff=" $GD_SHARED_LIBADD "
39249
39250  save_ext_shared=$ext_shared
39251  ext_shared=yes
39252
39253  for ac_i in $ac_stuff; do
39254    case $ac_i in
39255    -pthread)
39256      if test "$ext_shared" = "yes"; then
39257        LDFLAGS="$LDFLAGS -pthread"
39258      else
39259
39260
39261  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39262
39263  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39264  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39265    eval "EXTRA_LDFLAGS$unique=set"
39266    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39267  fi
39268
39269
39270
39271  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39272
39273  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39274  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39275    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39276    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39277  fi
39278
39279      fi
39280    ;;
39281    -l*)
39282      ac_ii=`echo $ac_i|cut -c 3-`
39283
39284
39285  case $ac_ii in
39286  c|c_r) ;;
39287  *)
39288    if test "$ext_shared" = "yes"; then
39289        LDFLAGS="$LDFLAGS -l$ac_ii"
39290    else
39291
39292
39293  case $ac_ii in
39294  c|c_r) ;;
39295  *)
39296      LIBS="$LIBS -l$ac_ii"
39297   ;;
39298  esac
39299
39300
39301    fi
39302   ;;
39303  esac
39304
39305
39306    ;;
39307    -L*)
39308      ac_ii=`echo $ac_i|cut -c 3-`
39309
39310  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39311
39312  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39313    ai_p=$ac_ii
39314  else
39315
39316    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39317
39318    ep_realdir=`(cd "$ep_dir" && pwd)`
39319    ai_p="$ep_realdir"/`basename "$ac_ii"`
39320  fi
39321
39322
39323      if test "$ext_shared" = "yes"; then
39324        LDFLAGS="-L$ai_p $LDFLAGS"
39325        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39326      else
39327
39328
39329
39330  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39331
39332  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39333  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39334    eval "LIBPATH$unique=set"
39335
39336    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39337    LDFLAGS="$LDFLAGS -L$ai_p"
39338    PHP_RPATHS="$PHP_RPATHS $ai_p"
39339
39340  fi
39341
39342
39343      fi
39344
39345  fi
39346
39347    ;;
39348    esac
39349  done
39350
39351  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromBmp in -lgd" >&5
39352printf %s "checking for gdImageCreateFromBmp in -lgd... " >&6; }
39353if test ${ac_cv_lib_gd_gdImageCreateFromBmp+y}
39354then :
39355  printf %s "(cached) " >&6
39356else $as_nop
39357  ac_check_lib_save_LIBS=$LIBS
39358LIBS="-lgd  $LIBS"
39359cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39360/* end confdefs.h.  */
39361
39362/* Override any GCC internal prototype to avoid an error.
39363   Use char because int might match the return type of a GCC
39364   builtin and then its argument prototype would still apply.  */
39365char gdImageCreateFromBmp ();
39366int
39367main (void)
39368{
39369return gdImageCreateFromBmp ();
39370  ;
39371  return 0;
39372}
39373_ACEOF
39374if ac_fn_c_try_link "$LINENO"
39375then :
39376  ac_cv_lib_gd_gdImageCreateFromBmp=yes
39377else $as_nop
39378  ac_cv_lib_gd_gdImageCreateFromBmp=no
39379fi
39380rm -f core conftest.err conftest.$ac_objext conftest.beam \
39381    conftest$ac_exeext conftest.$ac_ext
39382LIBS=$ac_check_lib_save_LIBS
39383fi
39384{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromBmp" >&5
39385printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromBmp" >&6; }
39386if test "x$ac_cv_lib_gd_gdImageCreateFromBmp" = xyes
39387then :
39388
39389    LDFLAGS=$save_old_LDFLAGS
39390    ext_shared=$save_ext_shared
39391
39392printf "%s\n" "#define HAVE_GD_BMP 1" >>confdefs.h
39393
39394
39395else $as_nop
39396
39397    LDFLAGS=$save_old_LDFLAGS
39398    ext_shared=$save_ext_shared
39399    unset ac_cv_lib_gd_gdImageCreateFromBmp
39400
39401
39402fi
39403
39404
39405  save_old_LDFLAGS=$LDFLAGS
39406  ac_stuff=" $GD_SHARED_LIBADD "
39407
39408  save_ext_shared=$ext_shared
39409  ext_shared=yes
39410
39411  for ac_i in $ac_stuff; do
39412    case $ac_i in
39413    -pthread)
39414      if test "$ext_shared" = "yes"; then
39415        LDFLAGS="$LDFLAGS -pthread"
39416      else
39417
39418
39419  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39420
39421  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39422  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39423    eval "EXTRA_LDFLAGS$unique=set"
39424    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39425  fi
39426
39427
39428
39429  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39430
39431  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39432  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39433    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39434    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39435  fi
39436
39437      fi
39438    ;;
39439    -l*)
39440      ac_ii=`echo $ac_i|cut -c 3-`
39441
39442
39443  case $ac_ii in
39444  c|c_r) ;;
39445  *)
39446    if test "$ext_shared" = "yes"; then
39447        LDFLAGS="$LDFLAGS -l$ac_ii"
39448    else
39449
39450
39451  case $ac_ii in
39452  c|c_r) ;;
39453  *)
39454      LIBS="$LIBS -l$ac_ii"
39455   ;;
39456  esac
39457
39458
39459    fi
39460   ;;
39461  esac
39462
39463
39464    ;;
39465    -L*)
39466      ac_ii=`echo $ac_i|cut -c 3-`
39467
39468  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39469
39470  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39471    ai_p=$ac_ii
39472  else
39473
39474    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39475
39476    ep_realdir=`(cd "$ep_dir" && pwd)`
39477    ai_p="$ep_realdir"/`basename "$ac_ii"`
39478  fi
39479
39480
39481      if test "$ext_shared" = "yes"; then
39482        LDFLAGS="-L$ai_p $LDFLAGS"
39483        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39484      else
39485
39486
39487
39488  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39489
39490  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39491  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39492    eval "LIBPATH$unique=set"
39493
39494    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39495    LDFLAGS="$LDFLAGS -L$ai_p"
39496    PHP_RPATHS="$PHP_RPATHS $ai_p"
39497
39498  fi
39499
39500
39501      fi
39502
39503  fi
39504
39505    ;;
39506    esac
39507  done
39508
39509  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreateFromTga in -lgd" >&5
39510printf %s "checking for gdImageCreateFromTga in -lgd... " >&6; }
39511if test ${ac_cv_lib_gd_gdImageCreateFromTga+y}
39512then :
39513  printf %s "(cached) " >&6
39514else $as_nop
39515  ac_check_lib_save_LIBS=$LIBS
39516LIBS="-lgd  $LIBS"
39517cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39518/* end confdefs.h.  */
39519
39520/* Override any GCC internal prototype to avoid an error.
39521   Use char because int might match the return type of a GCC
39522   builtin and then its argument prototype would still apply.  */
39523char gdImageCreateFromTga ();
39524int
39525main (void)
39526{
39527return gdImageCreateFromTga ();
39528  ;
39529  return 0;
39530}
39531_ACEOF
39532if ac_fn_c_try_link "$LINENO"
39533then :
39534  ac_cv_lib_gd_gdImageCreateFromTga=yes
39535else $as_nop
39536  ac_cv_lib_gd_gdImageCreateFromTga=no
39537fi
39538rm -f core conftest.err conftest.$ac_objext conftest.beam \
39539    conftest$ac_exeext conftest.$ac_ext
39540LIBS=$ac_check_lib_save_LIBS
39541fi
39542{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreateFromTga" >&5
39543printf "%s\n" "$ac_cv_lib_gd_gdImageCreateFromTga" >&6; }
39544if test "x$ac_cv_lib_gd_gdImageCreateFromTga" = xyes
39545then :
39546
39547    LDFLAGS=$save_old_LDFLAGS
39548    ext_shared=$save_ext_shared
39549
39550printf "%s\n" "#define HAVE_GD_TGA 1" >>confdefs.h
39551
39552
39553else $as_nop
39554
39555    LDFLAGS=$save_old_LDFLAGS
39556    ext_shared=$save_ext_shared
39557    unset ac_cv_lib_gd_gdImageCreateFromTga
39558
39559
39560fi
39561
39562
39563  save_old_LDFLAGS=$LDFLAGS
39564  ac_stuff=" $GD_SHARED_LIBADD "
39565
39566  save_ext_shared=$ext_shared
39567  ext_shared=yes
39568
39569  for ac_i in $ac_stuff; do
39570    case $ac_i in
39571    -pthread)
39572      if test "$ext_shared" = "yes"; then
39573        LDFLAGS="$LDFLAGS -pthread"
39574      else
39575
39576
39577  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39578
39579  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39580  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39581    eval "EXTRA_LDFLAGS$unique=set"
39582    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39583  fi
39584
39585
39586
39587  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39588
39589  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39590  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39591    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39592    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39593  fi
39594
39595      fi
39596    ;;
39597    -l*)
39598      ac_ii=`echo $ac_i|cut -c 3-`
39599
39600
39601  case $ac_ii in
39602  c|c_r) ;;
39603  *)
39604    if test "$ext_shared" = "yes"; then
39605        LDFLAGS="$LDFLAGS -l$ac_ii"
39606    else
39607
39608
39609  case $ac_ii in
39610  c|c_r) ;;
39611  *)
39612      LIBS="$LIBS -l$ac_ii"
39613   ;;
39614  esac
39615
39616
39617    fi
39618   ;;
39619  esac
39620
39621
39622    ;;
39623    -L*)
39624      ac_ii=`echo $ac_i|cut -c 3-`
39625
39626  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39627
39628  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39629    ai_p=$ac_ii
39630  else
39631
39632    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39633
39634    ep_realdir=`(cd "$ep_dir" && pwd)`
39635    ai_p="$ep_realdir"/`basename "$ac_ii"`
39636  fi
39637
39638
39639      if test "$ext_shared" = "yes"; then
39640        LDFLAGS="-L$ai_p $LDFLAGS"
39641        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39642      else
39643
39644
39645
39646  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39647
39648  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39649  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39650    eval "LIBPATH$unique=set"
39651
39652    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39653    LDFLAGS="$LDFLAGS -L$ai_p"
39654    PHP_RPATHS="$PHP_RPATHS $ai_p"
39655
39656  fi
39657
39658
39659      fi
39660
39661  fi
39662
39663    ;;
39664    esac
39665  done
39666
39667  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageStringFT in -lgd" >&5
39668printf %s "checking for gdImageStringFT in -lgd... " >&6; }
39669if test ${ac_cv_lib_gd_gdImageStringFT+y}
39670then :
39671  printf %s "(cached) " >&6
39672else $as_nop
39673  ac_check_lib_save_LIBS=$LIBS
39674LIBS="-lgd  $LIBS"
39675cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39676/* end confdefs.h.  */
39677
39678/* Override any GCC internal prototype to avoid an error.
39679   Use char because int might match the return type of a GCC
39680   builtin and then its argument prototype would still apply.  */
39681char gdImageStringFT ();
39682int
39683main (void)
39684{
39685return gdImageStringFT ();
39686  ;
39687  return 0;
39688}
39689_ACEOF
39690if ac_fn_c_try_link "$LINENO"
39691then :
39692  ac_cv_lib_gd_gdImageStringFT=yes
39693else $as_nop
39694  ac_cv_lib_gd_gdImageStringFT=no
39695fi
39696rm -f core conftest.err conftest.$ac_objext conftest.beam \
39697    conftest$ac_exeext conftest.$ac_ext
39698LIBS=$ac_check_lib_save_LIBS
39699fi
39700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageStringFT" >&5
39701printf "%s\n" "$ac_cv_lib_gd_gdImageStringFT" >&6; }
39702if test "x$ac_cv_lib_gd_gdImageStringFT" = xyes
39703then :
39704
39705    LDFLAGS=$save_old_LDFLAGS
39706    ext_shared=$save_ext_shared
39707
39708printf "%s\n" "#define HAVE_GD_FREETYPE 1" >>confdefs.h
39709
39710
39711else $as_nop
39712
39713    LDFLAGS=$save_old_LDFLAGS
39714    ext_shared=$save_ext_shared
39715    unset ac_cv_lib_gd_gdImageStringFT
39716
39717
39718fi
39719
39720
39721  save_old_LDFLAGS=$LDFLAGS
39722  ac_stuff=" $GD_SHARED_LIBADD "
39723
39724  save_ext_shared=$ext_shared
39725  ext_shared=yes
39726
39727  for ac_i in $ac_stuff; do
39728    case $ac_i in
39729    -pthread)
39730      if test "$ext_shared" = "yes"; then
39731        LDFLAGS="$LDFLAGS -pthread"
39732      else
39733
39734
39735  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39736
39737  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39738  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39739    eval "EXTRA_LDFLAGS$unique=set"
39740    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39741  fi
39742
39743
39744
39745  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39746
39747  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39748  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39749    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39750    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39751  fi
39752
39753      fi
39754    ;;
39755    -l*)
39756      ac_ii=`echo $ac_i|cut -c 3-`
39757
39758
39759  case $ac_ii in
39760  c|c_r) ;;
39761  *)
39762    if test "$ext_shared" = "yes"; then
39763        LDFLAGS="$LDFLAGS -l$ac_ii"
39764    else
39765
39766
39767  case $ac_ii in
39768  c|c_r) ;;
39769  *)
39770      LIBS="$LIBS -l$ac_ii"
39771   ;;
39772  esac
39773
39774
39775    fi
39776   ;;
39777  esac
39778
39779
39780    ;;
39781    -L*)
39782      ac_ii=`echo $ac_i|cut -c 3-`
39783
39784  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39785
39786  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39787    ai_p=$ac_ii
39788  else
39789
39790    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39791
39792    ep_realdir=`(cd "$ep_dir" && pwd)`
39793    ai_p="$ep_realdir"/`basename "$ac_ii"`
39794  fi
39795
39796
39797      if test "$ext_shared" = "yes"; then
39798        LDFLAGS="-L$ai_p $LDFLAGS"
39799        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39800      else
39801
39802
39803
39804  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39805
39806  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39807  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39808    eval "LIBPATH$unique=set"
39809
39810    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39811    LDFLAGS="$LDFLAGS -L$ai_p"
39812    PHP_RPATHS="$PHP_RPATHS $ai_p"
39813
39814  fi
39815
39816
39817      fi
39818
39819  fi
39820
39821    ;;
39822    esac
39823  done
39824
39825  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdVersionString in -lgd" >&5
39826printf %s "checking for gdVersionString in -lgd... " >&6; }
39827if test ${ac_cv_lib_gd_gdVersionString+y}
39828then :
39829  printf %s "(cached) " >&6
39830else $as_nop
39831  ac_check_lib_save_LIBS=$LIBS
39832LIBS="-lgd  $LIBS"
39833cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39834/* end confdefs.h.  */
39835
39836/* Override any GCC internal prototype to avoid an error.
39837   Use char because int might match the return type of a GCC
39838   builtin and then its argument prototype would still apply.  */
39839char gdVersionString ();
39840int
39841main (void)
39842{
39843return gdVersionString ();
39844  ;
39845  return 0;
39846}
39847_ACEOF
39848if ac_fn_c_try_link "$LINENO"
39849then :
39850  ac_cv_lib_gd_gdVersionString=yes
39851else $as_nop
39852  ac_cv_lib_gd_gdVersionString=no
39853fi
39854rm -f core conftest.err conftest.$ac_objext conftest.beam \
39855    conftest$ac_exeext conftest.$ac_ext
39856LIBS=$ac_check_lib_save_LIBS
39857fi
39858{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdVersionString" >&5
39859printf "%s\n" "$ac_cv_lib_gd_gdVersionString" >&6; }
39860if test "x$ac_cv_lib_gd_gdVersionString" = xyes
39861then :
39862
39863    LDFLAGS=$save_old_LDFLAGS
39864    ext_shared=$save_ext_shared
39865
39866printf "%s\n" "#define HAVE_GD_LIBVERSION 1" >>confdefs.h
39867
39868
39869else $as_nop
39870
39871    LDFLAGS=$save_old_LDFLAGS
39872    ext_shared=$save_ext_shared
39873    unset ac_cv_lib_gd_gdVersionString
39874
39875
39876fi
39877
39878
39879  save_old_LDFLAGS=$LDFLAGS
39880  ac_stuff=" $GD_SHARED_LIBADD "
39881
39882  save_ext_shared=$ext_shared
39883  ext_shared=yes
39884
39885  for ac_i in $ac_stuff; do
39886    case $ac_i in
39887    -pthread)
39888      if test "$ext_shared" = "yes"; then
39889        LDFLAGS="$LDFLAGS -pthread"
39890      else
39891
39892
39893  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39894
39895  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
39896  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39897    eval "EXTRA_LDFLAGS$unique=set"
39898    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
39899  fi
39900
39901
39902
39903  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
39904
39905  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
39906  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39907    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
39908    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
39909  fi
39910
39911      fi
39912    ;;
39913    -l*)
39914      ac_ii=`echo $ac_i|cut -c 3-`
39915
39916
39917  case $ac_ii in
39918  c|c_r) ;;
39919  *)
39920    if test "$ext_shared" = "yes"; then
39921        LDFLAGS="$LDFLAGS -l$ac_ii"
39922    else
39923
39924
39925  case $ac_ii in
39926  c|c_r) ;;
39927  *)
39928      LIBS="$LIBS -l$ac_ii"
39929   ;;
39930  esac
39931
39932
39933    fi
39934   ;;
39935  esac
39936
39937
39938    ;;
39939    -L*)
39940      ac_ii=`echo $ac_i|cut -c 3-`
39941
39942  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
39943
39944  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
39945    ai_p=$ac_ii
39946  else
39947
39948    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
39949
39950    ep_realdir=`(cd "$ep_dir" && pwd)`
39951    ai_p="$ep_realdir"/`basename "$ac_ii"`
39952  fi
39953
39954
39955      if test "$ext_shared" = "yes"; then
39956        LDFLAGS="-L$ai_p $LDFLAGS"
39957        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
39958      else
39959
39960
39961
39962  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
39963
39964  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
39965  if test -n "$unique" && test "`eval $cmd`" = "" ; then
39966    eval "LIBPATH$unique=set"
39967
39968    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
39969    LDFLAGS="$LDFLAGS -L$ai_p"
39970    PHP_RPATHS="$PHP_RPATHS $ai_p"
39971
39972  fi
39973
39974
39975      fi
39976
39977  fi
39978
39979    ;;
39980    esac
39981  done
39982
39983  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageGetInterpolationMethod in -lgd" >&5
39984printf %s "checking for gdImageGetInterpolationMethod in -lgd... " >&6; }
39985if test ${ac_cv_lib_gd_gdImageGetInterpolationMethod+y}
39986then :
39987  printf %s "(cached) " >&6
39988else $as_nop
39989  ac_check_lib_save_LIBS=$LIBS
39990LIBS="-lgd  $LIBS"
39991cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39992/* end confdefs.h.  */
39993
39994/* Override any GCC internal prototype to avoid an error.
39995   Use char because int might match the return type of a GCC
39996   builtin and then its argument prototype would still apply.  */
39997char gdImageGetInterpolationMethod ();
39998int
39999main (void)
40000{
40001return gdImageGetInterpolationMethod ();
40002  ;
40003  return 0;
40004}
40005_ACEOF
40006if ac_fn_c_try_link "$LINENO"
40007then :
40008  ac_cv_lib_gd_gdImageGetInterpolationMethod=yes
40009else $as_nop
40010  ac_cv_lib_gd_gdImageGetInterpolationMethod=no
40011fi
40012rm -f core conftest.err conftest.$ac_objext conftest.beam \
40013    conftest$ac_exeext conftest.$ac_ext
40014LIBS=$ac_check_lib_save_LIBS
40015fi
40016{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageGetInterpolationMethod" >&5
40017printf "%s\n" "$ac_cv_lib_gd_gdImageGetInterpolationMethod" >&6; }
40018if test "x$ac_cv_lib_gd_gdImageGetInterpolationMethod" = xyes
40019then :
40020
40021    LDFLAGS=$save_old_LDFLAGS
40022    ext_shared=$save_ext_shared
40023
40024printf "%s\n" "#define HAVE_GD_GET_INTERPOLATION 1" >>confdefs.h
40025
40026
40027else $as_nop
40028
40029    LDFLAGS=$save_old_LDFLAGS
40030    ext_shared=$save_ext_shared
40031    unset ac_cv_lib_gd_gdImageGetInterpolationMethod
40032
40033
40034fi
40035
40036
40037
40038
40039  ext_builddir=ext/gd
40040  ext_srcdir=$abs_srcdir/ext/gd
40041  ext_dir=ext/gd
40042
40043  ac_extra=
40044
40045  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
40046    PHP_GD_SHARED=no
40047
40048
40049  case $ext_dir in
40050  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40051  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40052  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40053  esac
40054
40055
40056
40057  b_c_pre=$php_c_pre
40058  b_cxx_pre=$php_cxx_pre
40059  b_c_meta=$php_c_meta
40060  b_cxx_meta=$php_cxx_meta
40061  b_c_post=$php_c_post
40062  b_cxx_post=$php_cxx_post
40063  b_lo=$php_lo
40064
40065
40066  old_IFS=$IFS
40067  for ac_src in gd.c $extra_sources; do
40068
40069      IFS=.
40070      set $ac_src
40071      ac_obj=$1
40072      IFS=$old_IFS
40073
40074      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40075
40076      case $ac_src in
40077        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40078        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40079        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40080        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40081      esac
40082
40083      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40084
40085    cat >>Makefile.objects<<EOF
40086-include $ac_bdir$ac_obj.dep
40087$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40088	$ac_comp
40089EOF
40090  done
40091
40092
40093    EXT_STATIC="$EXT_STATIC gd;$ext_dir"
40094    if test "$ext_shared" != "nocli"; then
40095      EXT_CLI_STATIC="$EXT_CLI_STATIC gd;$ext_dir"
40096    fi
40097  else
40098    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
40099      PHP_GD_SHARED=yes
40100
40101  case $ext_dir in
40102  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40103  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40104  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40105  esac
40106
40107
40108
40109  b_c_pre=$shared_c_pre
40110  b_cxx_pre=$shared_cxx_pre
40111  b_c_meta=$shared_c_meta
40112  b_cxx_meta=$shared_cxx_meta
40113  b_c_post=$shared_c_post
40114  b_cxx_post=$shared_cxx_post
40115  b_lo=$shared_lo
40116
40117
40118  old_IFS=$IFS
40119  for ac_src in gd.c $extra_sources; do
40120
40121      IFS=.
40122      set $ac_src
40123      ac_obj=$1
40124      IFS=$old_IFS
40125
40126      shared_objects_gd="$shared_objects_gd $ac_bdir$ac_obj.lo"
40127
40128      case $ac_src in
40129        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40130        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40131        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40132        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40133      esac
40134
40135      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40136
40137    cat >>Makefile.objects<<EOF
40138-include $ac_bdir$ac_obj.dep
40139$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40140	$ac_comp
40141EOF
40142  done
40143
40144
40145  install_modules="install-modules"
40146  suffix=la
40147
40148  case $host_alias in
40149    *aix*)
40150      additional_flags="-Wl,-G"
40151      ;;
40152  esac
40153
40154  if test "x" = "xyes"; then
40155    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/gd.$suffix"
40156  else
40157    PHP_MODULES="$PHP_MODULES \$(phplibdir)/gd.$suffix"
40158  fi
40159
40160  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_gd"
40161
40162  cat >>Makefile.objects<<EOF
40163\$(phplibdir)/gd.$suffix: $ext_builddir/gd.$suffix
40164	\$(LIBTOOL) --mode=install cp $ext_builddir/gd.$suffix \$(phplibdir)
40165
40166$ext_builddir/gd.$suffix: \$(shared_objects_gd) \$(GD_SHARED_DEPENDENCIES)
40167	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_gd) \$(GD_SHARED_LIBADD)
40168
40169EOF
40170
40171
40172printf "%s\n" "#define COMPILE_DL_GD 1" >>confdefs.h
40173
40174    fi
40175  fi
40176
40177  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
40178    PHP_GD_SHARED=no
40179    case "$PHP_SAPI" in
40180      cgi|embed|phpdbg)
40181
40182
40183  case $ext_dir in
40184  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40185  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40186  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40187  esac
40188
40189
40190
40191  b_c_pre=$php_c_pre
40192  b_cxx_pre=$php_cxx_pre
40193  b_c_meta=$php_c_meta
40194  b_cxx_meta=$php_cxx_meta
40195  b_c_post=$php_c_post
40196  b_cxx_post=$php_cxx_post
40197  b_lo=$php_lo
40198
40199
40200  old_IFS=$IFS
40201  for ac_src in gd.c $extra_sources; do
40202
40203      IFS=.
40204      set $ac_src
40205      ac_obj=$1
40206      IFS=$old_IFS
40207
40208      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40209
40210      case $ac_src in
40211        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40212        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40213        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40214        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40215      esac
40216
40217      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40218
40219    cat >>Makefile.objects<<EOF
40220-include $ac_bdir$ac_obj.dep
40221$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40222	$ac_comp
40223EOF
40224  done
40225
40226
40227        EXT_STATIC="$EXT_STATIC gd;$ext_dir"
40228        ;;
40229      *)
40230
40231
40232  case $ext_dir in
40233  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40234  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40235  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40236  esac
40237
40238
40239
40240  b_c_pre=$php_c_pre
40241  b_cxx_pre=$php_cxx_pre
40242  b_c_meta=$php_c_meta
40243  b_cxx_meta=$php_cxx_meta
40244  b_c_post=$php_c_post
40245  b_cxx_post=$php_cxx_post
40246  b_lo=$php_lo
40247
40248
40249  old_IFS=$IFS
40250  for ac_src in gd.c $extra_sources; do
40251
40252      IFS=.
40253      set $ac_src
40254      ac_obj=$1
40255      IFS=$old_IFS
40256
40257      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40258
40259      case $ac_src in
40260        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40261        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40262        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40263        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40264      esac
40265
40266      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40267
40268    cat >>Makefile.objects<<EOF
40269-include $ac_bdir$ac_obj.dep
40270$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40271	$ac_comp
40272EOF
40273  done
40274
40275
40276        ;;
40277    esac
40278    EXT_CLI_STATIC="$EXT_CLI_STATIC gd;$ext_dir"
40279  fi
40280
40281
40282    BUILD_DIR="$BUILD_DIR $ext_builddir"
40283
40284
40285
40286  if test "$ext_builddir" = "."; then
40287    PHP_PECL_EXTENSION=gd
40288
40289  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
40290
40291  fi
40292
40293    GD_HEADER_DIRS="ext/gd/"
40294
40295  save_old_LDFLAGS=$LDFLAGS
40296  ac_stuff=" $GD_SHARED_LIBADD "
40297
40298  save_ext_shared=$ext_shared
40299  ext_shared=yes
40300
40301  for ac_i in $ac_stuff; do
40302    case $ac_i in
40303    -pthread)
40304      if test "$ext_shared" = "yes"; then
40305        LDFLAGS="$LDFLAGS -pthread"
40306      else
40307
40308
40309  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
40310
40311  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
40312  if test -n "$unique" && test "`eval $cmd`" = "" ; then
40313    eval "EXTRA_LDFLAGS$unique=set"
40314    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
40315  fi
40316
40317
40318
40319  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
40320
40321  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
40322  if test -n "$unique" && test "`eval $cmd`" = "" ; then
40323    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
40324    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
40325  fi
40326
40327      fi
40328    ;;
40329    -l*)
40330      ac_ii=`echo $ac_i|cut -c 3-`
40331
40332
40333  case $ac_ii in
40334  c|c_r) ;;
40335  *)
40336    if test "$ext_shared" = "yes"; then
40337        LDFLAGS="$LDFLAGS -l$ac_ii"
40338    else
40339
40340
40341  case $ac_ii in
40342  c|c_r) ;;
40343  *)
40344      LIBS="$LIBS -l$ac_ii"
40345   ;;
40346  esac
40347
40348
40349    fi
40350   ;;
40351  esac
40352
40353
40354    ;;
40355    -L*)
40356      ac_ii=`echo $ac_i|cut -c 3-`
40357
40358  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
40359
40360  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
40361    ai_p=$ac_ii
40362  else
40363
40364    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
40365
40366    ep_realdir=`(cd "$ep_dir" && pwd)`
40367    ai_p="$ep_realdir"/`basename "$ac_ii"`
40368  fi
40369
40370
40371      if test "$ext_shared" = "yes"; then
40372        LDFLAGS="-L$ai_p $LDFLAGS"
40373        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
40374      else
40375
40376
40377
40378  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
40379
40380  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
40381  if test -n "$unique" && test "`eval $cmd`" = "" ; then
40382    eval "LIBPATH$unique=set"
40383
40384    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
40385    LDFLAGS="$LDFLAGS -L$ai_p"
40386    PHP_RPATHS="$PHP_RPATHS $ai_p"
40387
40388  fi
40389
40390
40391      fi
40392
40393  fi
40394
40395    ;;
40396    esac
40397  done
40398
40399  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gdImageCreate in -lgd" >&5
40400printf %s "checking for gdImageCreate in -lgd... " >&6; }
40401if test ${ac_cv_lib_gd_gdImageCreate+y}
40402then :
40403  printf %s "(cached) " >&6
40404else $as_nop
40405  ac_check_lib_save_LIBS=$LIBS
40406LIBS="-lgd  $LIBS"
40407cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40408/* end confdefs.h.  */
40409
40410/* Override any GCC internal prototype to avoid an error.
40411   Use char because int might match the return type of a GCC
40412   builtin and then its argument prototype would still apply.  */
40413char gdImageCreate ();
40414int
40415main (void)
40416{
40417return gdImageCreate ();
40418  ;
40419  return 0;
40420}
40421_ACEOF
40422if ac_fn_c_try_link "$LINENO"
40423then :
40424  ac_cv_lib_gd_gdImageCreate=yes
40425else $as_nop
40426  ac_cv_lib_gd_gdImageCreate=no
40427fi
40428rm -f core conftest.err conftest.$ac_objext conftest.beam \
40429    conftest$ac_exeext conftest.$ac_ext
40430LIBS=$ac_check_lib_save_LIBS
40431fi
40432{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gd_gdImageCreate" >&5
40433printf "%s\n" "$ac_cv_lib_gd_gdImageCreate" >&6; }
40434if test "x$ac_cv_lib_gd_gdImageCreate" = xyes
40435then :
40436
40437    LDFLAGS=$save_old_LDFLAGS
40438    ext_shared=$save_ext_shared
40439
40440
40441else $as_nop
40442
40443    LDFLAGS=$save_old_LDFLAGS
40444    ext_shared=$save_ext_shared
40445    unset ac_cv_lib_gd_gdImageCreate
40446
40447      as_fn_error $? "GD build test failed. Please check the config.log for details." "$LINENO" 5
40448
40449
40450fi
40451
40452  fi
40453
40454
40455
40456    for header_file in $GD_HEADER_DIRS; do
40457
40458
40459  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
40460
40461  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
40462  if test -n "$unique" && test "`eval $cmd`" = "" ; then
40463    eval "INSTALLHEADERS$unique=set"
40464
40465        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
40466
40467  fi
40468
40469    done
40470
40471
40472
40473  PHP_VAR_SUBST="$PHP_VAR_SUBST GD_CFLAGS"
40474
40475
40476  PHP_VAR_SUBST="$PHP_VAR_SUBST GDLIB_CFLAGS"
40477
40478
40479  PHP_VAR_SUBST="$PHP_VAR_SUBST GDLIB_LIBS"
40480
40481
40482  PHP_VAR_SUBST="$PHP_VAR_SUBST GD_SHARED_LIBADD"
40483
40484fi
40485
40486
40487
40488
40489
40490php_with_gettext=no
40491
40492{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext support" >&5
40493printf %s "checking for GNU gettext support... " >&6; }
40494
40495# Check whether --with-gettext was given.
40496if test ${with_gettext+y}
40497then :
40498  withval=$with_gettext; PHP_GETTEXT=$withval
40499else $as_nop
40500
40501  PHP_GETTEXT=no
40502  test "$PHP_ENABLE_ALL" && PHP_GETTEXT=$PHP_ENABLE_ALL
40503
40504fi
40505
40506
40507
40508ext_output="yes, shared"
40509ext_shared=yes
40510case $PHP_GETTEXT in
40511shared,*)
40512  PHP_GETTEXT=`echo "$PHP_GETTEXT"|$SED 's/^shared,//'`
40513  ;;
40514shared)
40515  PHP_GETTEXT=yes
40516  ;;
40517no)
40518  ext_output=no
40519  ext_shared=no
40520  ;;
40521*)
40522  ext_output=yes
40523  ext_shared=no
40524  ;;
40525esac
40526
40527
40528
40529{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
40530printf "%s\n" "$ext_output" >&6; }
40531
40532
40533
40534
40535if test "$PHP_GETTEXT" != "no"; then
40536  for i in $PHP_GETTEXT /usr/local /usr; do
40537    test -r $i/include/libintl.h && GETTEXT_DIR=$i && break
40538  done
40539
40540  if test -z "$GETTEXT_DIR"; then
40541    as_fn_error $? "Cannot locate header file libintl.h" "$LINENO" 5
40542  fi
40543
40544  GETTEXT_LIBDIR=$GETTEXT_DIR/$PHP_LIBDIR
40545  GETTEXT_INCDIR=$GETTEXT_DIR/include
40546
40547  O_LDFLAGS=$LDFLAGS
40548  LDFLAGS="$LDFLAGS -L$GETTEXT_LIBDIR"
40549  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bindtextdomain in -lintl" >&5
40550printf %s "checking for bindtextdomain in -lintl... " >&6; }
40551if test ${ac_cv_lib_intl_bindtextdomain+y}
40552then :
40553  printf %s "(cached) " >&6
40554else $as_nop
40555  ac_check_lib_save_LIBS=$LIBS
40556LIBS="-lintl  $LIBS"
40557cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40558/* end confdefs.h.  */
40559
40560/* Override any GCC internal prototype to avoid an error.
40561   Use char because int might match the return type of a GCC
40562   builtin and then its argument prototype would still apply.  */
40563char bindtextdomain ();
40564int
40565main (void)
40566{
40567return bindtextdomain ();
40568  ;
40569  return 0;
40570}
40571_ACEOF
40572if ac_fn_c_try_link "$LINENO"
40573then :
40574  ac_cv_lib_intl_bindtextdomain=yes
40575else $as_nop
40576  ac_cv_lib_intl_bindtextdomain=no
40577fi
40578rm -f core conftest.err conftest.$ac_objext conftest.beam \
40579    conftest$ac_exeext conftest.$ac_ext
40580LIBS=$ac_check_lib_save_LIBS
40581fi
40582{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_bindtextdomain" >&5
40583printf "%s\n" "$ac_cv_lib_intl_bindtextdomain" >&6; }
40584if test "x$ac_cv_lib_intl_bindtextdomain" = xyes
40585then :
40586
40587	GETTEXT_LIBS=intl
40588	GETTEXT_CHECK_IN_LIB=intl
40589
40590else $as_nop
40591  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bindtextdomain in -lc" >&5
40592printf %s "checking for bindtextdomain in -lc... " >&6; }
40593if test ${ac_cv_lib_c_bindtextdomain+y}
40594then :
40595  printf %s "(cached) " >&6
40596else $as_nop
40597  ac_check_lib_save_LIBS=$LIBS
40598LIBS="-lc  $LIBS"
40599cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40600/* end confdefs.h.  */
40601
40602/* Override any GCC internal prototype to avoid an error.
40603   Use char because int might match the return type of a GCC
40604   builtin and then its argument prototype would still apply.  */
40605char bindtextdomain ();
40606int
40607main (void)
40608{
40609return bindtextdomain ();
40610  ;
40611  return 0;
40612}
40613_ACEOF
40614if ac_fn_c_try_link "$LINENO"
40615then :
40616  ac_cv_lib_c_bindtextdomain=yes
40617else $as_nop
40618  ac_cv_lib_c_bindtextdomain=no
40619fi
40620rm -f core conftest.err conftest.$ac_objext conftest.beam \
40621    conftest$ac_exeext conftest.$ac_ext
40622LIBS=$ac_check_lib_save_LIBS
40623fi
40624{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_bindtextdomain" >&5
40625printf "%s\n" "$ac_cv_lib_c_bindtextdomain" >&6; }
40626if test "x$ac_cv_lib_c_bindtextdomain" = xyes
40627then :
40628
40629		GETTEXT_LIBS=
40630		GETTEXT_CHECK_IN_LIB=c
40631
40632else $as_nop
40633
40634		as_fn_error $? "Unable to find required gettext library" "$LINENO" 5
40635
40636fi
40637
40638
40639fi
40640
40641
40642
40643printf "%s\n" "#define HAVE_LIBINTL 1" >>confdefs.h
40644
40645
40646  ext_builddir=ext/gettext
40647  ext_srcdir=$abs_srcdir/ext/gettext
40648  ext_dir=ext/gettext
40649
40650  ac_extra=
40651
40652  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
40653    PHP_GETTEXT_SHARED=no
40654
40655
40656  case $ext_dir in
40657  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40658  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40659  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40660  esac
40661
40662
40663
40664  b_c_pre=$php_c_pre
40665  b_cxx_pre=$php_cxx_pre
40666  b_c_meta=$php_c_meta
40667  b_cxx_meta=$php_cxx_meta
40668  b_c_post=$php_c_post
40669  b_cxx_post=$php_cxx_post
40670  b_lo=$php_lo
40671
40672
40673  old_IFS=$IFS
40674  for ac_src in gettext.c; do
40675
40676      IFS=.
40677      set $ac_src
40678      ac_obj=$1
40679      IFS=$old_IFS
40680
40681      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40682
40683      case $ac_src in
40684        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40685        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40686        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40687        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40688      esac
40689
40690      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40691
40692    cat >>Makefile.objects<<EOF
40693-include $ac_bdir$ac_obj.dep
40694$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40695	$ac_comp
40696EOF
40697  done
40698
40699
40700    EXT_STATIC="$EXT_STATIC gettext;$ext_dir"
40701    if test "$ext_shared" != "nocli"; then
40702      EXT_CLI_STATIC="$EXT_CLI_STATIC gettext;$ext_dir"
40703    fi
40704  else
40705    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
40706      PHP_GETTEXT_SHARED=yes
40707
40708  case $ext_dir in
40709  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40710  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40711  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40712  esac
40713
40714
40715
40716  b_c_pre=$shared_c_pre
40717  b_cxx_pre=$shared_cxx_pre
40718  b_c_meta=$shared_c_meta
40719  b_cxx_meta=$shared_cxx_meta
40720  b_c_post=$shared_c_post
40721  b_cxx_post=$shared_cxx_post
40722  b_lo=$shared_lo
40723
40724
40725  old_IFS=$IFS
40726  for ac_src in gettext.c; do
40727
40728      IFS=.
40729      set $ac_src
40730      ac_obj=$1
40731      IFS=$old_IFS
40732
40733      shared_objects_gettext="$shared_objects_gettext $ac_bdir$ac_obj.lo"
40734
40735      case $ac_src in
40736        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40737        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40738        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40739        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40740      esac
40741
40742      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40743
40744    cat >>Makefile.objects<<EOF
40745-include $ac_bdir$ac_obj.dep
40746$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40747	$ac_comp
40748EOF
40749  done
40750
40751
40752  install_modules="install-modules"
40753  suffix=la
40754
40755  case $host_alias in
40756    *aix*)
40757      additional_flags="-Wl,-G"
40758      ;;
40759  esac
40760
40761  if test "x" = "xyes"; then
40762    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/gettext.$suffix"
40763  else
40764    PHP_MODULES="$PHP_MODULES \$(phplibdir)/gettext.$suffix"
40765  fi
40766
40767  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_gettext"
40768
40769  cat >>Makefile.objects<<EOF
40770\$(phplibdir)/gettext.$suffix: $ext_builddir/gettext.$suffix
40771	\$(LIBTOOL) --mode=install cp $ext_builddir/gettext.$suffix \$(phplibdir)
40772
40773$ext_builddir/gettext.$suffix: \$(shared_objects_gettext) \$(GETTEXT_SHARED_DEPENDENCIES)
40774	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_gettext) \$(GETTEXT_SHARED_LIBADD)
40775
40776EOF
40777
40778
40779printf "%s\n" "#define COMPILE_DL_GETTEXT 1" >>confdefs.h
40780
40781    fi
40782  fi
40783
40784  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
40785    PHP_GETTEXT_SHARED=no
40786    case "$PHP_SAPI" in
40787      cgi|embed|phpdbg)
40788
40789
40790  case $ext_dir in
40791  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40792  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40793  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40794  esac
40795
40796
40797
40798  b_c_pre=$php_c_pre
40799  b_cxx_pre=$php_cxx_pre
40800  b_c_meta=$php_c_meta
40801  b_cxx_meta=$php_cxx_meta
40802  b_c_post=$php_c_post
40803  b_cxx_post=$php_cxx_post
40804  b_lo=$php_lo
40805
40806
40807  old_IFS=$IFS
40808  for ac_src in gettext.c; do
40809
40810      IFS=.
40811      set $ac_src
40812      ac_obj=$1
40813      IFS=$old_IFS
40814
40815      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40816
40817      case $ac_src in
40818        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40819        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40820        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40821        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40822      esac
40823
40824      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40825
40826    cat >>Makefile.objects<<EOF
40827-include $ac_bdir$ac_obj.dep
40828$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40829	$ac_comp
40830EOF
40831  done
40832
40833
40834        EXT_STATIC="$EXT_STATIC gettext;$ext_dir"
40835        ;;
40836      *)
40837
40838
40839  case $ext_dir in
40840  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
40841  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
40842  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
40843  esac
40844
40845
40846
40847  b_c_pre=$php_c_pre
40848  b_cxx_pre=$php_cxx_pre
40849  b_c_meta=$php_c_meta
40850  b_cxx_meta=$php_cxx_meta
40851  b_c_post=$php_c_post
40852  b_cxx_post=$php_cxx_post
40853  b_lo=$php_lo
40854
40855
40856  old_IFS=$IFS
40857  for ac_src in gettext.c; do
40858
40859      IFS=.
40860      set $ac_src
40861      ac_obj=$1
40862      IFS=$old_IFS
40863
40864      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
40865
40866      case $ac_src in
40867        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40868        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40869        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
40870        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
40871      esac
40872
40873      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
40874
40875    cat >>Makefile.objects<<EOF
40876-include $ac_bdir$ac_obj.dep
40877$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
40878	$ac_comp
40879EOF
40880  done
40881
40882
40883        ;;
40884    esac
40885    EXT_CLI_STATIC="$EXT_CLI_STATIC gettext;$ext_dir"
40886  fi
40887
40888
40889    BUILD_DIR="$BUILD_DIR $ext_builddir"
40890
40891
40892
40893  if test "$ext_builddir" = "."; then
40894    PHP_PECL_EXTENSION=gettext
40895
40896  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
40897
40898  fi
40899
40900
40901  PHP_VAR_SUBST="$PHP_VAR_SUBST GETTEXT_SHARED_LIBADD"
40902
40903
40904
40905  if test "$GETTEXT_INCDIR" != "/usr/include"; then
40906
40907  if test -z "$GETTEXT_INCDIR" || echo "$GETTEXT_INCDIR" | grep '^/' >/dev/null ; then
40908    ai_p=$GETTEXT_INCDIR
40909  else
40910
40911    ep_dir=`echo $GETTEXT_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
40912
40913    ep_realdir=`(cd "$ep_dir" && pwd)`
40914    ai_p="$ep_realdir"/`basename "$GETTEXT_INCDIR"`
40915  fi
40916
40917
40918
40919  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
40920
40921  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
40922  if test -n "$unique" && test "`eval $cmd`" = "" ; then
40923    eval "INCLUDEPATH$unique=set"
40924
40925      if test ""; then
40926        INCLUDES="-I$ai_p $INCLUDES"
40927      else
40928        INCLUDES="$INCLUDES -I$ai_p"
40929      fi
40930
40931  fi
40932
40933  fi
40934
40935
40936  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$GETTEXT_CHECK_IN_LIB""_ngettext" | $as_tr_sh`
40937{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
40938printf %s "checking for ngettext in -l$GETTEXT_CHECK_IN_LIB... " >&6; }
40939if eval test \${$as_ac_Lib+y}
40940then :
40941  printf %s "(cached) " >&6
40942else $as_nop
40943  ac_check_lib_save_LIBS=$LIBS
40944LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
40945cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40946/* end confdefs.h.  */
40947
40948/* Override any GCC internal prototype to avoid an error.
40949   Use char because int might match the return type of a GCC
40950   builtin and then its argument prototype would still apply.  */
40951char ngettext ();
40952int
40953main (void)
40954{
40955return ngettext ();
40956  ;
40957  return 0;
40958}
40959_ACEOF
40960if ac_fn_c_try_link "$LINENO"
40961then :
40962  eval "$as_ac_Lib=yes"
40963else $as_nop
40964  eval "$as_ac_Lib=no"
40965fi
40966rm -f core conftest.err conftest.$ac_objext conftest.beam \
40967    conftest$ac_exeext conftest.$ac_ext
40968LIBS=$ac_check_lib_save_LIBS
40969fi
40970eval ac_res=\$$as_ac_Lib
40971	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
40972printf "%s\n" "$ac_res" >&6; }
40973if eval test \"x\$"$as_ac_Lib"\" = x"yes"
40974then :
40975
40976printf "%s\n" "#define HAVE_NGETTEXT 1" >>confdefs.h
40977
40978fi
40979
40980  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$GETTEXT_CHECK_IN_LIB""_dngettext" | $as_tr_sh`
40981{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
40982printf %s "checking for dngettext in -l$GETTEXT_CHECK_IN_LIB... " >&6; }
40983if eval test \${$as_ac_Lib+y}
40984then :
40985  printf %s "(cached) " >&6
40986else $as_nop
40987  ac_check_lib_save_LIBS=$LIBS
40988LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
40989cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40990/* end confdefs.h.  */
40991
40992/* Override any GCC internal prototype to avoid an error.
40993   Use char because int might match the return type of a GCC
40994   builtin and then its argument prototype would still apply.  */
40995char dngettext ();
40996int
40997main (void)
40998{
40999return dngettext ();
41000  ;
41001  return 0;
41002}
41003_ACEOF
41004if ac_fn_c_try_link "$LINENO"
41005then :
41006  eval "$as_ac_Lib=yes"
41007else $as_nop
41008  eval "$as_ac_Lib=no"
41009fi
41010rm -f core conftest.err conftest.$ac_objext conftest.beam \
41011    conftest$ac_exeext conftest.$ac_ext
41012LIBS=$ac_check_lib_save_LIBS
41013fi
41014eval ac_res=\$$as_ac_Lib
41015	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
41016printf "%s\n" "$ac_res" >&6; }
41017if eval test \"x\$"$as_ac_Lib"\" = x"yes"
41018then :
41019
41020printf "%s\n" "#define HAVE_DNGETTEXT 1" >>confdefs.h
41021
41022fi
41023
41024  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$GETTEXT_CHECK_IN_LIB""_dcngettext" | $as_tr_sh`
41025{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dcngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
41026printf %s "checking for dcngettext in -l$GETTEXT_CHECK_IN_LIB... " >&6; }
41027if eval test \${$as_ac_Lib+y}
41028then :
41029  printf %s "(cached) " >&6
41030else $as_nop
41031  ac_check_lib_save_LIBS=$LIBS
41032LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
41033cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41034/* end confdefs.h.  */
41035
41036/* Override any GCC internal prototype to avoid an error.
41037   Use char because int might match the return type of a GCC
41038   builtin and then its argument prototype would still apply.  */
41039char dcngettext ();
41040int
41041main (void)
41042{
41043return dcngettext ();
41044  ;
41045  return 0;
41046}
41047_ACEOF
41048if ac_fn_c_try_link "$LINENO"
41049then :
41050  eval "$as_ac_Lib=yes"
41051else $as_nop
41052  eval "$as_ac_Lib=no"
41053fi
41054rm -f core conftest.err conftest.$ac_objext conftest.beam \
41055    conftest$ac_exeext conftest.$ac_ext
41056LIBS=$ac_check_lib_save_LIBS
41057fi
41058eval ac_res=\$$as_ac_Lib
41059	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
41060printf "%s\n" "$ac_res" >&6; }
41061if eval test \"x\$"$as_ac_Lib"\" = x"yes"
41062then :
41063
41064printf "%s\n" "#define HAVE_DCNGETTEXT 1" >>confdefs.h
41065
41066fi
41067
41068  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$GETTEXT_CHECK_IN_LIB""_bind_textdomain_codeset" | $as_tr_sh`
41069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bind_textdomain_codeset in -l$GETTEXT_CHECK_IN_LIB" >&5
41070printf %s "checking for bind_textdomain_codeset in -l$GETTEXT_CHECK_IN_LIB... " >&6; }
41071if eval test \${$as_ac_Lib+y}
41072then :
41073  printf %s "(cached) " >&6
41074else $as_nop
41075  ac_check_lib_save_LIBS=$LIBS
41076LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
41077cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41078/* end confdefs.h.  */
41079
41080/* Override any GCC internal prototype to avoid an error.
41081   Use char because int might match the return type of a GCC
41082   builtin and then its argument prototype would still apply.  */
41083char bind_textdomain_codeset ();
41084int
41085main (void)
41086{
41087return bind_textdomain_codeset ();
41088  ;
41089  return 0;
41090}
41091_ACEOF
41092if ac_fn_c_try_link "$LINENO"
41093then :
41094  eval "$as_ac_Lib=yes"
41095else $as_nop
41096  eval "$as_ac_Lib=no"
41097fi
41098rm -f core conftest.err conftest.$ac_objext conftest.beam \
41099    conftest$ac_exeext conftest.$ac_ext
41100LIBS=$ac_check_lib_save_LIBS
41101fi
41102eval ac_res=\$$as_ac_Lib
41103	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
41104printf "%s\n" "$ac_res" >&6; }
41105if eval test \"x\$"$as_ac_Lib"\" = x"yes"
41106then :
41107
41108printf "%s\n" "#define HAVE_BIND_TEXTDOMAIN_CODESET 1" >>confdefs.h
41109
41110fi
41111
41112  LDFLAGS=$O_LDFLAGS
41113
41114  if test -n "$GETTEXT_LIBS"; then
41115
41116
41117  if test "$ext_shared" = "yes"; then
41118    GETTEXT_SHARED_LIBADD="-l$GETTEXT_LIBS $GETTEXT_SHARED_LIBADD"
41119    if test -n "$GETTEXT_LIBDIR"; then
41120
41121  if test "$GETTEXT_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$GETTEXT_LIBDIR" != "/usr/lib"; then
41122
41123  if test -z "$GETTEXT_LIBDIR" || echo "$GETTEXT_LIBDIR" | grep '^/' >/dev/null ; then
41124    ai_p=$GETTEXT_LIBDIR
41125  else
41126
41127    ep_dir=`echo $GETTEXT_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
41128
41129    ep_realdir=`(cd "$ep_dir" && pwd)`
41130    ai_p="$ep_realdir"/`basename "$GETTEXT_LIBDIR"`
41131  fi
41132
41133
41134      if test "$ext_shared" = "yes"; then
41135        GETTEXT_SHARED_LIBADD="-L$ai_p $GETTEXT_SHARED_LIBADD"
41136        test -n "$ld_runpath_switch" && GETTEXT_SHARED_LIBADD="$ld_runpath_switch$ai_p $GETTEXT_SHARED_LIBADD"
41137      else
41138
41139
41140
41141  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41142
41143  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41144  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41145    eval "LIBPATH$unique=set"
41146
41147    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41148    LDFLAGS="$LDFLAGS -L$ai_p"
41149    PHP_RPATHS="$PHP_RPATHS $ai_p"
41150
41151  fi
41152
41153
41154      fi
41155
41156  fi
41157
41158    fi
41159  else
41160
41161
41162  if test -n "$GETTEXT_LIBDIR"; then
41163
41164  if test "$GETTEXT_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$GETTEXT_LIBDIR" != "/usr/lib"; then
41165
41166  if test -z "$GETTEXT_LIBDIR" || echo "$GETTEXT_LIBDIR" | grep '^/' >/dev/null ; then
41167    ai_p=$GETTEXT_LIBDIR
41168  else
41169
41170    ep_dir=`echo $GETTEXT_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
41171
41172    ep_realdir=`(cd "$ep_dir" && pwd)`
41173    ai_p="$ep_realdir"/`basename "$GETTEXT_LIBDIR"`
41174  fi
41175
41176
41177
41178
41179
41180  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41181
41182  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41183  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41184    eval "LIBPATH$unique=set"
41185
41186    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41187    LDFLAGS="$LDFLAGS -L$ai_p"
41188    PHP_RPATHS="$PHP_RPATHS $ai_p"
41189
41190  fi
41191
41192
41193
41194  fi
41195
41196  fi
41197
41198
41199  case $GETTEXT_LIBS in
41200  c|c_r) ;;
41201  *)
41202      LIBS="-l$GETTEXT_LIBS $LIBS"
41203   ;;
41204  esac
41205
41206
41207
41208
41209  fi
41210
41211
41212  fi
41213fi
41214
41215
41216
41217
41218
41219php_with_gmp=no
41220
41221{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU MP support" >&5
41222printf %s "checking for GNU MP support... " >&6; }
41223
41224# Check whether --with-gmp was given.
41225if test ${with_gmp+y}
41226then :
41227  withval=$with_gmp; PHP_GMP=$withval
41228else $as_nop
41229
41230  PHP_GMP=no
41231  test "$PHP_ENABLE_ALL" && PHP_GMP=$PHP_ENABLE_ALL
41232
41233fi
41234
41235
41236
41237ext_output="yes, shared"
41238ext_shared=yes
41239case $PHP_GMP in
41240shared,*)
41241  PHP_GMP=`echo "$PHP_GMP"|$SED 's/^shared,//'`
41242  ;;
41243shared)
41244  PHP_GMP=yes
41245  ;;
41246no)
41247  ext_output=no
41248  ext_shared=no
41249  ;;
41250*)
41251  ext_output=yes
41252  ext_shared=no
41253  ;;
41254esac
41255
41256
41257
41258{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
41259printf "%s\n" "$ext_output" >&6; }
41260
41261
41262
41263
41264if test "$PHP_GMP" != "no"; then
41265  if test "$PHP_GMP" = "yes"; then
41266
41267  save_old_LDFLAGS=$LDFLAGS
41268  ac_stuff=""
41269
41270  save_ext_shared=$ext_shared
41271  ext_shared=yes
41272
41273  for ac_i in $ac_stuff; do
41274    case $ac_i in
41275    -pthread)
41276      if test "$ext_shared" = "yes"; then
41277        LDFLAGS="$LDFLAGS -pthread"
41278      else
41279
41280
41281  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
41282
41283  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
41284  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41285    eval "EXTRA_LDFLAGS$unique=set"
41286    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
41287  fi
41288
41289
41290
41291  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
41292
41293  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
41294  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41295    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
41296    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
41297  fi
41298
41299      fi
41300    ;;
41301    -l*)
41302      ac_ii=`echo $ac_i|cut -c 3-`
41303
41304
41305  case $ac_ii in
41306  c|c_r) ;;
41307  *)
41308    if test "$ext_shared" = "yes"; then
41309        LDFLAGS="$LDFLAGS -l$ac_ii"
41310    else
41311
41312
41313  case $ac_ii in
41314  c|c_r) ;;
41315  *)
41316      LIBS="$LIBS -l$ac_ii"
41317   ;;
41318  esac
41319
41320
41321    fi
41322   ;;
41323  esac
41324
41325
41326    ;;
41327    -L*)
41328      ac_ii=`echo $ac_i|cut -c 3-`
41329
41330  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
41331
41332  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
41333    ai_p=$ac_ii
41334  else
41335
41336    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
41337
41338    ep_realdir=`(cd "$ep_dir" && pwd)`
41339    ai_p="$ep_realdir"/`basename "$ac_ii"`
41340  fi
41341
41342
41343      if test "$ext_shared" = "yes"; then
41344        LDFLAGS="-L$ai_p $LDFLAGS"
41345        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
41346      else
41347
41348
41349
41350  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41351
41352  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41353  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41354    eval "LIBPATH$unique=set"
41355
41356    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41357    LDFLAGS="$LDFLAGS -L$ai_p"
41358    PHP_RPATHS="$PHP_RPATHS $ai_p"
41359
41360  fi
41361
41362
41363      fi
41364
41365  fi
41366
41367    ;;
41368    esac
41369  done
41370
41371  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gmpz_rootrem in -lgmp" >&5
41372printf %s "checking for __gmpz_rootrem in -lgmp... " >&6; }
41373if test ${ac_cv_lib_gmp___gmpz_rootrem+y}
41374then :
41375  printf %s "(cached) " >&6
41376else $as_nop
41377  ac_check_lib_save_LIBS=$LIBS
41378LIBS="-lgmp  $LIBS"
41379cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41380/* end confdefs.h.  */
41381
41382/* Override any GCC internal prototype to avoid an error.
41383   Use char because int might match the return type of a GCC
41384   builtin and then its argument prototype would still apply.  */
41385char __gmpz_rootrem ();
41386int
41387main (void)
41388{
41389return __gmpz_rootrem ();
41390  ;
41391  return 0;
41392}
41393_ACEOF
41394if ac_fn_c_try_link "$LINENO"
41395then :
41396  ac_cv_lib_gmp___gmpz_rootrem=yes
41397else $as_nop
41398  ac_cv_lib_gmp___gmpz_rootrem=no
41399fi
41400rm -f core conftest.err conftest.$ac_objext conftest.beam \
41401    conftest$ac_exeext conftest.$ac_ext
41402LIBS=$ac_check_lib_save_LIBS
41403fi
41404{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gmp___gmpz_rootrem" >&5
41405printf "%s\n" "$ac_cv_lib_gmp___gmpz_rootrem" >&6; }
41406if test "x$ac_cv_lib_gmp___gmpz_rootrem" = xyes
41407then :
41408
41409    LDFLAGS=$save_old_LDFLAGS
41410    ext_shared=$save_ext_shared
41411
41412
41413else $as_nop
41414
41415    LDFLAGS=$save_old_LDFLAGS
41416    ext_shared=$save_ext_shared
41417    unset ac_cv_lib_gmp___gmpz_rootrem
41418
41419      as_fn_error $? "GNU MP Library version 4.2 or greater required." "$LINENO" 5
41420
41421
41422fi
41423
41424
41425
41426
41427  case gmp in
41428  c|c_r) ;;
41429  *)
41430    if test "$ext_shared" = "yes"; then
41431        GMP_SHARED_LIBADD="-lgmp $GMP_SHARED_LIBADD"
41432    else
41433
41434
41435  case gmp in
41436  c|c_r) ;;
41437  *)
41438      LIBS="-lgmp $LIBS"
41439   ;;
41440  esac
41441
41442
41443    fi
41444   ;;
41445  esac
41446
41447
41448  else
41449    if test ! -f $PHP_GMP/include/gmp.h; then
41450      as_fn_error $? "Unable to locate gmp.h" "$LINENO" 5
41451    fi
41452
41453
41454  save_old_LDFLAGS=$LDFLAGS
41455  ac_stuff="
41456      -L$PHP_GMP/$PHP_LIBDIR
41457    "
41458
41459  save_ext_shared=$ext_shared
41460  ext_shared=yes
41461
41462  for ac_i in $ac_stuff; do
41463    case $ac_i in
41464    -pthread)
41465      if test "$ext_shared" = "yes"; then
41466        LDFLAGS="$LDFLAGS -pthread"
41467      else
41468
41469
41470  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
41471
41472  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
41473  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41474    eval "EXTRA_LDFLAGS$unique=set"
41475    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
41476  fi
41477
41478
41479
41480  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
41481
41482  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
41483  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41484    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
41485    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
41486  fi
41487
41488      fi
41489    ;;
41490    -l*)
41491      ac_ii=`echo $ac_i|cut -c 3-`
41492
41493
41494  case $ac_ii in
41495  c|c_r) ;;
41496  *)
41497    if test "$ext_shared" = "yes"; then
41498        LDFLAGS="$LDFLAGS -l$ac_ii"
41499    else
41500
41501
41502  case $ac_ii in
41503  c|c_r) ;;
41504  *)
41505      LIBS="$LIBS -l$ac_ii"
41506   ;;
41507  esac
41508
41509
41510    fi
41511   ;;
41512  esac
41513
41514
41515    ;;
41516    -L*)
41517      ac_ii=`echo $ac_i|cut -c 3-`
41518
41519  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
41520
41521  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
41522    ai_p=$ac_ii
41523  else
41524
41525    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
41526
41527    ep_realdir=`(cd "$ep_dir" && pwd)`
41528    ai_p="$ep_realdir"/`basename "$ac_ii"`
41529  fi
41530
41531
41532      if test "$ext_shared" = "yes"; then
41533        LDFLAGS="-L$ai_p $LDFLAGS"
41534        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
41535      else
41536
41537
41538
41539  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41540
41541  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41542  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41543    eval "LIBPATH$unique=set"
41544
41545    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41546    LDFLAGS="$LDFLAGS -L$ai_p"
41547    PHP_RPATHS="$PHP_RPATHS $ai_p"
41548
41549  fi
41550
41551
41552      fi
41553
41554  fi
41555
41556    ;;
41557    esac
41558  done
41559
41560  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __gmpz_rootrem in -lgmp" >&5
41561printf %s "checking for __gmpz_rootrem in -lgmp... " >&6; }
41562if test ${ac_cv_lib_gmp___gmpz_rootrem+y}
41563then :
41564  printf %s "(cached) " >&6
41565else $as_nop
41566  ac_check_lib_save_LIBS=$LIBS
41567LIBS="-lgmp  $LIBS"
41568cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41569/* end confdefs.h.  */
41570
41571/* Override any GCC internal prototype to avoid an error.
41572   Use char because int might match the return type of a GCC
41573   builtin and then its argument prototype would still apply.  */
41574char __gmpz_rootrem ();
41575int
41576main (void)
41577{
41578return __gmpz_rootrem ();
41579  ;
41580  return 0;
41581}
41582_ACEOF
41583if ac_fn_c_try_link "$LINENO"
41584then :
41585  ac_cv_lib_gmp___gmpz_rootrem=yes
41586else $as_nop
41587  ac_cv_lib_gmp___gmpz_rootrem=no
41588fi
41589rm -f core conftest.err conftest.$ac_objext conftest.beam \
41590    conftest$ac_exeext conftest.$ac_ext
41591LIBS=$ac_check_lib_save_LIBS
41592fi
41593{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gmp___gmpz_rootrem" >&5
41594printf "%s\n" "$ac_cv_lib_gmp___gmpz_rootrem" >&6; }
41595if test "x$ac_cv_lib_gmp___gmpz_rootrem" = xyes
41596then :
41597
41598    LDFLAGS=$save_old_LDFLAGS
41599    ext_shared=$save_ext_shared
41600
41601
41602else $as_nop
41603
41604    LDFLAGS=$save_old_LDFLAGS
41605    ext_shared=$save_ext_shared
41606    unset ac_cv_lib_gmp___gmpz_rootrem
41607
41608      as_fn_error $? "GNU MP Library version 4.2 or greater required." "$LINENO" 5
41609
41610
41611fi
41612
41613
41614
41615
41616  if test "$ext_shared" = "yes"; then
41617    GMP_SHARED_LIBADD="-lgmp $GMP_SHARED_LIBADD"
41618    if test -n "$PHP_GMP/$PHP_LIBDIR"; then
41619
41620  if test "$PHP_GMP/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PHP_GMP/$PHP_LIBDIR" != "/usr/lib"; then
41621
41622  if test -z "$PHP_GMP/$PHP_LIBDIR" || echo "$PHP_GMP/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
41623    ai_p=$PHP_GMP/$PHP_LIBDIR
41624  else
41625
41626    ep_dir=`echo $PHP_GMP/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
41627
41628    ep_realdir=`(cd "$ep_dir" && pwd)`
41629    ai_p="$ep_realdir"/`basename "$PHP_GMP/$PHP_LIBDIR"`
41630  fi
41631
41632
41633      if test "$ext_shared" = "yes"; then
41634        GMP_SHARED_LIBADD="-L$ai_p $GMP_SHARED_LIBADD"
41635        test -n "$ld_runpath_switch" && GMP_SHARED_LIBADD="$ld_runpath_switch$ai_p $GMP_SHARED_LIBADD"
41636      else
41637
41638
41639
41640  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41641
41642  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41643  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41644    eval "LIBPATH$unique=set"
41645
41646    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41647    LDFLAGS="$LDFLAGS -L$ai_p"
41648    PHP_RPATHS="$PHP_RPATHS $ai_p"
41649
41650  fi
41651
41652
41653      fi
41654
41655  fi
41656
41657    fi
41658  else
41659
41660
41661  if test -n "$PHP_GMP/$PHP_LIBDIR"; then
41662
41663  if test "$PHP_GMP/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PHP_GMP/$PHP_LIBDIR" != "/usr/lib"; then
41664
41665  if test -z "$PHP_GMP/$PHP_LIBDIR" || echo "$PHP_GMP/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
41666    ai_p=$PHP_GMP/$PHP_LIBDIR
41667  else
41668
41669    ep_dir=`echo $PHP_GMP/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
41670
41671    ep_realdir=`(cd "$ep_dir" && pwd)`
41672    ai_p="$ep_realdir"/`basename "$PHP_GMP/$PHP_LIBDIR"`
41673  fi
41674
41675
41676
41677
41678
41679  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41680
41681  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
41682  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41683    eval "LIBPATH$unique=set"
41684
41685    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
41686    LDFLAGS="$LDFLAGS -L$ai_p"
41687    PHP_RPATHS="$PHP_RPATHS $ai_p"
41688
41689  fi
41690
41691
41692
41693  fi
41694
41695  fi
41696
41697
41698  case gmp in
41699  c|c_r) ;;
41700  *)
41701      LIBS="-lgmp $LIBS"
41702   ;;
41703  esac
41704
41705
41706
41707
41708  fi
41709
41710
41711
41712  if test "$PHP_GMP/include" != "/usr/include"; then
41713
41714  if test -z "$PHP_GMP/include" || echo "$PHP_GMP/include" | grep '^/' >/dev/null ; then
41715    ai_p=$PHP_GMP/include
41716  else
41717
41718    ep_dir=`echo $PHP_GMP/include|$SED 's%/*[^/][^/]*/*$%%'`
41719
41720    ep_realdir=`(cd "$ep_dir" && pwd)`
41721    ai_p="$ep_realdir"/`basename "$PHP_GMP/include"`
41722  fi
41723
41724
41725
41726  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
41727
41728  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
41729  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41730    eval "INCLUDEPATH$unique=set"
41731
41732      if test ""; then
41733        INCLUDES="-I$ai_p $INCLUDES"
41734      else
41735        INCLUDES="$INCLUDES -I$ai_p"
41736      fi
41737
41738  fi
41739
41740  fi
41741
41742  fi
41743
41744
41745
41746    for header_file in ext/gmp/php_gmp_int.h; do
41747
41748
41749  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
41750
41751  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
41752  if test -n "$unique" && test "`eval $cmd`" = "" ; then
41753    eval "INSTALLHEADERS$unique=set"
41754
41755        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
41756
41757  fi
41758
41759    done
41760
41761
41762
41763
41764  ext_builddir=ext/gmp
41765  ext_srcdir=$abs_srcdir/ext/gmp
41766  ext_dir=ext/gmp
41767
41768  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
41769
41770  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
41771    PHP_GMP_SHARED=no
41772
41773
41774  case $ext_dir in
41775  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
41776  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
41777  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
41778  esac
41779
41780
41781
41782  b_c_pre=$php_c_pre
41783  b_cxx_pre=$php_cxx_pre
41784  b_c_meta=$php_c_meta
41785  b_cxx_meta=$php_cxx_meta
41786  b_c_post=$php_c_post
41787  b_cxx_post=$php_cxx_post
41788  b_lo=$php_lo
41789
41790
41791  old_IFS=$IFS
41792  for ac_src in gmp.c; do
41793
41794      IFS=.
41795      set $ac_src
41796      ac_obj=$1
41797      IFS=$old_IFS
41798
41799      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
41800
41801      case $ac_src in
41802        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41803        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41804        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41805        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
41806      esac
41807
41808      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
41809
41810    cat >>Makefile.objects<<EOF
41811-include $ac_bdir$ac_obj.dep
41812$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
41813	$ac_comp
41814EOF
41815  done
41816
41817
41818    EXT_STATIC="$EXT_STATIC gmp;$ext_dir"
41819    if test "$ext_shared" != "nocli"; then
41820      EXT_CLI_STATIC="$EXT_CLI_STATIC gmp;$ext_dir"
41821    fi
41822  else
41823    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
41824      PHP_GMP_SHARED=yes
41825
41826  case $ext_dir in
41827  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
41828  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
41829  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
41830  esac
41831
41832
41833
41834  b_c_pre=$shared_c_pre
41835  b_cxx_pre=$shared_cxx_pre
41836  b_c_meta=$shared_c_meta
41837  b_cxx_meta=$shared_cxx_meta
41838  b_c_post=$shared_c_post
41839  b_cxx_post=$shared_cxx_post
41840  b_lo=$shared_lo
41841
41842
41843  old_IFS=$IFS
41844  for ac_src in gmp.c; do
41845
41846      IFS=.
41847      set $ac_src
41848      ac_obj=$1
41849      IFS=$old_IFS
41850
41851      shared_objects_gmp="$shared_objects_gmp $ac_bdir$ac_obj.lo"
41852
41853      case $ac_src in
41854        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41855        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41856        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41857        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
41858      esac
41859
41860      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
41861
41862    cat >>Makefile.objects<<EOF
41863-include $ac_bdir$ac_obj.dep
41864$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
41865	$ac_comp
41866EOF
41867  done
41868
41869
41870  install_modules="install-modules"
41871  suffix=la
41872
41873  case $host_alias in
41874    *aix*)
41875      additional_flags="-Wl,-G"
41876      ;;
41877  esac
41878
41879  if test "x" = "xyes"; then
41880    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/gmp.$suffix"
41881  else
41882    PHP_MODULES="$PHP_MODULES \$(phplibdir)/gmp.$suffix"
41883  fi
41884
41885  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_gmp"
41886
41887  cat >>Makefile.objects<<EOF
41888\$(phplibdir)/gmp.$suffix: $ext_builddir/gmp.$suffix
41889	\$(LIBTOOL) --mode=install cp $ext_builddir/gmp.$suffix \$(phplibdir)
41890
41891$ext_builddir/gmp.$suffix: \$(shared_objects_gmp) \$(GMP_SHARED_DEPENDENCIES)
41892	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_gmp) \$(GMP_SHARED_LIBADD)
41893
41894EOF
41895
41896
41897printf "%s\n" "#define COMPILE_DL_GMP 1" >>confdefs.h
41898
41899    fi
41900  fi
41901
41902  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
41903    PHP_GMP_SHARED=no
41904    case "$PHP_SAPI" in
41905      cgi|embed|phpdbg)
41906
41907
41908  case $ext_dir in
41909  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
41910  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
41911  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
41912  esac
41913
41914
41915
41916  b_c_pre=$php_c_pre
41917  b_cxx_pre=$php_cxx_pre
41918  b_c_meta=$php_c_meta
41919  b_cxx_meta=$php_cxx_meta
41920  b_c_post=$php_c_post
41921  b_cxx_post=$php_cxx_post
41922  b_lo=$php_lo
41923
41924
41925  old_IFS=$IFS
41926  for ac_src in gmp.c; do
41927
41928      IFS=.
41929      set $ac_src
41930      ac_obj=$1
41931      IFS=$old_IFS
41932
41933      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
41934
41935      case $ac_src in
41936        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41937        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41938        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41939        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
41940      esac
41941
41942      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
41943
41944    cat >>Makefile.objects<<EOF
41945-include $ac_bdir$ac_obj.dep
41946$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
41947	$ac_comp
41948EOF
41949  done
41950
41951
41952        EXT_STATIC="$EXT_STATIC gmp;$ext_dir"
41953        ;;
41954      *)
41955
41956
41957  case $ext_dir in
41958  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
41959  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
41960  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
41961  esac
41962
41963
41964
41965  b_c_pre=$php_c_pre
41966  b_cxx_pre=$php_cxx_pre
41967  b_c_meta=$php_c_meta
41968  b_cxx_meta=$php_cxx_meta
41969  b_c_post=$php_c_post
41970  b_cxx_post=$php_cxx_post
41971  b_lo=$php_lo
41972
41973
41974  old_IFS=$IFS
41975  for ac_src in gmp.c; do
41976
41977      IFS=.
41978      set $ac_src
41979      ac_obj=$1
41980      IFS=$old_IFS
41981
41982      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
41983
41984      case $ac_src in
41985        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41986        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41987        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
41988        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
41989      esac
41990
41991      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
41992
41993    cat >>Makefile.objects<<EOF
41994-include $ac_bdir$ac_obj.dep
41995$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
41996	$ac_comp
41997EOF
41998  done
41999
42000
42001        ;;
42002    esac
42003    EXT_CLI_STATIC="$EXT_CLI_STATIC gmp;$ext_dir"
42004  fi
42005
42006
42007    BUILD_DIR="$BUILD_DIR $ext_builddir"
42008
42009
42010
42011  if test "$ext_builddir" = "."; then
42012    PHP_PECL_EXTENSION=gmp
42013
42014  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
42015
42016  fi
42017
42018
42019  PHP_VAR_SUBST="$PHP_VAR_SUBST GMP_SHARED_LIBADD"
42020
42021
42022printf "%s\n" "#define HAVE_GMP 1" >>confdefs.h
42023
42024fi
42025
42026
42027
42028
42029
42030php_with_mhash=no
42031
42032{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mhash support" >&5
42033printf %s "checking for mhash support... " >&6; }
42034
42035# Check whether --with-mhash was given.
42036if test ${with_mhash+y}
42037then :
42038  withval=$with_mhash; PHP_MHASH=$withval
42039else $as_nop
42040
42041  PHP_MHASH=no
42042  test "$PHP_ENABLE_ALL" && PHP_MHASH=$PHP_ENABLE_ALL
42043
42044fi
42045
42046
42047
42048ext_output="yes, shared"
42049ext_shared=yes
42050case $PHP_MHASH in
42051shared,*)
42052  PHP_MHASH=`echo "$PHP_MHASH"|$SED 's/^shared,//'`
42053  ;;
42054shared)
42055  PHP_MHASH=yes
42056  ;;
42057no)
42058  ext_output=no
42059  ext_shared=no
42060  ;;
42061*)
42062  ext_output=yes
42063  ext_shared=no
42064  ;;
42065esac
42066
42067
42068
42069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
42070printf "%s\n" "$ext_output" >&6; }
42071
42072
42073
42074
42075if test "$PHP_MHASH" != "no"; then
42076  if test "$PHP_HASH" = "no"; then
42077    PHP_HASH="yes"
42078  fi
42079
42080
42081printf "%s\n" "#define PHP_MHASH_BC 1" >>confdefs.h
42082
42083fi
42084
42085if test $ac_cv_c_bigendian_php = yes; then
42086  EXT_HASH_SHA3_SOURCES="hash_sha3.c"
42087
42088printf "%s\n" "#define HAVE_SLOW_HASH3 1" >>confdefs.h
42089
42090  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: \"Use SHA3 slow implementation on bigendian\"" >&5
42091printf "%s\n" "$as_me: WARNING: \"Use SHA3 slow implementation on bigendian\"" >&2;}
42092else
42093  # The cast to long int works around a bug in the HP C Compiler
42094# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
42095# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
42096# This bug is HP SR number 8606223364.
42097{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
42098printf %s "checking size of long... " >&6; }
42099if test ${ac_cv_sizeof_long+y}
42100then :
42101  printf %s "(cached) " >&6
42102else $as_nop
42103  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
42104then :
42105
42106else $as_nop
42107  if test "$ac_cv_type_long" = yes; then
42108     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
42109printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
42110as_fn_error 77 "cannot compute sizeof (long)
42111See \`config.log' for more details" "$LINENO" 5; }
42112   else
42113     ac_cv_sizeof_long=0
42114   fi
42115fi
42116
42117fi
42118{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
42119printf "%s\n" "$ac_cv_sizeof_long" >&6; }
42120
42121
42122
42123printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
42124
42125
42126  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
42127printf %s "checking if we're at 64-bit platform... " >&6; }
42128  if test "$ac_cv_sizeof_long" -eq 4
42129then :
42130
42131    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
42132printf "%s\n" "no" >&6; }
42133    SHA3_DIR="sha3/generic32lc"
42134    SHA3_OPT_SRC="$SHA3_DIR/KeccakP-1600-inplace32BI.c"
42135
42136else $as_nop
42137
42138    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42139printf "%s\n" "yes" >&6; }
42140    SHA3_DIR="sha3/generic64lc"
42141    SHA3_OPT_SRC="$SHA3_DIR/KeccakP-1600-opt64.c"
42142
42143fi
42144  EXT_HASH_SHA3_SOURCES="$SHA3_OPT_SRC $SHA3_DIR/KeccakHash.c $SHA3_DIR/KeccakSponge.c hash_sha3.c"
42145    PHP_HASH_CFLAGS="-Wno-implicit-fallthrough -I@ext_srcdir@/$SHA3_DIR -DKeccakP200_excluded -DKeccakP400_excluded -DKeccakP800_excluded -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
42146
42147
42148
42149    $php_shtool mkdir -p ext/hash/$SHA3_DIR
42150
42151
42152fi
42153
42154
42155
42156    $php_shtool mkdir -p ext/hash/murmur
42157
42158
42159PHP_HASH_CFLAGS="$PHP_HASH_CFLAGS -I@ext_srcdir@/xxhash"
42160
42161EXT_HASH_SOURCES="hash.c hash_md.c hash_sha.c hash_ripemd.c hash_haval.c \
42162  hash_tiger.c hash_gost.c hash_snefru.c hash_whirlpool.c hash_adler32.c \
42163  hash_crc32.c hash_fnv.c hash_joaat.c $EXT_HASH_SHA3_SOURCES
42164  murmur/PMurHash.c murmur/PMurHash128.c hash_murmur.c hash_xxhash.c"
42165EXT_HASH_HEADERS="php_hash.h php_hash_md.h php_hash_sha.h php_hash_ripemd.h \
42166  php_hash_haval.h php_hash_tiger.h php_hash_gost.h php_hash_snefru.h \
42167  php_hash_whirlpool.h php_hash_adler32.h php_hash_crc32.h \
42168  php_hash_fnv.h php_hash_joaat.h php_hash_sha3.h php_hash_murmur.h \
42169  php_hash_xxhash.h"
42170
42171
42172  ext_builddir=ext/hash
42173  ext_srcdir=$abs_srcdir/ext/hash
42174  ext_dir=ext/hash
42175
42176  ac_extra=`echo "$PHP_HASH_CFLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
42177
42178  if test "0" != "shared" && test "0" != "yes" && test "" != "cli"; then
42179    PHP_HASH_SHARED=no
42180
42181
42182  case $ext_dir in
42183  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
42184  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
42185  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
42186  esac
42187
42188
42189
42190  b_c_pre=$php_c_pre
42191  b_cxx_pre=$php_cxx_pre
42192  b_c_meta=$php_c_meta
42193  b_cxx_meta=$php_cxx_meta
42194  b_c_post=$php_c_post
42195  b_cxx_post=$php_cxx_post
42196  b_lo=$php_lo
42197
42198
42199  old_IFS=$IFS
42200  for ac_src in $EXT_HASH_SOURCES; do
42201
42202      IFS=.
42203      set $ac_src
42204      ac_obj=$1
42205      IFS=$old_IFS
42206
42207      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
42208
42209      case $ac_src in
42210        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42211        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42212        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42213        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
42214      esac
42215
42216      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
42217
42218    cat >>Makefile.objects<<EOF
42219-include $ac_bdir$ac_obj.dep
42220$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
42221	$ac_comp
42222EOF
42223  done
42224
42225
42226    EXT_STATIC="$EXT_STATIC hash;$ext_dir"
42227    if test "0" != "nocli"; then
42228      EXT_CLI_STATIC="$EXT_CLI_STATIC hash;$ext_dir"
42229    fi
42230  else
42231    if test "0" = "shared" || test "0" = "yes"; then
42232      PHP_HASH_SHARED=yes
42233
42234  case $ext_dir in
42235  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
42236  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
42237  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
42238  esac
42239
42240
42241
42242  b_c_pre=$shared_c_pre
42243  b_cxx_pre=$shared_cxx_pre
42244  b_c_meta=$shared_c_meta
42245  b_cxx_meta=$shared_cxx_meta
42246  b_c_post=$shared_c_post
42247  b_cxx_post=$shared_cxx_post
42248  b_lo=$shared_lo
42249
42250
42251  old_IFS=$IFS
42252  for ac_src in $EXT_HASH_SOURCES; do
42253
42254      IFS=.
42255      set $ac_src
42256      ac_obj=$1
42257      IFS=$old_IFS
42258
42259      shared_objects_hash="$shared_objects_hash $ac_bdir$ac_obj.lo"
42260
42261      case $ac_src in
42262        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42263        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42264        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42265        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
42266      esac
42267
42268      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
42269
42270    cat >>Makefile.objects<<EOF
42271-include $ac_bdir$ac_obj.dep
42272$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
42273	$ac_comp
42274EOF
42275  done
42276
42277
42278  install_modules="install-modules"
42279  suffix=la
42280
42281  case $host_alias in
42282    *aix*)
42283      additional_flags="-Wl,-G"
42284      ;;
42285  esac
42286
42287  if test "x" = "xyes"; then
42288    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/hash.$suffix"
42289  else
42290    PHP_MODULES="$PHP_MODULES \$(phplibdir)/hash.$suffix"
42291  fi
42292
42293  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_hash"
42294
42295  cat >>Makefile.objects<<EOF
42296\$(phplibdir)/hash.$suffix: $ext_builddir/hash.$suffix
42297	\$(LIBTOOL) --mode=install cp $ext_builddir/hash.$suffix \$(phplibdir)
42298
42299$ext_builddir/hash.$suffix: \$(shared_objects_hash) \$(HASH_SHARED_DEPENDENCIES)
42300	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_hash) \$(HASH_SHARED_LIBADD)
42301
42302EOF
42303
42304
42305printf "%s\n" "#define COMPILE_DL_HASH 1" >>confdefs.h
42306
42307    fi
42308  fi
42309
42310  if test "0" != "shared" && test "0" != "yes" && test "" = "cli"; then
42311    PHP_HASH_SHARED=no
42312    case "$PHP_SAPI" in
42313      cgi|embed|phpdbg)
42314
42315
42316  case $ext_dir in
42317  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
42318  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
42319  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
42320  esac
42321
42322
42323
42324  b_c_pre=$php_c_pre
42325  b_cxx_pre=$php_cxx_pre
42326  b_c_meta=$php_c_meta
42327  b_cxx_meta=$php_cxx_meta
42328  b_c_post=$php_c_post
42329  b_cxx_post=$php_cxx_post
42330  b_lo=$php_lo
42331
42332
42333  old_IFS=$IFS
42334  for ac_src in $EXT_HASH_SOURCES; do
42335
42336      IFS=.
42337      set $ac_src
42338      ac_obj=$1
42339      IFS=$old_IFS
42340
42341      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
42342
42343      case $ac_src in
42344        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42345        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42346        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42347        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
42348      esac
42349
42350      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
42351
42352    cat >>Makefile.objects<<EOF
42353-include $ac_bdir$ac_obj.dep
42354$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
42355	$ac_comp
42356EOF
42357  done
42358
42359
42360        EXT_STATIC="$EXT_STATIC hash;$ext_dir"
42361        ;;
42362      *)
42363
42364
42365  case $ext_dir in
42366  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
42367  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
42368  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
42369  esac
42370
42371
42372
42373  b_c_pre=$php_c_pre
42374  b_cxx_pre=$php_cxx_pre
42375  b_c_meta=$php_c_meta
42376  b_cxx_meta=$php_cxx_meta
42377  b_c_post=$php_c_post
42378  b_cxx_post=$php_cxx_post
42379  b_lo=$php_lo
42380
42381
42382  old_IFS=$IFS
42383  for ac_src in $EXT_HASH_SOURCES; do
42384
42385      IFS=.
42386      set $ac_src
42387      ac_obj=$1
42388      IFS=$old_IFS
42389
42390      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
42391
42392      case $ac_src in
42393        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42394        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42395        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
42396        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
42397      esac
42398
42399      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
42400
42401    cat >>Makefile.objects<<EOF
42402-include $ac_bdir$ac_obj.dep
42403$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
42404	$ac_comp
42405EOF
42406  done
42407
42408
42409        ;;
42410    esac
42411    EXT_CLI_STATIC="$EXT_CLI_STATIC hash;$ext_dir"
42412  fi
42413
42414
42415    BUILD_DIR="$BUILD_DIR $ext_builddir"
42416
42417
42418
42419  if test "$ext_builddir" = "."; then
42420    PHP_PECL_EXTENSION=hash
42421
42422  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
42423
42424  fi
42425
42426
42427
42428    header_path=ext/hash
42429    for header_file in $EXT_HASH_HEADERS; do
42430      hp_hf="$header_path/$header_file"
42431
42432
42433  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
42434
42435  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
42436  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42437    eval "INSTALLHEADERS$unique=set"
42438
42439        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
42440
42441  fi
42442
42443    done
42444
42445
42446
42447
42448
42449
42450
42451php_with_iconv=yes
42452
42453{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv support" >&5
42454printf %s "checking for iconv support... " >&6; }
42455
42456# Check whether --with-iconv was given.
42457if test ${with_iconv+y}
42458then :
42459  withval=$with_iconv; PHP_ICONV=$withval
42460else $as_nop
42461
42462  PHP_ICONV=yes
42463  test "$PHP_ENABLE_ALL" && PHP_ICONV=$PHP_ENABLE_ALL
42464
42465fi
42466
42467
42468
42469ext_output="yes, shared"
42470ext_shared=yes
42471case $PHP_ICONV in
42472shared,*)
42473  PHP_ICONV=`echo "$PHP_ICONV"|$SED 's/^shared,//'`
42474  ;;
42475shared)
42476  PHP_ICONV=yes
42477  ;;
42478no)
42479  ext_output=no
42480  ext_shared=no
42481  ;;
42482*)
42483  ext_output=yes
42484  ext_shared=no
42485  ;;
42486esac
42487
42488
42489
42490{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
42491printf "%s\n" "$ext_output" >&6; }
42492
42493
42494
42495
42496if test "$PHP_ICONV" != "no"; then
42497
42498
42499  found_iconv=no
42500  unset ICONV_DIR
42501
42502    if test "$PHP_ICONV" = "yes"; then
42503        LIBS_save="$LIBS"
42504    LIBS=
42505    ac_fn_c_check_func "$LINENO" "iconv" "ac_cv_func_iconv"
42506if test "x$ac_cv_func_iconv" = xyes
42507then :
42508
42509      found_iconv=yes
42510
42511else $as_nop
42512
42513      ac_fn_c_check_func "$LINENO" "libiconv" "ac_cv_func_libiconv"
42514if test "x$ac_cv_func_libiconv" = xyes
42515then :
42516
42517
42518printf "%s\n" "#define HAVE_LIBICONV 1" >>confdefs.h
42519
42520        found_iconv=yes
42521
42522fi
42523
42524
42525fi
42526
42527    LIBS="$LIBS_save"
42528  fi
42529
42530    if test "$found_iconv" = "no"; then
42531
42532    for i in $PHP_ICONV /usr/local /usr; do
42533      if test -r $i/include/gnu-libiconv/iconv.h; then
42534        ICONV_DIR=$i
42535        ICONV_INCLUDE_DIR=$i/include/gnu-libiconv
42536        iconv_lib_name=iconv
42537        break
42538      elif test -r $i/include/iconv.h; then
42539        ICONV_DIR=$i
42540        ICONV_INCLUDE_DIR=$i/include
42541        iconv_lib_name=iconv
42542        break
42543      fi
42544    done
42545
42546    if test -z "$ICONV_DIR"; then
42547      as_fn_error $? "Please specify the install prefix of iconv with --with-iconv=<DIR>" "$LINENO" 5
42548    fi
42549
42550    if test -f $ICONV_DIR/$PHP_LIBDIR/lib$iconv_lib_name.a ||
42551       test -f $ICONV_DIR/$PHP_LIBDIR/lib$iconv_lib_name.$SHLIB_SUFFIX_NAME ||
42552       test -f $ICONV_DIR/$PHP_LIBDIR/lib$iconv_lib_name.tbd
42553    then
42554
42555  save_old_LDFLAGS=$LDFLAGS
42556  ac_stuff="
42557        -L$ICONV_DIR/$PHP_LIBDIR
42558      "
42559
42560  save_ext_shared=$ext_shared
42561  ext_shared=yes
42562
42563  for ac_i in $ac_stuff; do
42564    case $ac_i in
42565    -pthread)
42566      if test "$ext_shared" = "yes"; then
42567        LDFLAGS="$LDFLAGS -pthread"
42568      else
42569
42570
42571  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
42572
42573  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
42574  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42575    eval "EXTRA_LDFLAGS$unique=set"
42576    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
42577  fi
42578
42579
42580
42581  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
42582
42583  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
42584  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42585    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
42586    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
42587  fi
42588
42589      fi
42590    ;;
42591    -l*)
42592      ac_ii=`echo $ac_i|cut -c 3-`
42593
42594
42595  case $ac_ii in
42596  c|c_r) ;;
42597  *)
42598    if test "$ext_shared" = "yes"; then
42599        LDFLAGS="$LDFLAGS -l$ac_ii"
42600    else
42601
42602
42603  case $ac_ii in
42604  c|c_r) ;;
42605  *)
42606      LIBS="$LIBS -l$ac_ii"
42607   ;;
42608  esac
42609
42610
42611    fi
42612   ;;
42613  esac
42614
42615
42616    ;;
42617    -L*)
42618      ac_ii=`echo $ac_i|cut -c 3-`
42619
42620  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
42621
42622  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
42623    ai_p=$ac_ii
42624  else
42625
42626    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
42627
42628    ep_realdir=`(cd "$ep_dir" && pwd)`
42629    ai_p="$ep_realdir"/`basename "$ac_ii"`
42630  fi
42631
42632
42633      if test "$ext_shared" = "yes"; then
42634        LDFLAGS="-L$ai_p $LDFLAGS"
42635        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
42636      else
42637
42638
42639
42640  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
42641
42642  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
42643  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42644    eval "LIBPATH$unique=set"
42645
42646    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
42647    LDFLAGS="$LDFLAGS -L$ai_p"
42648    PHP_RPATHS="$PHP_RPATHS $ai_p"
42649
42650  fi
42651
42652
42653      fi
42654
42655  fi
42656
42657    ;;
42658    esac
42659  done
42660
42661  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$iconv_lib_name""_libiconv" | $as_tr_sh`
42662{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libiconv in -l$iconv_lib_name" >&5
42663printf %s "checking for libiconv in -l$iconv_lib_name... " >&6; }
42664if eval test \${$as_ac_Lib+y}
42665then :
42666  printf %s "(cached) " >&6
42667else $as_nop
42668  ac_check_lib_save_LIBS=$LIBS
42669LIBS="-l$iconv_lib_name  $LIBS"
42670cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42671/* end confdefs.h.  */
42672
42673/* Override any GCC internal prototype to avoid an error.
42674   Use char because int might match the return type of a GCC
42675   builtin and then its argument prototype would still apply.  */
42676char libiconv ();
42677int
42678main (void)
42679{
42680return libiconv ();
42681  ;
42682  return 0;
42683}
42684_ACEOF
42685if ac_fn_c_try_link "$LINENO"
42686then :
42687  eval "$as_ac_Lib=yes"
42688else $as_nop
42689  eval "$as_ac_Lib=no"
42690fi
42691rm -f core conftest.err conftest.$ac_objext conftest.beam \
42692    conftest$ac_exeext conftest.$ac_ext
42693LIBS=$ac_check_lib_save_LIBS
42694fi
42695eval ac_res=\$$as_ac_Lib
42696	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
42697printf "%s\n" "$ac_res" >&6; }
42698if eval test \"x\$"$as_ac_Lib"\" = x"yes"
42699then :
42700
42701    LDFLAGS=$save_old_LDFLAGS
42702    ext_shared=$save_ext_shared
42703
42704        found_iconv=yes
42705
42706printf "%s\n" "#define HAVE_LIBICONV 1" >>confdefs.h
42707
42708
42709printf "%s\n" "#define ICONV_ALIASED_LIBICONV 1" >>confdefs.h
42710
42711
42712
42713else $as_nop
42714
42715    LDFLAGS=$save_old_LDFLAGS
42716    ext_shared=$save_ext_shared
42717    unset ac_cv_lib_$iconv_lib_name_libiconv
42718
42719
42720  save_old_LDFLAGS=$LDFLAGS
42721  ac_stuff="
42722          -L$ICONV_DIR/$PHP_LIBDIR
42723        "
42724
42725  save_ext_shared=$ext_shared
42726  ext_shared=yes
42727
42728  for ac_i in $ac_stuff; do
42729    case $ac_i in
42730    -pthread)
42731      if test "$ext_shared" = "yes"; then
42732        LDFLAGS="$LDFLAGS -pthread"
42733      else
42734
42735
42736  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
42737
42738  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
42739  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42740    eval "EXTRA_LDFLAGS$unique=set"
42741    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
42742  fi
42743
42744
42745
42746  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
42747
42748  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
42749  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42750    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
42751    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
42752  fi
42753
42754      fi
42755    ;;
42756    -l*)
42757      ac_ii=`echo $ac_i|cut -c 3-`
42758
42759
42760  case $ac_ii in
42761  c|c_r) ;;
42762  *)
42763    if test "$ext_shared" = "yes"; then
42764        LDFLAGS="$LDFLAGS -l$ac_ii"
42765    else
42766
42767
42768  case $ac_ii in
42769  c|c_r) ;;
42770  *)
42771      LIBS="$LIBS -l$ac_ii"
42772   ;;
42773  esac
42774
42775
42776    fi
42777   ;;
42778  esac
42779
42780
42781    ;;
42782    -L*)
42783      ac_ii=`echo $ac_i|cut -c 3-`
42784
42785  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
42786
42787  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
42788    ai_p=$ac_ii
42789  else
42790
42791    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
42792
42793    ep_realdir=`(cd "$ep_dir" && pwd)`
42794    ai_p="$ep_realdir"/`basename "$ac_ii"`
42795  fi
42796
42797
42798      if test "$ext_shared" = "yes"; then
42799        LDFLAGS="-L$ai_p $LDFLAGS"
42800        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
42801      else
42802
42803
42804
42805  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
42806
42807  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
42808  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42809    eval "LIBPATH$unique=set"
42810
42811    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
42812    LDFLAGS="$LDFLAGS -L$ai_p"
42813    PHP_RPATHS="$PHP_RPATHS $ai_p"
42814
42815  fi
42816
42817
42818      fi
42819
42820  fi
42821
42822    ;;
42823    esac
42824  done
42825
42826  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$iconv_lib_name""_iconv" | $as_tr_sh`
42827{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv in -l$iconv_lib_name" >&5
42828printf %s "checking for iconv in -l$iconv_lib_name... " >&6; }
42829if eval test \${$as_ac_Lib+y}
42830then :
42831  printf %s "(cached) " >&6
42832else $as_nop
42833  ac_check_lib_save_LIBS=$LIBS
42834LIBS="-l$iconv_lib_name  $LIBS"
42835cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42836/* end confdefs.h.  */
42837
42838/* Override any GCC internal prototype to avoid an error.
42839   Use char because int might match the return type of a GCC
42840   builtin and then its argument prototype would still apply.  */
42841char iconv ();
42842int
42843main (void)
42844{
42845return iconv ();
42846  ;
42847  return 0;
42848}
42849_ACEOF
42850if ac_fn_c_try_link "$LINENO"
42851then :
42852  eval "$as_ac_Lib=yes"
42853else $as_nop
42854  eval "$as_ac_Lib=no"
42855fi
42856rm -f core conftest.err conftest.$ac_objext conftest.beam \
42857    conftest$ac_exeext conftest.$ac_ext
42858LIBS=$ac_check_lib_save_LIBS
42859fi
42860eval ac_res=\$$as_ac_Lib
42861	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
42862printf "%s\n" "$ac_res" >&6; }
42863if eval test \"x\$"$as_ac_Lib"\" = x"yes"
42864then :
42865
42866    LDFLAGS=$save_old_LDFLAGS
42867    ext_shared=$save_ext_shared
42868
42869          found_iconv=yes
42870
42871
42872else $as_nop
42873
42874    LDFLAGS=$save_old_LDFLAGS
42875    ext_shared=$save_ext_shared
42876    unset ac_cv_lib_$iconv_lib_name_iconv
42877
42878
42879fi
42880
42881
42882
42883fi
42884
42885    fi
42886  fi
42887
42888  if test "$found_iconv" = "yes"; then
42889
42890printf "%s\n" "#define HAVE_ICONV 1" >>confdefs.h
42891
42892    if test -n "$ICONV_DIR"; then
42893
42894
42895  if test "$ext_shared" = "yes"; then
42896    ICONV_SHARED_LIBADD="-l$iconv_lib_name $ICONV_SHARED_LIBADD"
42897    if test -n "$ICONV_DIR/$PHP_LIBDIR"; then
42898
42899  if test "$ICONV_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$ICONV_DIR/$PHP_LIBDIR" != "/usr/lib"; then
42900
42901  if test -z "$ICONV_DIR/$PHP_LIBDIR" || echo "$ICONV_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
42902    ai_p=$ICONV_DIR/$PHP_LIBDIR
42903  else
42904
42905    ep_dir=`echo $ICONV_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
42906
42907    ep_realdir=`(cd "$ep_dir" && pwd)`
42908    ai_p="$ep_realdir"/`basename "$ICONV_DIR/$PHP_LIBDIR"`
42909  fi
42910
42911
42912      if test "$ext_shared" = "yes"; then
42913        ICONV_SHARED_LIBADD="-L$ai_p $ICONV_SHARED_LIBADD"
42914        test -n "$ld_runpath_switch" && ICONV_SHARED_LIBADD="$ld_runpath_switch$ai_p $ICONV_SHARED_LIBADD"
42915      else
42916
42917
42918
42919  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
42920
42921  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
42922  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42923    eval "LIBPATH$unique=set"
42924
42925    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
42926    LDFLAGS="$LDFLAGS -L$ai_p"
42927    PHP_RPATHS="$PHP_RPATHS $ai_p"
42928
42929  fi
42930
42931
42932      fi
42933
42934  fi
42935
42936    fi
42937  else
42938
42939
42940  if test -n "$ICONV_DIR/$PHP_LIBDIR"; then
42941
42942  if test "$ICONV_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$ICONV_DIR/$PHP_LIBDIR" != "/usr/lib"; then
42943
42944  if test -z "$ICONV_DIR/$PHP_LIBDIR" || echo "$ICONV_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
42945    ai_p=$ICONV_DIR/$PHP_LIBDIR
42946  else
42947
42948    ep_dir=`echo $ICONV_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
42949
42950    ep_realdir=`(cd "$ep_dir" && pwd)`
42951    ai_p="$ep_realdir"/`basename "$ICONV_DIR/$PHP_LIBDIR"`
42952  fi
42953
42954
42955
42956
42957
42958  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
42959
42960  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
42961  if test -n "$unique" && test "`eval $cmd`" = "" ; then
42962    eval "LIBPATH$unique=set"
42963
42964    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
42965    LDFLAGS="$LDFLAGS -L$ai_p"
42966    PHP_RPATHS="$PHP_RPATHS $ai_p"
42967
42968  fi
42969
42970
42971
42972  fi
42973
42974  fi
42975
42976
42977  case $iconv_lib_name in
42978  c|c_r) ;;
42979  *)
42980      LIBS="-l$iconv_lib_name $LIBS"
42981   ;;
42982  esac
42983
42984
42985
42986
42987  fi
42988
42989
42990
42991  if test "$ICONV_INCLUDE_DIR" != "/usr/include"; then
42992
42993  if test -z "$ICONV_INCLUDE_DIR" || echo "$ICONV_INCLUDE_DIR" | grep '^/' >/dev/null ; then
42994    ai_p=$ICONV_INCLUDE_DIR
42995  else
42996
42997    ep_dir=`echo $ICONV_INCLUDE_DIR|$SED 's%/*[^/][^/]*/*$%%'`
42998
42999    ep_realdir=`(cd "$ep_dir" && pwd)`
43000    ai_p="$ep_realdir"/`basename "$ICONV_INCLUDE_DIR"`
43001  fi
43002
43003
43004
43005  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
43006
43007  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
43008  if test -n "$unique" && test "`eval $cmd`" = "" ; then
43009    eval "INCLUDEPATH$unique=set"
43010
43011      if test ""; then
43012        INCLUDES="-I$ai_p $INCLUDES"
43013      else
43014        INCLUDES="$INCLUDES -I$ai_p"
43015      fi
43016
43017  fi
43018
43019  fi
43020
43021    fi
43022
43023    iconv_avail="yes";
43024
43025else
43026    iconv_avail="no";
43027
43028  fi
43029
43030
43031  if test "$iconv_avail" != "no"; then
43032    save_LDFLAGS="$LDFLAGS"
43033    save_CFLAGS="$CFLAGS"
43034    LDFLAGS="$ICONV_SHARED_LIBADD $LDFLAGS"
43035    CFLAGS="$INCLUDES $CFLAGS"
43036
43037    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if iconv is glibc's" >&5
43038printf %s "checking if iconv is glibc's... " >&6; }
43039    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43040/* end confdefs.h.  */
43041#include <gnu/libc-version.h>
43042int
43043main (void)
43044{
43045gnu_get_libc_version();
43046  ;
43047  return 0;
43048}
43049_ACEOF
43050if ac_fn_c_try_link "$LINENO"
43051then :
43052
43053      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43054printf "%s\n" "yes" >&6; }
43055      iconv_impl_name="glibc"
43056
43057else $as_nop
43058
43059      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43060printf "%s\n" "no" >&6; }
43061
43062fi
43063rm -f core conftest.err conftest.$ac_objext conftest.beam \
43064    conftest$ac_exeext conftest.$ac_ext
43065
43066    if test -z "$iconv_impl_name"; then
43067      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if using GNU libiconv" >&5
43068printf %s "checking if using GNU libiconv... " >&6; }
43069      if test "$cross_compiling" = yes
43070then :
43071
43072        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, cross-compiling" >&5
43073printf "%s\n" "no, cross-compiling" >&6; }
43074
43075else $as_nop
43076  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43077/* end confdefs.h.  */
43078
43079#include <iconv.h>
43080int main() {
43081  printf("%d", _libiconv_version);
43082  return 0;
43083}
43084
43085_ACEOF
43086if ac_fn_c_try_run "$LINENO"
43087then :
43088
43089        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43090printf "%s\n" "yes" >&6; }
43091        iconv_impl_name="gnu_libiconv"
43092
43093else $as_nop
43094
43095        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43096printf "%s\n" "no" >&6; }
43097
43098fi
43099rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43100  conftest.$ac_objext conftest.beam conftest.$ac_ext
43101fi
43102
43103    fi
43104
43105    if test -z "$iconv_impl_name"; then
43106      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if iconv is Konstantin Chuguev's" >&5
43107printf %s "checking if iconv is Konstantin Chuguev's... " >&6; }
43108      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43109/* end confdefs.h.  */
43110#include <iconv.h>
43111int
43112main (void)
43113{
43114iconv_ccs_init(NULL, NULL);
43115  ;
43116  return 0;
43117}
43118_ACEOF
43119if ac_fn_c_try_link "$LINENO"
43120then :
43121
43122        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43123printf "%s\n" "yes" >&6; }
43124        iconv_impl_name="bsd"
43125
43126else $as_nop
43127
43128        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43129printf "%s\n" "no" >&6; }
43130
43131fi
43132rm -f core conftest.err conftest.$ac_objext conftest.beam \
43133    conftest$ac_exeext conftest.$ac_ext
43134    fi
43135
43136    if test -z "$iconv_impl_name"; then
43137      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if using IBM iconv" >&5
43138printf %s "checking if using IBM iconv... " >&6; }
43139      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43140/* end confdefs.h.  */
43141#include <iconv.h>
43142int
43143main (void)
43144{
43145cstoccsid("");
43146  ;
43147  return 0;
43148}
43149_ACEOF
43150if ac_fn_c_try_link "$LINENO"
43151then :
43152
43153        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43154printf "%s\n" "yes" >&6; }
43155        iconv_impl_name="ibm"
43156
43157else $as_nop
43158
43159        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43160printf "%s\n" "no" >&6; }
43161
43162fi
43163rm -f core conftest.err conftest.$ac_objext conftest.beam \
43164    conftest$ac_exeext conftest.$ac_ext
43165    fi
43166
43167    case "$iconv_impl_name" in
43168      gnu_libiconv )
43169
43170printf "%s\n" "#define PHP_ICONV_IMPL \"libiconv\"" >>confdefs.h
43171
43172
43173printf "%s\n" "#define HAVE_LIBICONV 1" >>confdefs.h
43174
43175        ;;
43176
43177      bsd )
43178
43179printf "%s\n" "#define HAVE_BSD_ICONV 1" >>confdefs.h
43180
43181
43182printf "%s\n" "#define PHP_ICONV_IMPL \"BSD iconv\"" >>confdefs.h
43183
43184        ;;
43185
43186      glibc )
43187
43188printf "%s\n" "#define HAVE_GLIBC_ICONV 1" >>confdefs.h
43189
43190
43191printf "%s\n" "#define PHP_ICONV_IMPL \"glibc\"" >>confdefs.h
43192
43193        ;;
43194      ibm )
43195
43196printf "%s\n" "#define HAVE_IBM_ICONV 1" >>confdefs.h
43197
43198
43199printf "%s\n" "#define PHP_ICONV_IMPL \"IBM iconv\"" >>confdefs.h
43200
43201        ;;
43202    esac
43203
43204    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if iconv supports errno" >&5
43205printf %s "checking if iconv supports errno... " >&6; }
43206    if test "$cross_compiling" = yes
43207then :
43208
43209      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43210printf "%s\n" "yes" >&6; }
43211
43212else $as_nop
43213  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43214/* end confdefs.h.  */
43215
43216#include <iconv.h>
43217#include <errno.h>
43218
43219int main() {
43220  iconv_t cd;
43221  cd = iconv_open( "*blahblah*", "*blahblahblah*" );
43222  if (cd == (iconv_t)(-1)) {
43223    if (errno == EINVAL) {
43224      return 0;
43225  } else {
43226      return 1;
43227    }
43228  }
43229  iconv_close( cd );
43230  return 2;
43231}
43232
43233_ACEOF
43234if ac_fn_c_try_run "$LINENO"
43235then :
43236
43237      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43238printf "%s\n" "yes" >&6; }
43239
43240else $as_nop
43241
43242      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43243printf "%s\n" "no" >&6; }
43244      as_fn_error $? "iconv does not support errno" "$LINENO" 5
43245
43246fi
43247rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43248  conftest.$ac_objext conftest.beam conftest.$ac_ext
43249fi
43250
43251
43252    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if iconv supports //IGNORE" >&5
43253printf %s "checking if iconv supports //IGNORE... " >&6; }
43254    if test "$cross_compiling" = yes
43255then :
43256
43257      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43258printf "%s\n" "no" >&6; }
43259
43260printf "%s\n" "#define ICONV_BROKEN_IGNORE 0" >>confdefs.h
43261
43262
43263else $as_nop
43264  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43265/* end confdefs.h.  */
43266
43267#include <iconv.h>
43268#include <stdlib.h>
43269
43270int main() {
43271  iconv_t cd = iconv_open( "UTF-8//IGNORE", "UTF-8" );
43272  if(cd == (iconv_t)-1) {
43273    return 1;
43274  }
43275  char *in_p = "\xC3\xC3\xC3\xB8";
43276  size_t in_left = 4, out_left = 4096;
43277  char *out = malloc(out_left);
43278  char *out_p = out;
43279  size_t result = iconv(cd, (char **) &in_p, &in_left, (char **) &out_p, &out_left);
43280  if(result == (size_t)-1) {
43281    return 1;
43282  }
43283  return 0;
43284}
43285
43286_ACEOF
43287if ac_fn_c_try_run "$LINENO"
43288then :
43289
43290      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43291printf "%s\n" "yes" >&6; }
43292
43293printf "%s\n" "#define ICONV_BROKEN_IGNORE 0" >>confdefs.h
43294
43295
43296else $as_nop
43297
43298      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
43299printf "%s\n" "no" >&6; }
43300
43301printf "%s\n" "#define ICONV_BROKEN_IGNORE 1" >>confdefs.h
43302
43303
43304fi
43305rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43306  conftest.$ac_objext conftest.beam conftest.$ac_ext
43307fi
43308
43309
43310    LDFLAGS="$save_LDFLAGS"
43311    CFLAGS="$save_CFLAGS"
43312
43313
43314  ext_builddir=ext/iconv
43315  ext_srcdir=$abs_srcdir/ext/iconv
43316  ext_dir=ext/iconv
43317
43318  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
43319
43320  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
43321    PHP_ICONV_SHARED=no
43322
43323
43324  case $ext_dir in
43325  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43326  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43327  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43328  esac
43329
43330
43331
43332  b_c_pre=$php_c_pre
43333  b_cxx_pre=$php_cxx_pre
43334  b_c_meta=$php_c_meta
43335  b_cxx_meta=$php_cxx_meta
43336  b_c_post=$php_c_post
43337  b_cxx_post=$php_cxx_post
43338  b_lo=$php_lo
43339
43340
43341  old_IFS=$IFS
43342  for ac_src in iconv.c; do
43343
43344      IFS=.
43345      set $ac_src
43346      ac_obj=$1
43347      IFS=$old_IFS
43348
43349      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43350
43351      case $ac_src in
43352        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43353        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43354        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43355        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43356      esac
43357
43358      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43359
43360    cat >>Makefile.objects<<EOF
43361-include $ac_bdir$ac_obj.dep
43362$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43363	$ac_comp
43364EOF
43365  done
43366
43367
43368    EXT_STATIC="$EXT_STATIC iconv;$ext_dir"
43369    if test "$ext_shared" != "nocli"; then
43370      EXT_CLI_STATIC="$EXT_CLI_STATIC iconv;$ext_dir"
43371    fi
43372  else
43373    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
43374      PHP_ICONV_SHARED=yes
43375
43376  case $ext_dir in
43377  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43378  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43379  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43380  esac
43381
43382
43383
43384  b_c_pre=$shared_c_pre
43385  b_cxx_pre=$shared_cxx_pre
43386  b_c_meta=$shared_c_meta
43387  b_cxx_meta=$shared_cxx_meta
43388  b_c_post=$shared_c_post
43389  b_cxx_post=$shared_cxx_post
43390  b_lo=$shared_lo
43391
43392
43393  old_IFS=$IFS
43394  for ac_src in iconv.c; do
43395
43396      IFS=.
43397      set $ac_src
43398      ac_obj=$1
43399      IFS=$old_IFS
43400
43401      shared_objects_iconv="$shared_objects_iconv $ac_bdir$ac_obj.lo"
43402
43403      case $ac_src in
43404        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43405        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43406        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43407        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43408      esac
43409
43410      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43411
43412    cat >>Makefile.objects<<EOF
43413-include $ac_bdir$ac_obj.dep
43414$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43415	$ac_comp
43416EOF
43417  done
43418
43419
43420  install_modules="install-modules"
43421  suffix=la
43422
43423  case $host_alias in
43424    *aix*)
43425      additional_flags="-Wl,-G"
43426      ;;
43427  esac
43428
43429  if test "x" = "xyes"; then
43430    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/iconv.$suffix"
43431  else
43432    PHP_MODULES="$PHP_MODULES \$(phplibdir)/iconv.$suffix"
43433  fi
43434
43435  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_iconv"
43436
43437  cat >>Makefile.objects<<EOF
43438\$(phplibdir)/iconv.$suffix: $ext_builddir/iconv.$suffix
43439	\$(LIBTOOL) --mode=install cp $ext_builddir/iconv.$suffix \$(phplibdir)
43440
43441$ext_builddir/iconv.$suffix: \$(shared_objects_iconv) \$(ICONV_SHARED_DEPENDENCIES)
43442	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_iconv) \$(ICONV_SHARED_LIBADD)
43443
43444EOF
43445
43446
43447printf "%s\n" "#define COMPILE_DL_ICONV 1" >>confdefs.h
43448
43449    fi
43450  fi
43451
43452  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
43453    PHP_ICONV_SHARED=no
43454    case "$PHP_SAPI" in
43455      cgi|embed|phpdbg)
43456
43457
43458  case $ext_dir in
43459  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43460  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43461  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43462  esac
43463
43464
43465
43466  b_c_pre=$php_c_pre
43467  b_cxx_pre=$php_cxx_pre
43468  b_c_meta=$php_c_meta
43469  b_cxx_meta=$php_cxx_meta
43470  b_c_post=$php_c_post
43471  b_cxx_post=$php_cxx_post
43472  b_lo=$php_lo
43473
43474
43475  old_IFS=$IFS
43476  for ac_src in iconv.c; do
43477
43478      IFS=.
43479      set $ac_src
43480      ac_obj=$1
43481      IFS=$old_IFS
43482
43483      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43484
43485      case $ac_src in
43486        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43487        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43488        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43489        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43490      esac
43491
43492      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43493
43494    cat >>Makefile.objects<<EOF
43495-include $ac_bdir$ac_obj.dep
43496$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43497	$ac_comp
43498EOF
43499  done
43500
43501
43502        EXT_STATIC="$EXT_STATIC iconv;$ext_dir"
43503        ;;
43504      *)
43505
43506
43507  case $ext_dir in
43508  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43509  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43510  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43511  esac
43512
43513
43514
43515  b_c_pre=$php_c_pre
43516  b_cxx_pre=$php_cxx_pre
43517  b_c_meta=$php_c_meta
43518  b_cxx_meta=$php_cxx_meta
43519  b_c_post=$php_c_post
43520  b_cxx_post=$php_cxx_post
43521  b_lo=$php_lo
43522
43523
43524  old_IFS=$IFS
43525  for ac_src in iconv.c; do
43526
43527      IFS=.
43528      set $ac_src
43529      ac_obj=$1
43530      IFS=$old_IFS
43531
43532      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43533
43534      case $ac_src in
43535        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43536        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43537        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43538        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43539      esac
43540
43541      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43542
43543    cat >>Makefile.objects<<EOF
43544-include $ac_bdir$ac_obj.dep
43545$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43546	$ac_comp
43547EOF
43548  done
43549
43550
43551        ;;
43552    esac
43553    EXT_CLI_STATIC="$EXT_CLI_STATIC iconv;$ext_dir"
43554  fi
43555
43556
43557    BUILD_DIR="$BUILD_DIR $ext_builddir"
43558
43559
43560
43561  if test "$ext_builddir" = "."; then
43562    PHP_PECL_EXTENSION=iconv
43563
43564  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
43565
43566  fi
43567
43568
43569  PHP_VAR_SUBST="$PHP_VAR_SUBST ICONV_SHARED_LIBADD"
43570
43571
43572
43573    for header_file in ext/iconv/; do
43574
43575
43576  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
43577
43578  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
43579  if test -n "$unique" && test "`eval $cmd`" = "" ; then
43580    eval "INSTALLHEADERS$unique=set"
43581
43582        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
43583
43584  fi
43585
43586    done
43587
43588
43589  else
43590    as_fn_error $? "Please reinstall the iconv library." "$LINENO" 5
43591  fi
43592fi
43593
43594
43595
43596
43597
43598
43599
43600
43601
43602
43603
43604
43605
43606
43607
43608php_with_imap=no
43609
43610{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for IMAP support" >&5
43611printf %s "checking for IMAP support... " >&6; }
43612
43613# Check whether --with-imap was given.
43614if test ${with_imap+y}
43615then :
43616  withval=$with_imap; PHP_IMAP=$withval
43617else $as_nop
43618
43619  PHP_IMAP=no
43620  test "$PHP_ENABLE_ALL" && PHP_IMAP=$PHP_ENABLE_ALL
43621
43622fi
43623
43624
43625
43626ext_output="yes, shared"
43627ext_shared=yes
43628case $PHP_IMAP in
43629shared,*)
43630  PHP_IMAP=`echo "$PHP_IMAP"|$SED 's/^shared,//'`
43631  ;;
43632shared)
43633  PHP_IMAP=yes
43634  ;;
43635no)
43636  ext_output=no
43637  ext_shared=no
43638  ;;
43639*)
43640  ext_output=yes
43641  ext_shared=no
43642  ;;
43643esac
43644
43645
43646
43647{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
43648printf "%s\n" "$ext_output" >&6; }
43649
43650
43651
43652
43653
43654php_with_kerberos=no
43655
43656{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for IMAP Kerberos support" >&5
43657printf %s "checking for IMAP Kerberos support... " >&6; }
43658
43659# Check whether --with-kerberos was given.
43660if test ${with_kerberos+y}
43661then :
43662  withval=$with_kerberos; PHP_KERBEROS=$withval
43663else $as_nop
43664
43665  PHP_KERBEROS=no
43666
43667
43668fi
43669
43670
43671ext_output=$PHP_KERBEROS
43672{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
43673printf "%s\n" "$ext_output" >&6; }
43674
43675
43676
43677
43678
43679php_with_imap_ssl=no
43680
43681{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for IMAP SSL support" >&5
43682printf %s "checking for IMAP SSL support... " >&6; }
43683
43684# Check whether --with-imap-ssl was given.
43685if test ${with_imap_ssl+y}
43686then :
43687  withval=$with_imap_ssl; PHP_IMAP_SSL=$withval
43688else $as_nop
43689
43690  PHP_IMAP_SSL=no
43691
43692
43693fi
43694
43695
43696ext_output=$PHP_IMAP_SSL
43697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
43698printf "%s\n" "$ext_output" >&6; }
43699
43700
43701
43702
43703if test "$PHP_IMAP" != "no"; then
43704
43705  PHP_VAR_SUBST="$PHP_VAR_SUBST IMAP_SHARED_LIBADD"
43706
43707
43708  ext_builddir=ext/imap
43709  ext_srcdir=$abs_srcdir/ext/imap
43710  ext_dir=ext/imap
43711
43712  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
43713
43714  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
43715    PHP_IMAP_SHARED=no
43716
43717
43718  case $ext_dir in
43719  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43720  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43721  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43722  esac
43723
43724
43725
43726  b_c_pre=$php_c_pre
43727  b_cxx_pre=$php_cxx_pre
43728  b_c_meta=$php_c_meta
43729  b_cxx_meta=$php_cxx_meta
43730  b_c_post=$php_c_post
43731  b_cxx_post=$php_cxx_post
43732  b_lo=$php_lo
43733
43734
43735  old_IFS=$IFS
43736  for ac_src in php_imap.c; do
43737
43738      IFS=.
43739      set $ac_src
43740      ac_obj=$1
43741      IFS=$old_IFS
43742
43743      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43744
43745      case $ac_src in
43746        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43747        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43748        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43749        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43750      esac
43751
43752      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43753
43754    cat >>Makefile.objects<<EOF
43755-include $ac_bdir$ac_obj.dep
43756$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43757	$ac_comp
43758EOF
43759  done
43760
43761
43762    EXT_STATIC="$EXT_STATIC imap;$ext_dir"
43763    if test "$ext_shared" != "nocli"; then
43764      EXT_CLI_STATIC="$EXT_CLI_STATIC imap;$ext_dir"
43765    fi
43766  else
43767    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
43768      PHP_IMAP_SHARED=yes
43769
43770  case $ext_dir in
43771  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43772  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43773  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43774  esac
43775
43776
43777
43778  b_c_pre=$shared_c_pre
43779  b_cxx_pre=$shared_cxx_pre
43780  b_c_meta=$shared_c_meta
43781  b_cxx_meta=$shared_cxx_meta
43782  b_c_post=$shared_c_post
43783  b_cxx_post=$shared_cxx_post
43784  b_lo=$shared_lo
43785
43786
43787  old_IFS=$IFS
43788  for ac_src in php_imap.c; do
43789
43790      IFS=.
43791      set $ac_src
43792      ac_obj=$1
43793      IFS=$old_IFS
43794
43795      shared_objects_imap="$shared_objects_imap $ac_bdir$ac_obj.lo"
43796
43797      case $ac_src in
43798        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43799        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43800        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43801        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43802      esac
43803
43804      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43805
43806    cat >>Makefile.objects<<EOF
43807-include $ac_bdir$ac_obj.dep
43808$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43809	$ac_comp
43810EOF
43811  done
43812
43813
43814  install_modules="install-modules"
43815  suffix=la
43816
43817  case $host_alias in
43818    *aix*)
43819      additional_flags="-Wl,-G"
43820      ;;
43821  esac
43822
43823  if test "x" = "xyes"; then
43824    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/imap.$suffix"
43825  else
43826    PHP_MODULES="$PHP_MODULES \$(phplibdir)/imap.$suffix"
43827  fi
43828
43829  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_imap"
43830
43831  cat >>Makefile.objects<<EOF
43832\$(phplibdir)/imap.$suffix: $ext_builddir/imap.$suffix
43833	\$(LIBTOOL) --mode=install cp $ext_builddir/imap.$suffix \$(phplibdir)
43834
43835$ext_builddir/imap.$suffix: \$(shared_objects_imap) \$(IMAP_SHARED_DEPENDENCIES)
43836	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_imap) \$(IMAP_SHARED_LIBADD)
43837
43838EOF
43839
43840
43841printf "%s\n" "#define COMPILE_DL_IMAP 1" >>confdefs.h
43842
43843    fi
43844  fi
43845
43846  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
43847    PHP_IMAP_SHARED=no
43848    case "$PHP_SAPI" in
43849      cgi|embed|phpdbg)
43850
43851
43852  case $ext_dir in
43853  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43854  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43855  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43856  esac
43857
43858
43859
43860  b_c_pre=$php_c_pre
43861  b_cxx_pre=$php_cxx_pre
43862  b_c_meta=$php_c_meta
43863  b_cxx_meta=$php_cxx_meta
43864  b_c_post=$php_c_post
43865  b_cxx_post=$php_cxx_post
43866  b_lo=$php_lo
43867
43868
43869  old_IFS=$IFS
43870  for ac_src in php_imap.c; do
43871
43872      IFS=.
43873      set $ac_src
43874      ac_obj=$1
43875      IFS=$old_IFS
43876
43877      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43878
43879      case $ac_src in
43880        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43881        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43882        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43883        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43884      esac
43885
43886      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43887
43888    cat >>Makefile.objects<<EOF
43889-include $ac_bdir$ac_obj.dep
43890$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43891	$ac_comp
43892EOF
43893  done
43894
43895
43896        EXT_STATIC="$EXT_STATIC imap;$ext_dir"
43897        ;;
43898      *)
43899
43900
43901  case $ext_dir in
43902  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
43903  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
43904  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
43905  esac
43906
43907
43908
43909  b_c_pre=$php_c_pre
43910  b_cxx_pre=$php_cxx_pre
43911  b_c_meta=$php_c_meta
43912  b_cxx_meta=$php_cxx_meta
43913  b_c_post=$php_c_post
43914  b_cxx_post=$php_cxx_post
43915  b_lo=$php_lo
43916
43917
43918  old_IFS=$IFS
43919  for ac_src in php_imap.c; do
43920
43921      IFS=.
43922      set $ac_src
43923      ac_obj=$1
43924      IFS=$old_IFS
43925
43926      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
43927
43928      case $ac_src in
43929        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43930        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43931        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
43932        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
43933      esac
43934
43935      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
43936
43937    cat >>Makefile.objects<<EOF
43938-include $ac_bdir$ac_obj.dep
43939$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
43940	$ac_comp
43941EOF
43942  done
43943
43944
43945        ;;
43946    esac
43947    EXT_CLI_STATIC="$EXT_CLI_STATIC imap;$ext_dir"
43948  fi
43949
43950
43951    BUILD_DIR="$BUILD_DIR $ext_builddir"
43952
43953
43954
43955  if test "$ext_builddir" = "."; then
43956    PHP_PECL_EXTENSION=imap
43957
43958  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
43959
43960  fi
43961
43962
43963printf "%s\n" "#define HAVE_IMAP 1" >>confdefs.h
43964
43965
43966    for i in $PHP_IMAP /usr/local /usr; do
43967      if test -r "$i/c-client.h"; then
43968
43969printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
43970
43971    IMAP_DIR=$i
43972    IMAP_INC_DIR=$i
43973    break
43974  elif test -r "$i/rfc822.h"; then
43975    IMAP_DIR=$i;
43976    IMAP_INC_DIR=$i
43977    break
43978
43979      elif test -r "$i/include/c-client/c-client.h"; then
43980
43981printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
43982
43983    IMAP_DIR=$i
43984    IMAP_INC_DIR=$i/include/c-client
43985    break
43986  elif test -r "$i/include/c-client/rfc822.h"; then
43987    IMAP_DIR=$i;
43988    IMAP_INC_DIR=$i/include/c-client
43989    break
43990
43991      elif test -r "$i/include/imap/c-client.h"; then
43992
43993printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
43994
43995    IMAP_DIR=$i
43996    IMAP_INC_DIR=$i/include/imap
43997    break
43998  elif test -r "$i/include/imap/rfc822.h"; then
43999    IMAP_DIR=$i;
44000    IMAP_INC_DIR=$i/include/imap
44001    break
44002
44003      elif test -r "$i/include/c-client.h"; then
44004
44005printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
44006
44007    IMAP_DIR=$i
44008    IMAP_INC_DIR=$i/include
44009    break
44010  elif test -r "$i/include/rfc822.h"; then
44011    IMAP_DIR=$i;
44012    IMAP_INC_DIR=$i/include
44013    break
44014
44015      elif test -r "$i/imap/c-client.h"; then
44016
44017printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
44018
44019    IMAP_DIR=$i
44020    IMAP_INC_DIR=$i/imap
44021    break
44022  elif test -r "$i/imap/rfc822.h"; then
44023    IMAP_DIR=$i;
44024    IMAP_INC_DIR=$i/imap
44025    break
44026
44027      elif test -r "$i/c-client/c-client.h"; then
44028
44029printf "%s\n" "#define HAVE_IMAP2000 1" >>confdefs.h
44030
44031    IMAP_DIR=$i
44032    IMAP_INC_DIR=$i/c-client
44033    break
44034  elif test -r "$i/c-client/rfc822.h"; then
44035    IMAP_DIR=$i;
44036    IMAP_INC_DIR=$i/c-client
44037    break
44038
44039      fi
44040    done
44041
44042        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44043/* end confdefs.h.  */
44044#include <$IMAP_INC_DIR/mail.h>
44045
44046_ACEOF
44047if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
44048  $EGREP "mail_fetch_overview_sequence" >/dev/null 2>&1
44049then :
44050
44051
44052printf "%s\n" "#define HAVE_IMAP2004 1" >>confdefs.h
44053
44054
44055fi
44056rm -rf conftest*
44057
44058
44059        old_CFLAGS=$CFLAGS
44060    CFLAGS="-I$IMAP_INC_DIR"
44061    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for utf8_mime2text signature" >&5
44062printf %s "checking for utf8_mime2text signature... " >&6; }
44063if test ${ac_cv_utf8_mime2text+y}
44064then :
44065  printf %s "(cached) " >&6
44066else $as_nop
44067  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44068/* end confdefs.h.  */
44069
44070#include <stdio.h>
44071#include <c-client.h>
44072
44073int
44074main (void)
44075{
44076
44077        SIZEDTEXT *src, *dst;
44078        utf8_mime2text(src, dst);
44079
44080  ;
44081  return 0;
44082}
44083_ACEOF
44084if ac_fn_c_try_compile "$LINENO"
44085then :
44086
44087        ac_cv_utf8_mime2text=old
44088
44089else $as_nop
44090
44091        ac_cv_utf8_mime2text=new
44092
44093fi
44094rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
44095
44096fi
44097{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_utf8_mime2text" >&5
44098printf "%s\n" "$ac_cv_utf8_mime2text" >&6; }
44099    if test "$ac_cv_utf8_mime2text" = "new"; then
44100
44101printf "%s\n" "#define HAVE_NEW_MIME2TEXT 1" >>confdefs.h
44102
44103    fi
44104    CFLAGS=$old_CFLAGS
44105
44106    old_CFLAGS=$CFLAGS
44107    CFLAGS="-I$IMAP_INC_DIR"
44108    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for U8T_DECOMPOSE" >&5
44109printf %s "checking for U8T_DECOMPOSE... " >&6; }
44110if test ${ac_cv_u8t_decompose+y}
44111then :
44112  printf %s "(cached) " >&6
44113else $as_nop
44114  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44115/* end confdefs.h.  */
44116
44117#include <c-client.h>
44118
44119int
44120main (void)
44121{
44122
44123         int i = U8T_CANONICAL;
44124
44125  ;
44126  return 0;
44127}
44128_ACEOF
44129if ac_fn_c_try_compile "$LINENO"
44130then :
44131
44132         ac_cv_u8t_decompose=yes
44133
44134else $as_nop
44135
44136         ac_cv_u8t_decompose=no
44137
44138fi
44139rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
44140
44141fi
44142{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_u8t_decompose" >&5
44143printf "%s\n" "$ac_cv_u8t_decompose" >&6; }
44144    CFLAGS=$old_CFLAGS
44145
44146    if test "$ac_cv_u8t_decompose" = "no" && test "$ac_cv_utf8_mime2text" = "new"; then
44147		as_fn_error $? "utf8_mime2text() has new signature, but U8T_CANONICAL is missing. This should not happen. Check config.log for additional information." "$LINENO" 5
44148    fi
44149    if test "$ac_cv_u8t_decompose" = "yes" && test "$ac_cv_utf8_mime2text" = "old"; then
44150		as_fn_error $? "utf8_mime2text() has old signature, but U8T_CANONICAL is present. This should not happen. Check config.log for additional information." "$LINENO" 5
44151    fi
44152
44153        old_CPPFLAGS=$CPPFLAGS
44154    CPPFLAGS=-I$IMAP_INC_DIR
44155    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44156/* end confdefs.h.  */
44157
44158#include "imap4r1.h"
44159#if defined(IMAPSSLPORT)
44160      this_is_true
44161#endif
44162
44163_ACEOF
44164if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
44165  $EGREP "this_is_true" >/dev/null 2>&1
44166then :
44167
44168
44169printf "%s\n" "#define HAVE_IMAP2001 1" >>confdefs.h
44170
44171
44172fi
44173rm -rf conftest*
44174
44175    CPPFLAGS=$old_CPPFLAGS
44176
44177
44178  save_old_LDFLAGS=$LDFLAGS
44179  ac_stuff=""
44180
44181  save_ext_shared=$ext_shared
44182  ext_shared=yes
44183
44184  for ac_i in $ac_stuff; do
44185    case $ac_i in
44186    -pthread)
44187      if test "$ext_shared" = "yes"; then
44188        LDFLAGS="$LDFLAGS -pthread"
44189      else
44190
44191
44192  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44193
44194  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
44195  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44196    eval "EXTRA_LDFLAGS$unique=set"
44197    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
44198  fi
44199
44200
44201
44202  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44203
44204  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
44205  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44206    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
44207    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
44208  fi
44209
44210      fi
44211    ;;
44212    -l*)
44213      ac_ii=`echo $ac_i|cut -c 3-`
44214
44215
44216  case $ac_ii in
44217  c|c_r) ;;
44218  *)
44219    if test "$ext_shared" = "yes"; then
44220        LDFLAGS="$LDFLAGS -l$ac_ii"
44221    else
44222
44223
44224  case $ac_ii in
44225  c|c_r) ;;
44226  *)
44227      LIBS="$LIBS -l$ac_ii"
44228   ;;
44229  esac
44230
44231
44232    fi
44233   ;;
44234  esac
44235
44236
44237    ;;
44238    -L*)
44239      ac_ii=`echo $ac_i|cut -c 3-`
44240
44241  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
44242
44243  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
44244    ai_p=$ac_ii
44245  else
44246
44247    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
44248
44249    ep_realdir=`(cd "$ep_dir" && pwd)`
44250    ai_p="$ep_realdir"/`basename "$ac_ii"`
44251  fi
44252
44253
44254      if test "$ext_shared" = "yes"; then
44255        LDFLAGS="-L$ai_p $LDFLAGS"
44256        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
44257      else
44258
44259
44260
44261  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44262
44263  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
44264  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44265    eval "LIBPATH$unique=set"
44266
44267    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
44268    LDFLAGS="$LDFLAGS -L$ai_p"
44269    PHP_RPATHS="$PHP_RPATHS $ai_p"
44270
44271  fi
44272
44273
44274      fi
44275
44276  fi
44277
44278    ;;
44279    esac
44280  done
44281
44282  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pam_start in -lpam" >&5
44283printf %s "checking for pam_start in -lpam... " >&6; }
44284if test ${ac_cv_lib_pam_pam_start+y}
44285then :
44286  printf %s "(cached) " >&6
44287else $as_nop
44288  ac_check_lib_save_LIBS=$LIBS
44289LIBS="-lpam  $LIBS"
44290cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44291/* end confdefs.h.  */
44292
44293/* Override any GCC internal prototype to avoid an error.
44294   Use char because int might match the return type of a GCC
44295   builtin and then its argument prototype would still apply.  */
44296char pam_start ();
44297int
44298main (void)
44299{
44300return pam_start ();
44301  ;
44302  return 0;
44303}
44304_ACEOF
44305if ac_fn_c_try_link "$LINENO"
44306then :
44307  ac_cv_lib_pam_pam_start=yes
44308else $as_nop
44309  ac_cv_lib_pam_pam_start=no
44310fi
44311rm -f core conftest.err conftest.$ac_objext conftest.beam \
44312    conftest$ac_exeext conftest.$ac_ext
44313LIBS=$ac_check_lib_save_LIBS
44314fi
44315{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_start" >&5
44316printf "%s\n" "$ac_cv_lib_pam_pam_start" >&6; }
44317if test "x$ac_cv_lib_pam_pam_start" = xyes
44318then :
44319
44320    LDFLAGS=$save_old_LDFLAGS
44321    ext_shared=$save_ext_shared
44322
44323
44324
44325  case pam in
44326  c|c_r) ;;
44327  *)
44328    if test "$ext_shared" = "yes"; then
44329        IMAP_SHARED_LIBADD="-lpam $IMAP_SHARED_LIBADD"
44330    else
44331
44332
44333  case pam in
44334  c|c_r) ;;
44335  *)
44336      LIBS="-lpam $LIBS"
44337   ;;
44338  esac
44339
44340
44341    fi
44342   ;;
44343  esac
44344
44345
44346
44347printf "%s\n" "#define HAVE_LIBPAM 1" >>confdefs.h
44348
44349
44350
44351else $as_nop
44352
44353    LDFLAGS=$save_old_LDFLAGS
44354    ext_shared=$save_ext_shared
44355    unset ac_cv_lib_pam_pam_start
44356
44357
44358fi
44359
44360
44361
44362  save_old_LDFLAGS=$LDFLAGS
44363  ac_stuff=""
44364
44365  save_ext_shared=$ext_shared
44366  ext_shared=yes
44367
44368  for ac_i in $ac_stuff; do
44369    case $ac_i in
44370    -pthread)
44371      if test "$ext_shared" = "yes"; then
44372        LDFLAGS="$LDFLAGS -pthread"
44373      else
44374
44375
44376  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44377
44378  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
44379  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44380    eval "EXTRA_LDFLAGS$unique=set"
44381    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
44382  fi
44383
44384
44385
44386  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44387
44388  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
44389  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44390    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
44391    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
44392  fi
44393
44394      fi
44395    ;;
44396    -l*)
44397      ac_ii=`echo $ac_i|cut -c 3-`
44398
44399
44400  case $ac_ii in
44401  c|c_r) ;;
44402  *)
44403    if test "$ext_shared" = "yes"; then
44404        LDFLAGS="$LDFLAGS -l$ac_ii"
44405    else
44406
44407
44408  case $ac_ii in
44409  c|c_r) ;;
44410  *)
44411      LIBS="$LIBS -l$ac_ii"
44412   ;;
44413  esac
44414
44415
44416    fi
44417   ;;
44418  esac
44419
44420
44421    ;;
44422    -L*)
44423      ac_ii=`echo $ac_i|cut -c 3-`
44424
44425  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
44426
44427  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
44428    ai_p=$ac_ii
44429  else
44430
44431    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
44432
44433    ep_realdir=`(cd "$ep_dir" && pwd)`
44434    ai_p="$ep_realdir"/`basename "$ac_ii"`
44435  fi
44436
44437
44438      if test "$ext_shared" = "yes"; then
44439        LDFLAGS="-L$ai_p $LDFLAGS"
44440        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
44441      else
44442
44443
44444
44445  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44446
44447  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
44448  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44449    eval "LIBPATH$unique=set"
44450
44451    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
44452    LDFLAGS="$LDFLAGS -L$ai_p"
44453    PHP_RPATHS="$PHP_RPATHS $ai_p"
44454
44455  fi
44456
44457
44458      fi
44459
44460  fi
44461
44462    ;;
44463    esac
44464  done
44465
44466  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5
44467printf %s "checking for crypt in -lcrypt... " >&6; }
44468if test ${ac_cv_lib_crypt_crypt+y}
44469then :
44470  printf %s "(cached) " >&6
44471else $as_nop
44472  ac_check_lib_save_LIBS=$LIBS
44473LIBS="-lcrypt  $LIBS"
44474cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44475/* end confdefs.h.  */
44476
44477/* Override any GCC internal prototype to avoid an error.
44478   Use char because int might match the return type of a GCC
44479   builtin and then its argument prototype would still apply.  */
44480char crypt ();
44481int
44482main (void)
44483{
44484return crypt ();
44485  ;
44486  return 0;
44487}
44488_ACEOF
44489if ac_fn_c_try_link "$LINENO"
44490then :
44491  ac_cv_lib_crypt_crypt=yes
44492else $as_nop
44493  ac_cv_lib_crypt_crypt=no
44494fi
44495rm -f core conftest.err conftest.$ac_objext conftest.beam \
44496    conftest$ac_exeext conftest.$ac_ext
44497LIBS=$ac_check_lib_save_LIBS
44498fi
44499{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
44500printf "%s\n" "$ac_cv_lib_crypt_crypt" >&6; }
44501if test "x$ac_cv_lib_crypt_crypt" = xyes
44502then :
44503
44504    LDFLAGS=$save_old_LDFLAGS
44505    ext_shared=$save_ext_shared
44506
44507
44508
44509  case crypt in
44510  c|c_r) ;;
44511  *)
44512    if test "$ext_shared" = "yes"; then
44513        IMAP_SHARED_LIBADD="-lcrypt $IMAP_SHARED_LIBADD"
44514    else
44515
44516
44517  case crypt in
44518  c|c_r) ;;
44519  *)
44520      LIBS="-lcrypt $LIBS"
44521   ;;
44522  esac
44523
44524
44525    fi
44526   ;;
44527  esac
44528
44529
44530
44531printf "%s\n" "#define HAVE_LIBCRYPT 1" >>confdefs.h
44532
44533
44534
44535else $as_nop
44536
44537    LDFLAGS=$save_old_LDFLAGS
44538    ext_shared=$save_ext_shared
44539    unset ac_cv_lib_crypt_crypt
44540
44541
44542fi
44543
44544
44545
44546  if test -z "$IMAP_DIR" || echo "$IMAP_DIR" | grep '^/' >/dev/null ; then
44547    IMAP_DIR=$IMAP_DIR
44548  else
44549
44550    ep_dir=`echo $IMAP_DIR|$SED 's%/*[^/][^/]*/*$%%'`
44551
44552    ep_realdir=`(cd "$ep_dir" && pwd)`
44553    IMAP_DIR="$ep_realdir"/`basename "$IMAP_DIR"`
44554  fi
44555
44556
44557    if test -z "$IMAP_DIR"; then
44558      as_fn_error $? "Cannot find rfc822.h. Please check your c-client installation." "$LINENO" 5
44559    fi
44560
44561    if test ! -r "$IMAP_DIR/c-client/libc-client.a" && test -r "$IMAP_DIR/c-client/c-client.a" ; then
44562      ln -s "$IMAP_DIR/c-client/c-client.a" "$IMAP_DIR/c-client/libc-client.a" >/dev/null 2>&1
44563    elif test ! -r "$IMAP_DIR/$PHP_LIBDIR/libc-client.a" && test -r "$IMAP_DIR/$PHP_LIBDIR/c-client.a"; then
44564      ln -s "$IMAP_DIR/$PHP_LIBDIR/c-client.a" "$IMAP_DIR/$PHP_LIBDIR/libc-client.a" >/dev/null 2>&1
44565    fi
44566
44567    for lib in c-client4 c-client imap; do
44568      IMAP_LIB=$lib
44569
44570  str="$IMAP_DIR/$PHP_LIBDIR/lib$lib.*"
44571  for i in `echo $str`; do
44572    test -r $i && IMAP_LIBDIR=$IMAP_DIR/$PHP_LIBDIR && break 2
44573  done
44574
44575
44576  str="$IMAP_DIR/c-client/lib$lib.*"
44577  for i in `echo $str`; do
44578    test -r $i && IMAP_LIBDIR=$IMAP_DIR/c-client && break 2
44579  done
44580
44581    done
44582
44583    if test -z "$IMAP_LIBDIR"; then
44584      as_fn_error $? "Cannot find imap library (libc-client.a). Please check your c-client installation." "$LINENO" 5
44585    fi
44586
44587
44588  if test "$IMAP_INC_DIR" != "/usr/include"; then
44589
44590  if test -z "$IMAP_INC_DIR" || echo "$IMAP_INC_DIR" | grep '^/' >/dev/null ; then
44591    ai_p=$IMAP_INC_DIR
44592  else
44593
44594    ep_dir=`echo $IMAP_INC_DIR|$SED 's%/*[^/][^/]*/*$%%'`
44595
44596    ep_realdir=`(cd "$ep_dir" && pwd)`
44597    ai_p="$ep_realdir"/`basename "$IMAP_INC_DIR"`
44598  fi
44599
44600
44601
44602  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44603
44604  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
44605  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44606    eval "INCLUDEPATH$unique=set"
44607
44608      if test ""; then
44609        INCLUDES="-I$ai_p $INCLUDES"
44610      else
44611        INCLUDES="$INCLUDES -I$ai_p"
44612      fi
44613
44614  fi
44615
44616  fi
44617
44618
44619
44620  case $IMAP_LIB in
44621  c|c_r) ;;
44622  *)
44623    if test "$ext_shared" = "yes"; then
44624        IMAP_SHARED_LIBADD="-l$IMAP_LIB $IMAP_SHARED_LIBADD"
44625    else
44626
44627
44628  case $IMAP_LIB in
44629  c|c_r) ;;
44630  *)
44631      DLIBS="-l$IMAP_LIB $DLIBS"
44632   ;;
44633  esac
44634
44635
44636    fi
44637   ;;
44638  esac
44639
44640
44641
44642  if test "$IMAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$IMAP_LIBDIR" != "/usr/lib"; then
44643
44644  if test -z "$IMAP_LIBDIR" || echo "$IMAP_LIBDIR" | grep '^/' >/dev/null ; then
44645    ai_p=$IMAP_LIBDIR
44646  else
44647
44648    ep_dir=`echo $IMAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
44649
44650    ep_realdir=`(cd "$ep_dir" && pwd)`
44651    ai_p="$ep_realdir"/`basename "$IMAP_LIBDIR"`
44652  fi
44653
44654
44655      if test "$ext_shared" = "yes"; then
44656        IMAP_SHARED_LIBADD="-L$ai_p $IMAP_SHARED_LIBADD"
44657        test -n "$ld_runpath_switch" && IMAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $IMAP_SHARED_LIBADD"
44658      else
44659
44660
44661
44662  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44663
44664  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
44665  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44666    eval "LIBPATH$unique=set"
44667
44668    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
44669    LDFLAGS="$LDFLAGS -L$ai_p"
44670    PHP_RPATHS="$PHP_RPATHS $ai_p"
44671
44672  fi
44673
44674
44675      fi
44676
44677  fi
44678
44679
44680  if test "$PHP_KERBEROS" != "no"; then
44681
44682pkg_failed=no
44683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for krb5-gssapi krb5" >&5
44684printf %s "checking for krb5-gssapi krb5... " >&6; }
44685
44686if test -n "$KERBEROS_CFLAGS"; then
44687    pkg_cv_KERBEROS_CFLAGS="$KERBEROS_CFLAGS"
44688 elif test -n "$PKG_CONFIG"; then
44689    if test -n "$PKG_CONFIG" && \
44690    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"krb5-gssapi krb5\""; } >&5
44691  ($PKG_CONFIG --exists --print-errors "krb5-gssapi krb5") 2>&5
44692  ac_status=$?
44693  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44694  test $ac_status = 0; }; then
44695  pkg_cv_KERBEROS_CFLAGS=`$PKG_CONFIG --cflags "krb5-gssapi krb5" 2>/dev/null`
44696		      test "x$?" != "x0" && pkg_failed=yes
44697else
44698  pkg_failed=yes
44699fi
44700 else
44701    pkg_failed=untried
44702fi
44703if test -n "$KERBEROS_LIBS"; then
44704    pkg_cv_KERBEROS_LIBS="$KERBEROS_LIBS"
44705 elif test -n "$PKG_CONFIG"; then
44706    if test -n "$PKG_CONFIG" && \
44707    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"krb5-gssapi krb5\""; } >&5
44708  ($PKG_CONFIG --exists --print-errors "krb5-gssapi krb5") 2>&5
44709  ac_status=$?
44710  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44711  test $ac_status = 0; }; then
44712  pkg_cv_KERBEROS_LIBS=`$PKG_CONFIG --libs "krb5-gssapi krb5" 2>/dev/null`
44713		      test "x$?" != "x0" && pkg_failed=yes
44714else
44715  pkg_failed=yes
44716fi
44717 else
44718    pkg_failed=untried
44719fi
44720
44721
44722
44723if test $pkg_failed = yes; then
44724        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
44725printf "%s\n" "no" >&6; }
44726
44727if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
44728        _pkg_short_errors_supported=yes
44729else
44730        _pkg_short_errors_supported=no
44731fi
44732        if test $_pkg_short_errors_supported = yes; then
44733	        KERBEROS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "krb5-gssapi krb5" 2>&1`
44734        else
44735	        KERBEROS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "krb5-gssapi krb5" 2>&1`
44736        fi
44737	# Put the nasty error message in config.log where it belongs
44738	echo "$KERBEROS_PKG_ERRORS" >&5
44739
44740	as_fn_error $? "Package requirements (krb5-gssapi krb5) were not met:
44741
44742$KERBEROS_PKG_ERRORS
44743
44744Consider adjusting the PKG_CONFIG_PATH environment variable if you
44745installed software in a non-standard prefix.
44746
44747Alternatively, you may set the environment variables KERBEROS_CFLAGS
44748and KERBEROS_LIBS to avoid the need to call pkg-config.
44749See the pkg-config man page for more details." "$LINENO" 5
44750elif test $pkg_failed = untried; then
44751        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
44752printf "%s\n" "no" >&6; }
44753	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
44754printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
44755as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
44756is in your PATH or set the PKG_CONFIG environment variable to the full
44757path to pkg-config.
44758
44759Alternatively, you may set the environment variables KERBEROS_CFLAGS
44760and KERBEROS_LIBS to avoid the need to call pkg-config.
44761See the pkg-config man page for more details.
44762
44763To get pkg-config, see <http://pkg-config.freedesktop.org/>.
44764See \`config.log' for more details" "$LINENO" 5; }
44765else
44766	KERBEROS_CFLAGS=$pkg_cv_KERBEROS_CFLAGS
44767	KERBEROS_LIBS=$pkg_cv_KERBEROS_LIBS
44768        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
44769printf "%s\n" "yes" >&6; }
44770
44771fi
44772
44773
44774  for ac_i in $KERBEROS_CFLAGS; do
44775    case $ac_i in
44776    -I*)
44777      ac_ii=`echo $ac_i|cut -c 3-`
44778
44779  if test "$ac_ii" != "/usr/include"; then
44780
44781  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
44782    ai_p=$ac_ii
44783  else
44784
44785    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
44786
44787    ep_realdir=`(cd "$ep_dir" && pwd)`
44788    ai_p="$ep_realdir"/`basename "$ac_ii"`
44789  fi
44790
44791
44792
44793  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44794
44795  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
44796  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44797    eval "INCLUDEPATH$unique=set"
44798
44799      if test ""; then
44800        INCLUDES="-I$ai_p $INCLUDES"
44801      else
44802        INCLUDES="$INCLUDES -I$ai_p"
44803      fi
44804
44805  fi
44806
44807  fi
44808
44809    ;;
44810    esac
44811  done
44812
44813
44814  for ac_i in $KERBEROS_LIBS; do
44815    case $ac_i in
44816    -pthread)
44817      if test "$ext_shared" = "yes"; then
44818        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -pthread"
44819      else
44820
44821
44822  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44823
44824  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
44825  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44826    eval "EXTRA_LDFLAGS$unique=set"
44827    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
44828  fi
44829
44830
44831
44832  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
44833
44834  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
44835  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44836    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
44837    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
44838  fi
44839
44840      fi
44841    ;;
44842    -l*)
44843      ac_ii=`echo $ac_i|cut -c 3-`
44844
44845
44846  case $ac_ii in
44847  c|c_r) ;;
44848  *)
44849    if test "$ext_shared" = "yes"; then
44850        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -l$ac_ii"
44851    else
44852
44853
44854  case $ac_ii in
44855  c|c_r) ;;
44856  *)
44857      LIBS="$LIBS -l$ac_ii"
44858   ;;
44859  esac
44860
44861
44862    fi
44863   ;;
44864  esac
44865
44866
44867    ;;
44868    -L*)
44869      ac_ii=`echo $ac_i|cut -c 3-`
44870
44871  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
44872
44873  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
44874    ai_p=$ac_ii
44875  else
44876
44877    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
44878
44879    ep_realdir=`(cd "$ep_dir" && pwd)`
44880    ai_p="$ep_realdir"/`basename "$ac_ii"`
44881  fi
44882
44883
44884      if test "$ext_shared" = "yes"; then
44885        IMAP_SHARED_LIBADD="-L$ai_p $IMAP_SHARED_LIBADD"
44886        test -n "$ld_runpath_switch" && IMAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $IMAP_SHARED_LIBADD"
44887      else
44888
44889
44890
44891  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
44892
44893  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
44894  if test -n "$unique" && test "`eval $cmd`" = "" ; then
44895    eval "LIBPATH$unique=set"
44896
44897    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
44898    LDFLAGS="$LDFLAGS -L$ai_p"
44899    PHP_RPATHS="$PHP_RPATHS $ai_p"
44900
44901  fi
44902
44903
44904      fi
44905
44906  fi
44907
44908    ;;
44909    esac
44910  done
44911
44912
44913
44914printf "%s\n" "#define HAVE_IMAP_KRB 1" >>confdefs.h
44915
44916  else
44917    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44918/* end confdefs.h.  */
44919#include <$IMAP_INC_DIR/linkage.h>
44920
44921_ACEOF
44922if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
44923  $EGREP "auth_gss" >/dev/null 2>&1
44924then :
44925
44926      as_fn_error $? "This c-client library is built with Kerberos support.
44927
44928      Add --with-kerberos to your configure line. Check config.log for details.
44929      " "$LINENO" 5
44930
44931fi
44932rm -rf conftest*
44933
44934  fi
44935
44936
44937  if test "$PHP_IMAP_SSL" != "no"; then
44938    if test "$PHP_OPENSSL" = ""; then
44939      PHP_OPENSSL='no'
44940    fi
44941
44942  found_openssl=no
44943
44944
44945pkg_failed=no
44946{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl >= 1.0.2" >&5
44947printf %s "checking for openssl >= 1.0.2... " >&6; }
44948
44949if test -n "$OPENSSL_CFLAGS"; then
44950    pkg_cv_OPENSSL_CFLAGS="$OPENSSL_CFLAGS"
44951 elif test -n "$PKG_CONFIG"; then
44952    if test -n "$PKG_CONFIG" && \
44953    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
44954  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
44955  ac_status=$?
44956  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44957  test $ac_status = 0; }; then
44958  pkg_cv_OPENSSL_CFLAGS=`$PKG_CONFIG --cflags "openssl >= 1.0.2" 2>/dev/null`
44959		      test "x$?" != "x0" && pkg_failed=yes
44960else
44961  pkg_failed=yes
44962fi
44963 else
44964    pkg_failed=untried
44965fi
44966if test -n "$OPENSSL_LIBS"; then
44967    pkg_cv_OPENSSL_LIBS="$OPENSSL_LIBS"
44968 elif test -n "$PKG_CONFIG"; then
44969    if test -n "$PKG_CONFIG" && \
44970    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
44971  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
44972  ac_status=$?
44973  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44974  test $ac_status = 0; }; then
44975  pkg_cv_OPENSSL_LIBS=`$PKG_CONFIG --libs "openssl >= 1.0.2" 2>/dev/null`
44976		      test "x$?" != "x0" && pkg_failed=yes
44977else
44978  pkg_failed=yes
44979fi
44980 else
44981    pkg_failed=untried
44982fi
44983
44984
44985
44986if test $pkg_failed = yes; then
44987        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
44988printf "%s\n" "no" >&6; }
44989
44990if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
44991        _pkg_short_errors_supported=yes
44992else
44993        _pkg_short_errors_supported=no
44994fi
44995        if test $_pkg_short_errors_supported = yes; then
44996	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
44997        else
44998	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
44999        fi
45000	# Put the nasty error message in config.log where it belongs
45001	echo "$OPENSSL_PKG_ERRORS" >&5
45002
45003	as_fn_error $? "Package requirements (openssl >= 1.0.2) were not met:
45004
45005$OPENSSL_PKG_ERRORS
45006
45007Consider adjusting the PKG_CONFIG_PATH environment variable if you
45008installed software in a non-standard prefix.
45009
45010Alternatively, you may set the environment variables OPENSSL_CFLAGS
45011and OPENSSL_LIBS to avoid the need to call pkg-config.
45012See the pkg-config man page for more details." "$LINENO" 5
45013elif test $pkg_failed = untried; then
45014        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
45015printf "%s\n" "no" >&6; }
45016	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
45017printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
45018as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
45019is in your PATH or set the PKG_CONFIG environment variable to the full
45020path to pkg-config.
45021
45022Alternatively, you may set the environment variables OPENSSL_CFLAGS
45023and OPENSSL_LIBS to avoid the need to call pkg-config.
45024See the pkg-config man page for more details.
45025
45026To get pkg-config, see <http://pkg-config.freedesktop.org/>.
45027See \`config.log' for more details" "$LINENO" 5; }
45028else
45029	OPENSSL_CFLAGS=$pkg_cv_OPENSSL_CFLAGS
45030	OPENSSL_LIBS=$pkg_cv_OPENSSL_LIBS
45031        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
45032printf "%s\n" "yes" >&6; }
45033	found_openssl=yes
45034fi
45035
45036  if test "$found_openssl" = "yes"; then
45037
45038  for ac_i in $OPENSSL_LIBS; do
45039    case $ac_i in
45040    -pthread)
45041      if test "$ext_shared" = "yes"; then
45042        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -pthread"
45043      else
45044
45045
45046  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
45047
45048  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
45049  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45050    eval "EXTRA_LDFLAGS$unique=set"
45051    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
45052  fi
45053
45054
45055
45056  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
45057
45058  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
45059  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45060    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
45061    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
45062  fi
45063
45064      fi
45065    ;;
45066    -l*)
45067      ac_ii=`echo $ac_i|cut -c 3-`
45068
45069
45070  case $ac_ii in
45071  c|c_r) ;;
45072  *)
45073    if test "$ext_shared" = "yes"; then
45074        IMAP_SHARED_LIBADD="$IMAP_SHARED_LIBADD -l$ac_ii"
45075    else
45076
45077
45078  case $ac_ii in
45079  c|c_r) ;;
45080  *)
45081      LIBS="$LIBS -l$ac_ii"
45082   ;;
45083  esac
45084
45085
45086    fi
45087   ;;
45088  esac
45089
45090
45091    ;;
45092    -L*)
45093      ac_ii=`echo $ac_i|cut -c 3-`
45094
45095  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
45096
45097  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
45098    ai_p=$ac_ii
45099  else
45100
45101    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
45102
45103    ep_realdir=`(cd "$ep_dir" && pwd)`
45104    ai_p="$ep_realdir"/`basename "$ac_ii"`
45105  fi
45106
45107
45108      if test "$ext_shared" = "yes"; then
45109        IMAP_SHARED_LIBADD="-L$ai_p $IMAP_SHARED_LIBADD"
45110        test -n "$ld_runpath_switch" && IMAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $IMAP_SHARED_LIBADD"
45111      else
45112
45113
45114
45115  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
45116
45117  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
45118  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45119    eval "LIBPATH$unique=set"
45120
45121    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
45122    LDFLAGS="$LDFLAGS -L$ai_p"
45123    PHP_RPATHS="$PHP_RPATHS $ai_p"
45124
45125  fi
45126
45127
45128      fi
45129
45130  fi
45131
45132    ;;
45133    esac
45134  done
45135
45136
45137  for ac_i in $OPENSSL_CFLAGS; do
45138    case $ac_i in
45139    -I*)
45140      ac_ii=`echo $ac_i|cut -c 3-`
45141
45142  if test "$ac_ii" != "/usr/include"; then
45143
45144  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
45145    ai_p=$ac_ii
45146  else
45147
45148    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
45149
45150    ep_realdir=`(cd "$ep_dir" && pwd)`
45151    ai_p="$ep_realdir"/`basename "$ac_ii"`
45152  fi
45153
45154
45155
45156  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
45157
45158  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
45159  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45160    eval "INCLUDEPATH$unique=set"
45161
45162      if test ""; then
45163        INCLUDES="-I$ai_p $INCLUDES"
45164      else
45165        INCLUDES="$INCLUDES -I$ai_p"
45166      fi
45167
45168  fi
45169
45170  fi
45171
45172    ;;
45173    esac
45174  done
45175
45176
45177
45178printf "%s\n" "#define HAVE_IMAP_SSL 1" >>confdefs.h
45179
45180
45181else
45182      as_fn_error $? "OpenSSL libraries not found.
45183
45184      Check whether openssl is on your PKG_CONFIG_PATH and the output in config.log)
45185      " "$LINENO" 5
45186
45187  fi
45188
45189  elif test -f "$IMAP_INC_DIR/linkage.c"; then
45190    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45191/* end confdefs.h.  */
45192#include <$IMAP_INC_DIR/linkage.c>
45193
45194_ACEOF
45195if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
45196  $EGREP "ssl_onceonlyinit" >/dev/null 2>&1
45197then :
45198
45199      as_fn_error $? "This c-client library is built with SSL support.
45200
45201      Add --with-imap-ssl to your configure line. Check config.log for details.
45202      " "$LINENO" 5
45203
45204fi
45205rm -rf conftest*
45206
45207  fi
45208
45209
45210        TST_LIBS="$DLIBS $IMAP_SHARED_LIBADD"
45211
45212
45213
45214  old_LIBS=$LIBS
45215  LIBS="$TST_LIBS $LIBS"
45216  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45217/* end confdefs.h.  */
45218
45219
45220
45221#if defined(__GNUC__) && __GNUC__ >= 4
45222# define PHP_IMAP_EXPORT __attribute__ ((visibility("default")))
45223#else
45224# define PHP_IMAP_EXPORT
45225#endif
45226
45227    PHP_IMAP_EXPORT void mm_log(void){}
45228    PHP_IMAP_EXPORT void mm_dlog(void){}
45229    PHP_IMAP_EXPORT void mm_flags(void){}
45230    PHP_IMAP_EXPORT void mm_fatal(void){}
45231    PHP_IMAP_EXPORT void mm_critical(void){}
45232    PHP_IMAP_EXPORT void mm_nocritical(void){}
45233    PHP_IMAP_EXPORT void mm_notify(void){}
45234    PHP_IMAP_EXPORT void mm_login(void){}
45235    PHP_IMAP_EXPORT void mm_diskerror(void){}
45236    PHP_IMAP_EXPORT void mm_status(void){}
45237    PHP_IMAP_EXPORT void mm_lsub(void){}
45238    PHP_IMAP_EXPORT void mm_list(void){}
45239    PHP_IMAP_EXPORT void mm_exists(void){}
45240    PHP_IMAP_EXPORT void mm_searched(void){}
45241    PHP_IMAP_EXPORT void mm_expunged(void){}
45242
45243    char auth_gssapi_valid();
45244    int main() {
45245      auth_gssapi_valid();
45246      return 0;
45247    }
45248
45249_ACEOF
45250if ac_fn_c_try_link "$LINENO"
45251then :
45252
45253    LIBS=$old_LIBS
45254
45255
45256printf "%s\n" "#define HAVE_IMAP_AUTH_GSS 1" >>confdefs.h
45257
45258
45259
45260else $as_nop
45261
45262    LIBS=$old_LIBS
45263
45264
45265fi
45266rm -f core conftest.err conftest.$ac_objext conftest.beam \
45267    conftest$ac_exeext conftest.$ac_ext
45268
45269
45270
45271
45272
45273  old_LIBS=$LIBS
45274  LIBS="$TST_LIBS $LIBS"
45275  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45276/* end confdefs.h.  */
45277
45278
45279      char utf8_to_mutf7_php(){ return utf8_to_mutf7(""); }
45280
45281
45282#if defined(__GNUC__) && __GNUC__ >= 4
45283# define PHP_IMAP_EXPORT __attribute__ ((visibility("default")))
45284#else
45285# define PHP_IMAP_EXPORT
45286#endif
45287
45288    PHP_IMAP_EXPORT void mm_log(void){}
45289    PHP_IMAP_EXPORT void mm_dlog(void){}
45290    PHP_IMAP_EXPORT void mm_flags(void){}
45291    PHP_IMAP_EXPORT void mm_fatal(void){}
45292    PHP_IMAP_EXPORT void mm_critical(void){}
45293    PHP_IMAP_EXPORT void mm_nocritical(void){}
45294    PHP_IMAP_EXPORT void mm_notify(void){}
45295    PHP_IMAP_EXPORT void mm_login(void){}
45296    PHP_IMAP_EXPORT void mm_diskerror(void){}
45297    PHP_IMAP_EXPORT void mm_status(void){}
45298    PHP_IMAP_EXPORT void mm_lsub(void){}
45299    PHP_IMAP_EXPORT void mm_list(void){}
45300    PHP_IMAP_EXPORT void mm_exists(void){}
45301    PHP_IMAP_EXPORT void mm_searched(void){}
45302    PHP_IMAP_EXPORT void mm_expunged(void){}
45303
45304    char utf8_to_mutf7_php();
45305    int main() {
45306      utf8_to_mutf7_php();
45307      return 0;
45308    }
45309
45310_ACEOF
45311if ac_fn_c_try_link "$LINENO"
45312then :
45313
45314    LIBS=$old_LIBS
45315
45316
45317printf "%s\n" "#define HAVE_IMAP_MUTF7 1" >>confdefs.h
45318
45319
45320
45321else $as_nop
45322
45323    LIBS=$old_LIBS
45324
45325
45326fi
45327rm -f core conftest.err conftest.$ac_objext conftest.beam \
45328    conftest$ac_exeext conftest.$ac_ext
45329
45330
45331
45332    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether rfc822_output_address_list function present" >&5
45333printf %s "checking whether rfc822_output_address_list function present... " >&6; }
45334
45335  old_LIBS=$LIBS
45336  LIBS="
45337      $TST_LIBS
45338     $LIBS"
45339  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45340/* end confdefs.h.  */
45341
45342
45343#if defined(__GNUC__) && __GNUC__ >= 4
45344# define PHP_IMAP_EXPORT __attribute__ ((visibility("default")))
45345#else
45346# define PHP_IMAP_EXPORT
45347#endif
45348
45349      PHP_IMAP_EXPORT void mm_log(void){}
45350      PHP_IMAP_EXPORT void mm_dlog(void){}
45351      PHP_IMAP_EXPORT void mm_flags(void){}
45352      PHP_IMAP_EXPORT void mm_fatal(void){}
45353      PHP_IMAP_EXPORT void mm_critical(void){}
45354      PHP_IMAP_EXPORT void mm_nocritical(void){}
45355      PHP_IMAP_EXPORT void mm_notify(void){}
45356      PHP_IMAP_EXPORT void mm_login(void){}
45357      PHP_IMAP_EXPORT void mm_diskerror(void){}
45358      PHP_IMAP_EXPORT void mm_status(void){}
45359      PHP_IMAP_EXPORT void mm_lsub(void){}
45360      PHP_IMAP_EXPORT void mm_list(void){}
45361      PHP_IMAP_EXPORT void mm_exists(void){}
45362      PHP_IMAP_EXPORT void mm_searched(void){}
45363      PHP_IMAP_EXPORT void mm_expunged(void){}
45364      void rfc822_output_address_list(void);
45365      void (*f)(void);
45366      char foobar () {f = rfc822_output_address_list;}
45367
45368    char foobar();
45369    int main() {
45370      foobar();
45371      return 0;
45372    }
45373
45374_ACEOF
45375if ac_fn_c_try_link "$LINENO"
45376then :
45377
45378    LIBS=$old_LIBS
45379
45380      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
45381printf "%s\n" "yes" >&6; }
45382
45383printf "%s\n" "#define HAVE_RFC822_OUTPUT_ADDRESS_LIST 1" >>confdefs.h
45384
45385
45386
45387else $as_nop
45388
45389    LIBS=$old_LIBS
45390
45391      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
45392printf "%s\n" "no" >&6; }
45393
45394
45395fi
45396rm -f core conftest.err conftest.$ac_objext conftest.beam \
45397    conftest$ac_exeext conftest.$ac_ext
45398
45399
45400    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build with IMAP works" >&5
45401printf %s "checking whether build with IMAP works... " >&6; }
45402
45403
45404  old_LIBS=$LIBS
45405  LIBS="$TST_LIBS $LIBS"
45406  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45407/* end confdefs.h.  */
45408
45409
45410
45411#if defined(__GNUC__) && __GNUC__ >= 4
45412# define PHP_IMAP_EXPORT __attribute__ ((visibility("default")))
45413#else
45414# define PHP_IMAP_EXPORT
45415#endif
45416
45417    PHP_IMAP_EXPORT void mm_log(void){}
45418    PHP_IMAP_EXPORT void mm_dlog(void){}
45419    PHP_IMAP_EXPORT void mm_flags(void){}
45420    PHP_IMAP_EXPORT void mm_fatal(void){}
45421    PHP_IMAP_EXPORT void mm_critical(void){}
45422    PHP_IMAP_EXPORT void mm_nocritical(void){}
45423    PHP_IMAP_EXPORT void mm_notify(void){}
45424    PHP_IMAP_EXPORT void mm_login(void){}
45425    PHP_IMAP_EXPORT void mm_diskerror(void){}
45426    PHP_IMAP_EXPORT void mm_status(void){}
45427    PHP_IMAP_EXPORT void mm_lsub(void){}
45428    PHP_IMAP_EXPORT void mm_list(void){}
45429    PHP_IMAP_EXPORT void mm_exists(void){}
45430    PHP_IMAP_EXPORT void mm_searched(void){}
45431    PHP_IMAP_EXPORT void mm_expunged(void){}
45432
45433    char mail_newbody();
45434    int main() {
45435      mail_newbody();
45436      return 0;
45437    }
45438
45439_ACEOF
45440if ac_fn_c_try_link "$LINENO"
45441then :
45442
45443    LIBS=$old_LIBS
45444
45445      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
45446printf "%s\n" "yes" >&6; }
45447
45448
45449else $as_nop
45450
45451    LIBS=$old_LIBS
45452
45453      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
45454printf "%s\n" "no" >&6; }
45455      as_fn_error $? "build test failed. Please check the config.log for details." "$LINENO" 5
45456
45457
45458fi
45459rm -f core conftest.err conftest.$ac_objext conftest.beam \
45460    conftest$ac_exeext conftest.$ac_ext
45461
45462
45463fi
45464
45465
45466
45467
45468
45469php_enable_intl=no
45470
45471{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable internationalization support" >&5
45472printf %s "checking whether to enable internationalization support... " >&6; }
45473# Check whether --enable-intl was given.
45474if test ${enable_intl+y}
45475then :
45476  enableval=$enable_intl; PHP_INTL=$enableval
45477else $as_nop
45478
45479  PHP_INTL=no
45480  test "$PHP_ENABLE_ALL" && PHP_INTL=$PHP_ENABLE_ALL
45481
45482fi
45483
45484
45485
45486ext_output="yes, shared"
45487ext_shared=yes
45488case $PHP_INTL in
45489shared,*)
45490  PHP_INTL=`echo "$PHP_INTL"|$SED 's/^shared,//'`
45491  ;;
45492shared)
45493  PHP_INTL=yes
45494  ;;
45495no)
45496  ext_output=no
45497  ext_shared=no
45498  ;;
45499*)
45500  ext_output=yes
45501  ext_shared=no
45502  ;;
45503esac
45504
45505
45506
45507{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
45508printf "%s\n" "$ext_output" >&6; }
45509
45510
45511
45512
45513if test "$PHP_INTL" != "no"; then
45514
45515
45516pkg_failed=no
45517{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for icu-uc >= 50.1 icu-io icu-i18n" >&5
45518printf %s "checking for icu-uc >= 50.1 icu-io icu-i18n... " >&6; }
45519
45520if test -n "$ICU_CFLAGS"; then
45521    pkg_cv_ICU_CFLAGS="$ICU_CFLAGS"
45522 elif test -n "$PKG_CONFIG"; then
45523    if test -n "$PKG_CONFIG" && \
45524    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc >= 50.1 icu-io icu-i18n\""; } >&5
45525  ($PKG_CONFIG --exists --print-errors "icu-uc >= 50.1 icu-io icu-i18n") 2>&5
45526  ac_status=$?
45527  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
45528  test $ac_status = 0; }; then
45529  pkg_cv_ICU_CFLAGS=`$PKG_CONFIG --cflags "icu-uc >= 50.1 icu-io icu-i18n" 2>/dev/null`
45530		      test "x$?" != "x0" && pkg_failed=yes
45531else
45532  pkg_failed=yes
45533fi
45534 else
45535    pkg_failed=untried
45536fi
45537if test -n "$ICU_LIBS"; then
45538    pkg_cv_ICU_LIBS="$ICU_LIBS"
45539 elif test -n "$PKG_CONFIG"; then
45540    if test -n "$PKG_CONFIG" && \
45541    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc >= 50.1 icu-io icu-i18n\""; } >&5
45542  ($PKG_CONFIG --exists --print-errors "icu-uc >= 50.1 icu-io icu-i18n") 2>&5
45543  ac_status=$?
45544  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
45545  test $ac_status = 0; }; then
45546  pkg_cv_ICU_LIBS=`$PKG_CONFIG --libs "icu-uc >= 50.1 icu-io icu-i18n" 2>/dev/null`
45547		      test "x$?" != "x0" && pkg_failed=yes
45548else
45549  pkg_failed=yes
45550fi
45551 else
45552    pkg_failed=untried
45553fi
45554
45555
45556
45557if test $pkg_failed = yes; then
45558        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
45559printf "%s\n" "no" >&6; }
45560
45561if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
45562        _pkg_short_errors_supported=yes
45563else
45564        _pkg_short_errors_supported=no
45565fi
45566        if test $_pkg_short_errors_supported = yes; then
45567	        ICU_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "icu-uc >= 50.1 icu-io icu-i18n" 2>&1`
45568        else
45569	        ICU_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "icu-uc >= 50.1 icu-io icu-i18n" 2>&1`
45570        fi
45571	# Put the nasty error message in config.log where it belongs
45572	echo "$ICU_PKG_ERRORS" >&5
45573
45574	as_fn_error $? "Package requirements (icu-uc >= 50.1 icu-io icu-i18n) were not met:
45575
45576$ICU_PKG_ERRORS
45577
45578Consider adjusting the PKG_CONFIG_PATH environment variable if you
45579installed software in a non-standard prefix.
45580
45581Alternatively, you may set the environment variables ICU_CFLAGS
45582and ICU_LIBS to avoid the need to call pkg-config.
45583See the pkg-config man page for more details." "$LINENO" 5
45584elif test $pkg_failed = untried; then
45585        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
45586printf "%s\n" "no" >&6; }
45587	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
45588printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
45589as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
45590is in your PATH or set the PKG_CONFIG environment variable to the full
45591path to pkg-config.
45592
45593Alternatively, you may set the environment variables ICU_CFLAGS
45594and ICU_LIBS to avoid the need to call pkg-config.
45595See the pkg-config man page for more details.
45596
45597To get pkg-config, see <http://pkg-config.freedesktop.org/>.
45598See \`config.log' for more details" "$LINENO" 5; }
45599else
45600	ICU_CFLAGS=$pkg_cv_ICU_CFLAGS
45601	ICU_LIBS=$pkg_cv_ICU_LIBS
45602        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
45603printf "%s\n" "yes" >&6; }
45604
45605fi
45606
45607
45608  for ac_i in $ICU_CFLAGS; do
45609    case $ac_i in
45610    -I*)
45611      ac_ii=`echo $ac_i|cut -c 3-`
45612
45613  if test "$ac_ii" != "/usr/include"; then
45614
45615  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
45616    ai_p=$ac_ii
45617  else
45618
45619    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
45620
45621    ep_realdir=`(cd "$ep_dir" && pwd)`
45622    ai_p="$ep_realdir"/`basename "$ac_ii"`
45623  fi
45624
45625
45626
45627  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
45628
45629  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
45630  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45631    eval "INCLUDEPATH$unique=set"
45632
45633      if test ""; then
45634        INCLUDES="-I$ai_p $INCLUDES"
45635      else
45636        INCLUDES="$INCLUDES -I$ai_p"
45637      fi
45638
45639  fi
45640
45641  fi
45642
45643    ;;
45644    esac
45645  done
45646
45647
45648  for ac_i in $ICU_LIBS; do
45649    case $ac_i in
45650    -pthread)
45651      if test "$ext_shared" = "yes"; then
45652        INTL_SHARED_LIBADD="$INTL_SHARED_LIBADD -pthread"
45653      else
45654
45655
45656  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
45657
45658  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
45659  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45660    eval "EXTRA_LDFLAGS$unique=set"
45661    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
45662  fi
45663
45664
45665
45666  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
45667
45668  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
45669  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45670    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
45671    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
45672  fi
45673
45674      fi
45675    ;;
45676    -l*)
45677      ac_ii=`echo $ac_i|cut -c 3-`
45678
45679
45680  case $ac_ii in
45681  c|c_r) ;;
45682  *)
45683    if test "$ext_shared" = "yes"; then
45684        INTL_SHARED_LIBADD="$INTL_SHARED_LIBADD -l$ac_ii"
45685    else
45686
45687
45688  case $ac_ii in
45689  c|c_r) ;;
45690  *)
45691      LIBS="$LIBS -l$ac_ii"
45692   ;;
45693  esac
45694
45695
45696    fi
45697   ;;
45698  esac
45699
45700
45701    ;;
45702    -L*)
45703      ac_ii=`echo $ac_i|cut -c 3-`
45704
45705  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
45706
45707  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
45708    ai_p=$ac_ii
45709  else
45710
45711    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
45712
45713    ep_realdir=`(cd "$ep_dir" && pwd)`
45714    ai_p="$ep_realdir"/`basename "$ac_ii"`
45715  fi
45716
45717
45718      if test "$ext_shared" = "yes"; then
45719        INTL_SHARED_LIBADD="-L$ai_p $INTL_SHARED_LIBADD"
45720        test -n "$ld_runpath_switch" && INTL_SHARED_LIBADD="$ld_runpath_switch$ai_p $INTL_SHARED_LIBADD"
45721      else
45722
45723
45724
45725  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
45726
45727  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
45728  if test -n "$unique" && test "`eval $cmd`" = "" ; then
45729    eval "LIBPATH$unique=set"
45730
45731    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
45732    LDFLAGS="$LDFLAGS -L$ai_p"
45733    PHP_RPATHS="$PHP_RPATHS $ai_p"
45734
45735  fi
45736
45737
45738      fi
45739
45740  fi
45741
45742    ;;
45743    esac
45744  done
45745
45746
45747  ICU_CFLAGS="$ICU_CFLAGS -DU_NO_DEFAULT_INCLUDE_UTF_HEADERS=1"
45748  ICU_CXXFLAGS="$ICU_CXXFLAGS -DUNISTR_FROM_CHAR_EXPLICIT=explicit -DUNISTR_FROM_STRING_EXPLICIT=explicit"
45749
45750  if test "$PKG_CONFIG icu-io --atleast-version=60"; then
45751    ICU_CFLAGS="$ICU_CFLAGS -DU_HIDE_OBSOLETE_UTF_OLD_H=1"
45752  fi
45753
45754
45755  PHP_VAR_SUBST="$PHP_VAR_SUBST INTL_SHARED_LIBADD"
45756
45757  INTL_COMMON_FLAGS="$ICU_CFLAGS -Wno-write-strings -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
45758
45759  ext_builddir=ext/intl
45760  ext_srcdir=$abs_srcdir/ext/intl
45761  ext_dir=ext/intl
45762
45763  ac_extra=`echo "$INTL_COMMON_FLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
45764
45765  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
45766    PHP_INTL_SHARED=no
45767
45768
45769  case $ext_dir in
45770  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
45771  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
45772  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
45773  esac
45774
45775
45776
45777  b_c_pre=$php_c_pre
45778  b_cxx_pre=$php_cxx_pre
45779  b_c_meta=$php_c_meta
45780  b_cxx_meta=$php_cxx_meta
45781  b_c_post=$php_c_post
45782  b_cxx_post=$php_cxx_post
45783  b_lo=$php_lo
45784
45785
45786  old_IFS=$IFS
45787  for ac_src in php_intl.c \
45788    intl_error.c \
45789    intl_convert.c \
45790    collator/collator.c \
45791    collator/collator_class.c \
45792    collator/collator_sort.c \
45793    collator/collator_convert.c \
45794    collator/collator_locale.c \
45795    collator/collator_compare.c \
45796    collator/collator_attr.c \
45797    collator/collator_create.c \
45798    collator/collator_is_numeric.c \
45799    collator/collator_error.c \
45800    common/common_error.c \
45801    converter/converter.c \
45802    formatter/formatter.c \
45803    formatter/formatter_main.c \
45804    formatter/formatter_class.c \
45805    formatter/formatter_attr.c \
45806    formatter/formatter_data.c \
45807    formatter/formatter_format.c \
45808    formatter/formatter_parse.c \
45809    normalizer/normalizer.c \
45810    normalizer/normalizer_class.c \
45811    normalizer/normalizer_normalize.c \
45812    locale/locale.c \
45813    locale/locale_class.c \
45814    locale/locale_methods.c \
45815    dateformat/dateformat.c \
45816    dateformat/dateformat_class.c \
45817    dateformat/dateformat_attr.c \
45818    dateformat/dateformat_data.c \
45819    dateformat/dateformat_format.c \
45820    dateformat/dateformat_parse.c \
45821    msgformat/msgformat.c \
45822    msgformat/msgformat_attr.c \
45823    msgformat/msgformat_class.c \
45824    msgformat/msgformat_data.c  \
45825    msgformat/msgformat_format.c \
45826    msgformat/msgformat_parse.c \
45827    grapheme/grapheme_string.c \
45828    grapheme/grapheme_util.c \
45829    resourcebundle/resourcebundle.c \
45830    resourcebundle/resourcebundle_class.c \
45831    resourcebundle/resourcebundle_iterator.c \
45832    transliterator/transliterator.c \
45833    transliterator/transliterator_class.c \
45834    transliterator/transliterator_methods.c \
45835    uchar/uchar.c \
45836    idn/idn.c \
45837    spoofchecker/spoofchecker_class.c \
45838    spoofchecker/spoofchecker.c\
45839    spoofchecker/spoofchecker_create.c\
45840    spoofchecker/spoofchecker_main.c; do
45841
45842      IFS=.
45843      set $ac_src
45844      ac_obj=$1
45845      IFS=$old_IFS
45846
45847      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
45848
45849      case $ac_src in
45850        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45851        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45852        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45853        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
45854      esac
45855
45856      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
45857
45858    cat >>Makefile.objects<<EOF
45859-include $ac_bdir$ac_obj.dep
45860$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
45861	$ac_comp
45862EOF
45863  done
45864
45865
45866    EXT_STATIC="$EXT_STATIC intl;$ext_dir"
45867    if test "$ext_shared" != "nocli"; then
45868      EXT_CLI_STATIC="$EXT_CLI_STATIC intl;$ext_dir"
45869    fi
45870  else
45871    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
45872      PHP_INTL_SHARED=yes
45873
45874  case $ext_dir in
45875  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
45876  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
45877  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
45878  esac
45879
45880
45881
45882  b_c_pre=$shared_c_pre
45883  b_cxx_pre=$shared_cxx_pre
45884  b_c_meta=$shared_c_meta
45885  b_cxx_meta=$shared_cxx_meta
45886  b_c_post=$shared_c_post
45887  b_cxx_post=$shared_cxx_post
45888  b_lo=$shared_lo
45889
45890
45891  old_IFS=$IFS
45892  for ac_src in php_intl.c \
45893    intl_error.c \
45894    intl_convert.c \
45895    collator/collator.c \
45896    collator/collator_class.c \
45897    collator/collator_sort.c \
45898    collator/collator_convert.c \
45899    collator/collator_locale.c \
45900    collator/collator_compare.c \
45901    collator/collator_attr.c \
45902    collator/collator_create.c \
45903    collator/collator_is_numeric.c \
45904    collator/collator_error.c \
45905    common/common_error.c \
45906    converter/converter.c \
45907    formatter/formatter.c \
45908    formatter/formatter_main.c \
45909    formatter/formatter_class.c \
45910    formatter/formatter_attr.c \
45911    formatter/formatter_data.c \
45912    formatter/formatter_format.c \
45913    formatter/formatter_parse.c \
45914    normalizer/normalizer.c \
45915    normalizer/normalizer_class.c \
45916    normalizer/normalizer_normalize.c \
45917    locale/locale.c \
45918    locale/locale_class.c \
45919    locale/locale_methods.c \
45920    dateformat/dateformat.c \
45921    dateformat/dateformat_class.c \
45922    dateformat/dateformat_attr.c \
45923    dateformat/dateformat_data.c \
45924    dateformat/dateformat_format.c \
45925    dateformat/dateformat_parse.c \
45926    msgformat/msgformat.c \
45927    msgformat/msgformat_attr.c \
45928    msgformat/msgformat_class.c \
45929    msgformat/msgformat_data.c  \
45930    msgformat/msgformat_format.c \
45931    msgformat/msgformat_parse.c \
45932    grapheme/grapheme_string.c \
45933    grapheme/grapheme_util.c \
45934    resourcebundle/resourcebundle.c \
45935    resourcebundle/resourcebundle_class.c \
45936    resourcebundle/resourcebundle_iterator.c \
45937    transliterator/transliterator.c \
45938    transliterator/transliterator_class.c \
45939    transliterator/transliterator_methods.c \
45940    uchar/uchar.c \
45941    idn/idn.c \
45942    spoofchecker/spoofchecker_class.c \
45943    spoofchecker/spoofchecker.c\
45944    spoofchecker/spoofchecker_create.c\
45945    spoofchecker/spoofchecker_main.c; do
45946
45947      IFS=.
45948      set $ac_src
45949      ac_obj=$1
45950      IFS=$old_IFS
45951
45952      shared_objects_intl="$shared_objects_intl $ac_bdir$ac_obj.lo"
45953
45954      case $ac_src in
45955        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45956        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45957        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
45958        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
45959      esac
45960
45961      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
45962
45963    cat >>Makefile.objects<<EOF
45964-include $ac_bdir$ac_obj.dep
45965$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
45966	$ac_comp
45967EOF
45968  done
45969
45970
45971  install_modules="install-modules"
45972  suffix=la
45973
45974  case $host_alias in
45975    *aix*)
45976      additional_flags="-Wl,-G"
45977      ;;
45978  esac
45979
45980  if test "x" = "xyes"; then
45981    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/intl.$suffix"
45982  else
45983    PHP_MODULES="$PHP_MODULES \$(phplibdir)/intl.$suffix"
45984  fi
45985
45986  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_intl"
45987
45988  cat >>Makefile.objects<<EOF
45989\$(phplibdir)/intl.$suffix: $ext_builddir/intl.$suffix
45990	\$(LIBTOOL) --mode=install cp $ext_builddir/intl.$suffix \$(phplibdir)
45991
45992$ext_builddir/intl.$suffix: \$(shared_objects_intl) \$(INTL_SHARED_DEPENDENCIES)
45993	\$(LIBTOOL) --mode=link \$(CXX) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_intl) \$(INTL_SHARED_LIBADD)
45994
45995EOF
45996
45997
45998printf "%s\n" "#define COMPILE_DL_INTL 1" >>confdefs.h
45999
46000    fi
46001  fi
46002
46003  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
46004    PHP_INTL_SHARED=no
46005    case "$PHP_SAPI" in
46006      cgi|embed|phpdbg)
46007
46008
46009  case $ext_dir in
46010  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
46011  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
46012  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
46013  esac
46014
46015
46016
46017  b_c_pre=$php_c_pre
46018  b_cxx_pre=$php_cxx_pre
46019  b_c_meta=$php_c_meta
46020  b_cxx_meta=$php_cxx_meta
46021  b_c_post=$php_c_post
46022  b_cxx_post=$php_cxx_post
46023  b_lo=$php_lo
46024
46025
46026  old_IFS=$IFS
46027  for ac_src in php_intl.c \
46028    intl_error.c \
46029    intl_convert.c \
46030    collator/collator.c \
46031    collator/collator_class.c \
46032    collator/collator_sort.c \
46033    collator/collator_convert.c \
46034    collator/collator_locale.c \
46035    collator/collator_compare.c \
46036    collator/collator_attr.c \
46037    collator/collator_create.c \
46038    collator/collator_is_numeric.c \
46039    collator/collator_error.c \
46040    common/common_error.c \
46041    converter/converter.c \
46042    formatter/formatter.c \
46043    formatter/formatter_main.c \
46044    formatter/formatter_class.c \
46045    formatter/formatter_attr.c \
46046    formatter/formatter_data.c \
46047    formatter/formatter_format.c \
46048    formatter/formatter_parse.c \
46049    normalizer/normalizer.c \
46050    normalizer/normalizer_class.c \
46051    normalizer/normalizer_normalize.c \
46052    locale/locale.c \
46053    locale/locale_class.c \
46054    locale/locale_methods.c \
46055    dateformat/dateformat.c \
46056    dateformat/dateformat_class.c \
46057    dateformat/dateformat_attr.c \
46058    dateformat/dateformat_data.c \
46059    dateformat/dateformat_format.c \
46060    dateformat/dateformat_parse.c \
46061    msgformat/msgformat.c \
46062    msgformat/msgformat_attr.c \
46063    msgformat/msgformat_class.c \
46064    msgformat/msgformat_data.c  \
46065    msgformat/msgformat_format.c \
46066    msgformat/msgformat_parse.c \
46067    grapheme/grapheme_string.c \
46068    grapheme/grapheme_util.c \
46069    resourcebundle/resourcebundle.c \
46070    resourcebundle/resourcebundle_class.c \
46071    resourcebundle/resourcebundle_iterator.c \
46072    transliterator/transliterator.c \
46073    transliterator/transliterator_class.c \
46074    transliterator/transliterator_methods.c \
46075    uchar/uchar.c \
46076    idn/idn.c \
46077    spoofchecker/spoofchecker_class.c \
46078    spoofchecker/spoofchecker.c\
46079    spoofchecker/spoofchecker_create.c\
46080    spoofchecker/spoofchecker_main.c; do
46081
46082      IFS=.
46083      set $ac_src
46084      ac_obj=$1
46085      IFS=$old_IFS
46086
46087      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
46088
46089      case $ac_src in
46090        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46091        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46092        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46093        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
46094      esac
46095
46096      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
46097
46098    cat >>Makefile.objects<<EOF
46099-include $ac_bdir$ac_obj.dep
46100$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
46101	$ac_comp
46102EOF
46103  done
46104
46105
46106        EXT_STATIC="$EXT_STATIC intl;$ext_dir"
46107        ;;
46108      *)
46109
46110
46111  case $ext_dir in
46112  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
46113  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
46114  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
46115  esac
46116
46117
46118
46119  b_c_pre=$php_c_pre
46120  b_cxx_pre=$php_cxx_pre
46121  b_c_meta=$php_c_meta
46122  b_cxx_meta=$php_cxx_meta
46123  b_c_post=$php_c_post
46124  b_cxx_post=$php_cxx_post
46125  b_lo=$php_lo
46126
46127
46128  old_IFS=$IFS
46129  for ac_src in php_intl.c \
46130    intl_error.c \
46131    intl_convert.c \
46132    collator/collator.c \
46133    collator/collator_class.c \
46134    collator/collator_sort.c \
46135    collator/collator_convert.c \
46136    collator/collator_locale.c \
46137    collator/collator_compare.c \
46138    collator/collator_attr.c \
46139    collator/collator_create.c \
46140    collator/collator_is_numeric.c \
46141    collator/collator_error.c \
46142    common/common_error.c \
46143    converter/converter.c \
46144    formatter/formatter.c \
46145    formatter/formatter_main.c \
46146    formatter/formatter_class.c \
46147    formatter/formatter_attr.c \
46148    formatter/formatter_data.c \
46149    formatter/formatter_format.c \
46150    formatter/formatter_parse.c \
46151    normalizer/normalizer.c \
46152    normalizer/normalizer_class.c \
46153    normalizer/normalizer_normalize.c \
46154    locale/locale.c \
46155    locale/locale_class.c \
46156    locale/locale_methods.c \
46157    dateformat/dateformat.c \
46158    dateformat/dateformat_class.c \
46159    dateformat/dateformat_attr.c \
46160    dateformat/dateformat_data.c \
46161    dateformat/dateformat_format.c \
46162    dateformat/dateformat_parse.c \
46163    msgformat/msgformat.c \
46164    msgformat/msgformat_attr.c \
46165    msgformat/msgformat_class.c \
46166    msgformat/msgformat_data.c  \
46167    msgformat/msgformat_format.c \
46168    msgformat/msgformat_parse.c \
46169    grapheme/grapheme_string.c \
46170    grapheme/grapheme_util.c \
46171    resourcebundle/resourcebundle.c \
46172    resourcebundle/resourcebundle_class.c \
46173    resourcebundle/resourcebundle_iterator.c \
46174    transliterator/transliterator.c \
46175    transliterator/transliterator_class.c \
46176    transliterator/transliterator_methods.c \
46177    uchar/uchar.c \
46178    idn/idn.c \
46179    spoofchecker/spoofchecker_class.c \
46180    spoofchecker/spoofchecker.c\
46181    spoofchecker/spoofchecker_create.c\
46182    spoofchecker/spoofchecker_main.c; do
46183
46184      IFS=.
46185      set $ac_src
46186      ac_obj=$1
46187      IFS=$old_IFS
46188
46189      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
46190
46191      case $ac_src in
46192        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46193        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46194        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
46195        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
46196      esac
46197
46198      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
46199
46200    cat >>Makefile.objects<<EOF
46201-include $ac_bdir$ac_obj.dep
46202$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
46203	$ac_comp
46204EOF
46205  done
46206
46207
46208        ;;
46209    esac
46210    EXT_CLI_STATIC="$EXT_CLI_STATIC intl;$ext_dir"
46211  fi
46212
46213
46214    BUILD_DIR="$BUILD_DIR $ext_builddir"
46215
46216
46217
46218  if test "$ext_builddir" = "."; then
46219    PHP_PECL_EXTENSION=intl
46220
46221  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
46222
46223  fi
46224
46225
46226  PHP_INTL_CXX_SOURCES="intl_convertcpp.cpp \
46227    common/common_enum.cpp \
46228    common/common_date.cpp \
46229    dateformat/dateformat_format_object.cpp \
46230    dateformat/dateformat_create.cpp \
46231    dateformat/dateformat_attrcpp.cpp \
46232    dateformat/dateformat_helpers.cpp \
46233    dateformat/datepatterngenerator_class.cpp \
46234    dateformat/datepatterngenerator_methods.cpp \
46235    msgformat/msgformat_helpers.cpp \
46236    timezone/timezone_class.cpp \
46237    timezone/timezone_methods.cpp \
46238    calendar/calendar_class.cpp \
46239    calendar/calendar_methods.cpp \
46240    calendar/gregoriancalendar_methods.cpp \
46241    breakiterator/breakiterator_class.cpp \
46242    breakiterator/breakiterator_iterators.cpp \
46243    breakiterator/breakiterator_methods.cpp \
46244    breakiterator/rulebasedbreakiterator_methods.cpp \
46245    breakiterator/codepointiterator_internal.cpp \
46246    breakiterator/codepointiterator_methods.cpp"
46247
46248
46249  if test -z "$php_cxx_done"; then
46250    ac_ext=cpp
46251ac_cpp='$CXXCPP $CPPFLAGS'
46252ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46253ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46254ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46255if test -z "$CXX"; then
46256  if test -n "$CCC"; then
46257    CXX=$CCC
46258  else
46259    if test -n "$ac_tool_prefix"; then
46260  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
46261  do
46262    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
46263set dummy $ac_tool_prefix$ac_prog; ac_word=$2
46264{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
46265printf %s "checking for $ac_word... " >&6; }
46266if test ${ac_cv_prog_CXX+y}
46267then :
46268  printf %s "(cached) " >&6
46269else $as_nop
46270  if test -n "$CXX"; then
46271  ac_cv_prog_CXX="$CXX" # Let the user override the test.
46272else
46273as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
46274for as_dir in $PATH
46275do
46276  IFS=$as_save_IFS
46277  case $as_dir in #(((
46278    '') as_dir=./ ;;
46279    */) ;;
46280    *) as_dir=$as_dir/ ;;
46281  esac
46282    for ac_exec_ext in '' $ac_executable_extensions; do
46283  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
46284    ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
46285    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
46286    break 2
46287  fi
46288done
46289  done
46290IFS=$as_save_IFS
46291
46292fi
46293fi
46294CXX=$ac_cv_prog_CXX
46295if test -n "$CXX"; then
46296  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
46297printf "%s\n" "$CXX" >&6; }
46298else
46299  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
46300printf "%s\n" "no" >&6; }
46301fi
46302
46303
46304    test -n "$CXX" && break
46305  done
46306fi
46307if test -z "$CXX"; then
46308  ac_ct_CXX=$CXX
46309  for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
46310do
46311  # Extract the first word of "$ac_prog", so it can be a program name with args.
46312set dummy $ac_prog; ac_word=$2
46313{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
46314printf %s "checking for $ac_word... " >&6; }
46315if test ${ac_cv_prog_ac_ct_CXX+y}
46316then :
46317  printf %s "(cached) " >&6
46318else $as_nop
46319  if test -n "$ac_ct_CXX"; then
46320  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
46321else
46322as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
46323for as_dir in $PATH
46324do
46325  IFS=$as_save_IFS
46326  case $as_dir in #(((
46327    '') as_dir=./ ;;
46328    */) ;;
46329    *) as_dir=$as_dir/ ;;
46330  esac
46331    for ac_exec_ext in '' $ac_executable_extensions; do
46332  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
46333    ac_cv_prog_ac_ct_CXX="$ac_prog"
46334    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
46335    break 2
46336  fi
46337done
46338  done
46339IFS=$as_save_IFS
46340
46341fi
46342fi
46343ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
46344if test -n "$ac_ct_CXX"; then
46345  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
46346printf "%s\n" "$ac_ct_CXX" >&6; }
46347else
46348  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
46349printf "%s\n" "no" >&6; }
46350fi
46351
46352
46353  test -n "$ac_ct_CXX" && break
46354done
46355
46356  if test "x$ac_ct_CXX" = x; then
46357    CXX="g++"
46358  else
46359    case $cross_compiling:$ac_tool_warned in
46360yes:)
46361{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
46362printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
46363ac_tool_warned=yes ;;
46364esac
46365    CXX=$ac_ct_CXX
46366  fi
46367fi
46368
46369  fi
46370fi
46371# Provide some information about the compiler.
46372printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
46373set X $ac_compile
46374ac_compiler=$2
46375for ac_option in --version -v -V -qversion; do
46376  { { ac_try="$ac_compiler $ac_option >&5"
46377case "(($ac_try" in
46378  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
46379  *) ac_try_echo=$ac_try;;
46380esac
46381eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
46382printf "%s\n" "$ac_try_echo"; } >&5
46383  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
46384  ac_status=$?
46385  if test -s conftest.err; then
46386    sed '10a\
46387... rest of stderr output deleted ...
46388         10q' conftest.err >conftest.er1
46389    cat conftest.er1 >&5
46390  fi
46391  rm -f conftest.er1 conftest.err
46392  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46393  test $ac_status = 0; }
46394done
46395
46396{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C++" >&5
46397printf %s "checking whether the compiler supports GNU C++... " >&6; }
46398if test ${ac_cv_cxx_compiler_gnu+y}
46399then :
46400  printf %s "(cached) " >&6
46401else $as_nop
46402  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46403/* end confdefs.h.  */
46404
46405int
46406main (void)
46407{
46408#ifndef __GNUC__
46409       choke me
46410#endif
46411
46412  ;
46413  return 0;
46414}
46415_ACEOF
46416if ac_fn_cxx_try_compile "$LINENO"
46417then :
46418  ac_compiler_gnu=yes
46419else $as_nop
46420  ac_compiler_gnu=no
46421fi
46422rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
46423ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
46424
46425fi
46426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
46427printf "%s\n" "$ac_cv_cxx_compiler_gnu" >&6; }
46428ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46429
46430if test $ac_compiler_gnu = yes; then
46431  GXX=yes
46432else
46433  GXX=
46434fi
46435ac_test_CXXFLAGS=${CXXFLAGS+y}
46436ac_save_CXXFLAGS=$CXXFLAGS
46437{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
46438printf %s "checking whether $CXX accepts -g... " >&6; }
46439if test ${ac_cv_prog_cxx_g+y}
46440then :
46441  printf %s "(cached) " >&6
46442else $as_nop
46443  ac_save_cxx_werror_flag=$ac_cxx_werror_flag
46444   ac_cxx_werror_flag=yes
46445   ac_cv_prog_cxx_g=no
46446   CXXFLAGS="-g"
46447   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46448/* end confdefs.h.  */
46449
46450int
46451main (void)
46452{
46453
46454  ;
46455  return 0;
46456}
46457_ACEOF
46458if ac_fn_cxx_try_compile "$LINENO"
46459then :
46460  ac_cv_prog_cxx_g=yes
46461else $as_nop
46462  CXXFLAGS=""
46463      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46464/* end confdefs.h.  */
46465
46466int
46467main (void)
46468{
46469
46470  ;
46471  return 0;
46472}
46473_ACEOF
46474if ac_fn_cxx_try_compile "$LINENO"
46475then :
46476
46477else $as_nop
46478  ac_cxx_werror_flag=$ac_save_cxx_werror_flag
46479	 CXXFLAGS="-g"
46480	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46481/* end confdefs.h.  */
46482
46483int
46484main (void)
46485{
46486
46487  ;
46488  return 0;
46489}
46490_ACEOF
46491if ac_fn_cxx_try_compile "$LINENO"
46492then :
46493  ac_cv_prog_cxx_g=yes
46494fi
46495rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
46496fi
46497rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
46498fi
46499rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
46500   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
46501fi
46502{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
46503printf "%s\n" "$ac_cv_prog_cxx_g" >&6; }
46504if test $ac_test_CXXFLAGS; then
46505  CXXFLAGS=$ac_save_CXXFLAGS
46506elif test $ac_cv_prog_cxx_g = yes; then
46507  if test "$GXX" = yes; then
46508    CXXFLAGS="-g -O2"
46509  else
46510    CXXFLAGS="-g"
46511  fi
46512else
46513  if test "$GXX" = yes; then
46514    CXXFLAGS="-O2"
46515  else
46516    CXXFLAGS=
46517  fi
46518fi
46519ac_prog_cxx_stdcxx=no
46520if test x$ac_prog_cxx_stdcxx = xno
46521then :
46522  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++11 features" >&5
46523printf %s "checking for $CXX option to enable C++11 features... " >&6; }
46524if test ${ac_cv_prog_cxx_11+y}
46525then :
46526  printf %s "(cached) " >&6
46527else $as_nop
46528  ac_cv_prog_cxx_11=no
46529ac_save_CXX=$CXX
46530cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46531/* end confdefs.h.  */
46532$ac_cxx_conftest_cxx11_program
46533_ACEOF
46534for ac_arg in '' -std=gnu++11 -std=gnu++0x -std=c++11 -std=c++0x -qlanglvl=extended0x -AA
46535do
46536  CXX="$ac_save_CXX $ac_arg"
46537  if ac_fn_cxx_try_compile "$LINENO"
46538then :
46539  ac_cv_prog_cxx_cxx11=$ac_arg
46540fi
46541rm -f core conftest.err conftest.$ac_objext conftest.beam
46542  test "x$ac_cv_prog_cxx_cxx11" != "xno" && break
46543done
46544rm -f conftest.$ac_ext
46545CXX=$ac_save_CXX
46546fi
46547
46548if test "x$ac_cv_prog_cxx_cxx11" = xno
46549then :
46550  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
46551printf "%s\n" "unsupported" >&6; }
46552else $as_nop
46553  if test "x$ac_cv_prog_cxx_cxx11" = x
46554then :
46555  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
46556printf "%s\n" "none needed" >&6; }
46557else $as_nop
46558  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx11" >&5
46559printf "%s\n" "$ac_cv_prog_cxx_cxx11" >&6; }
46560     CXX="$CXX $ac_cv_prog_cxx_cxx11"
46561fi
46562  ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx11
46563  ac_prog_cxx_stdcxx=cxx11
46564fi
46565fi
46566if test x$ac_prog_cxx_stdcxx = xno
46567then :
46568  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++98 features" >&5
46569printf %s "checking for $CXX option to enable C++98 features... " >&6; }
46570if test ${ac_cv_prog_cxx_98+y}
46571then :
46572  printf %s "(cached) " >&6
46573else $as_nop
46574  ac_cv_prog_cxx_98=no
46575ac_save_CXX=$CXX
46576cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46577/* end confdefs.h.  */
46578$ac_cxx_conftest_cxx98_program
46579_ACEOF
46580for ac_arg in '' -std=gnu++98 -std=c++98 -qlanglvl=extended -AA
46581do
46582  CXX="$ac_save_CXX $ac_arg"
46583  if ac_fn_cxx_try_compile "$LINENO"
46584then :
46585  ac_cv_prog_cxx_cxx98=$ac_arg
46586fi
46587rm -f core conftest.err conftest.$ac_objext conftest.beam
46588  test "x$ac_cv_prog_cxx_cxx98" != "xno" && break
46589done
46590rm -f conftest.$ac_ext
46591CXX=$ac_save_CXX
46592fi
46593
46594if test "x$ac_cv_prog_cxx_cxx98" = xno
46595then :
46596  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
46597printf "%s\n" "unsupported" >&6; }
46598else $as_nop
46599  if test "x$ac_cv_prog_cxx_cxx98" = x
46600then :
46601  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
46602printf "%s\n" "none needed" >&6; }
46603else $as_nop
46604  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx98" >&5
46605printf "%s\n" "$ac_cv_prog_cxx_cxx98" >&6; }
46606     CXX="$CXX $ac_cv_prog_cxx_cxx98"
46607fi
46608  ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx98
46609  ac_prog_cxx_stdcxx=cxx98
46610fi
46611fi
46612
46613ac_ext=c
46614ac_cpp='$CPP $CPPFLAGS'
46615ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46616ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46617ac_compiler_gnu=$ac_cv_c_compiler_gnu
46618
46619    ac_ext=cpp
46620ac_cpp='$CXXCPP $CPPFLAGS'
46621ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46622ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46623ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46624{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
46625printf %s "checking how to run the C++ preprocessor... " >&6; }
46626if test -z "$CXXCPP"; then
46627  if test ${ac_cv_prog_CXXCPP+y}
46628then :
46629  printf %s "(cached) " >&6
46630else $as_nop
46631      # Double quotes because $CXX needs to be expanded
46632    for CXXCPP in "$CXX -E" cpp /lib/cpp
46633    do
46634      ac_preproc_ok=false
46635for ac_cxx_preproc_warn_flag in '' yes
46636do
46637  # Use a header file that comes with gcc, so configuring glibc
46638  # with a fresh cross-compiler works.
46639  # On the NeXT, cc -E runs the code through the compiler's parser,
46640  # not just through cpp. "Syntax error" is here to catch this case.
46641  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46642/* end confdefs.h.  */
46643#include <limits.h>
46644		     Syntax error
46645_ACEOF
46646if ac_fn_cxx_try_cpp "$LINENO"
46647then :
46648
46649else $as_nop
46650  # Broken: fails on valid input.
46651continue
46652fi
46653rm -f conftest.err conftest.i conftest.$ac_ext
46654
46655  # OK, works on sane cases.  Now check whether nonexistent headers
46656  # can be detected and how.
46657  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46658/* end confdefs.h.  */
46659#include <ac_nonexistent.h>
46660_ACEOF
46661if ac_fn_cxx_try_cpp "$LINENO"
46662then :
46663  # Broken: success on invalid input.
46664continue
46665else $as_nop
46666  # Passes both tests.
46667ac_preproc_ok=:
46668break
46669fi
46670rm -f conftest.err conftest.i conftest.$ac_ext
46671
46672done
46673# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
46674rm -f conftest.i conftest.err conftest.$ac_ext
46675if $ac_preproc_ok
46676then :
46677  break
46678fi
46679
46680    done
46681    ac_cv_prog_CXXCPP=$CXXCPP
46682
46683fi
46684  CXXCPP=$ac_cv_prog_CXXCPP
46685else
46686  ac_cv_prog_CXXCPP=$CXXCPP
46687fi
46688{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
46689printf "%s\n" "$CXXCPP" >&6; }
46690ac_preproc_ok=false
46691for ac_cxx_preproc_warn_flag in '' yes
46692do
46693  # Use a header file that comes with gcc, so configuring glibc
46694  # with a fresh cross-compiler works.
46695  # On the NeXT, cc -E runs the code through the compiler's parser,
46696  # not just through cpp. "Syntax error" is here to catch this case.
46697  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46698/* end confdefs.h.  */
46699#include <limits.h>
46700		     Syntax error
46701_ACEOF
46702if ac_fn_cxx_try_cpp "$LINENO"
46703then :
46704
46705else $as_nop
46706  # Broken: fails on valid input.
46707continue
46708fi
46709rm -f conftest.err conftest.i conftest.$ac_ext
46710
46711  # OK, works on sane cases.  Now check whether nonexistent headers
46712  # can be detected and how.
46713  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46714/* end confdefs.h.  */
46715#include <ac_nonexistent.h>
46716_ACEOF
46717if ac_fn_cxx_try_cpp "$LINENO"
46718then :
46719  # Broken: success on invalid input.
46720continue
46721else $as_nop
46722  # Passes both tests.
46723ac_preproc_ok=:
46724break
46725fi
46726rm -f conftest.err conftest.i conftest.$ac_ext
46727
46728done
46729# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
46730rm -f conftest.i conftest.err conftest.$ac_ext
46731if $ac_preproc_ok
46732then :
46733
46734else $as_nop
46735  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
46736printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
46737as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
46738See \`config.log' for more details" "$LINENO" 5; }
46739fi
46740
46741ac_ext=c
46742ac_cpp='$CPP $CPPFLAGS'
46743ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46744ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46745ac_compiler_gnu=$ac_cv_c_compiler_gnu
46746
46747
46748
46749  case stdc++ in
46750  c|c_r) ;;
46751  *)
46752      LIBS="-lstdc++ $LIBS"
46753   ;;
46754  esac
46755
46756
46757    php_cxx_done=yes
46758  fi
46759
46760
46761  ax_cxx_compile_alternatives="11 0x"  ax_cxx_compile_cxx11_required=truednl
46762  ac_ext=cpp
46763ac_cpp='$CXXCPP $CPPFLAGS'
46764ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46765ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46766ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46767  ac_success=no
46768
46769        for alternative in ${ax_cxx_compile_alternatives}; do
46770    for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
46771      cachevar=`printf "%s\n" "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
46772      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
46773printf %s "checking whether $CXX supports C++11 features with $switch... " >&6; }
46774if eval test \${$cachevar+y}
46775then :
46776  printf %s "(cached) " >&6
46777else $as_nop
46778  ac_save_CXX="$CXX"
46779           CXX="$CXX $switch"
46780           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46781/* end confdefs.h.  */
46782
46783
46784// If the compiler admits that it is not ready for C++11, why torture it?
46785// Hopefully, this will speed up the test.
46786
46787#ifndef __cplusplus
46788
46789#error "This is not a C++ compiler"
46790
46791#elif __cplusplus < 201103L
46792
46793#error "This is not a C++11 compiler"
46794
46795#else
46796
46797namespace cxx11
46798{
46799
46800  namespace test_static_assert
46801  {
46802
46803    template <typename T>
46804    struct check
46805    {
46806      static_assert(sizeof(int) <= sizeof(T), "not big enough");
46807    };
46808
46809  }
46810
46811  namespace test_final_override
46812  {
46813
46814    struct Base
46815    {
46816      virtual ~Base() {}
46817      virtual void f() {}
46818    };
46819
46820    struct Derived : public Base
46821    {
46822      virtual ~Derived() override {}
46823      virtual void f() override {}
46824    };
46825
46826  }
46827
46828  namespace test_double_right_angle_brackets
46829  {
46830
46831    template < typename T >
46832    struct check {};
46833
46834    typedef check<void> single_type;
46835    typedef check<check<void>> double_type;
46836    typedef check<check<check<void>>> triple_type;
46837    typedef check<check<check<check<void>>>> quadruple_type;
46838
46839  }
46840
46841  namespace test_decltype
46842  {
46843
46844    int
46845    f()
46846    {
46847      int a = 1;
46848      decltype(a) b = 2;
46849      return a + b;
46850    }
46851
46852  }
46853
46854  namespace test_type_deduction
46855  {
46856
46857    template < typename T1, typename T2 >
46858    struct is_same
46859    {
46860      static const bool value = false;
46861    };
46862
46863    template < typename T >
46864    struct is_same<T, T>
46865    {
46866      static const bool value = true;
46867    };
46868
46869    template < typename T1, typename T2 >
46870    auto
46871    add(T1 a1, T2 a2) -> decltype(a1 + a2)
46872    {
46873      return a1 + a2;
46874    }
46875
46876    int
46877    test(const int c, volatile int v)
46878    {
46879      static_assert(is_same<int, decltype(0)>::value == true, "");
46880      static_assert(is_same<int, decltype(c)>::value == false, "");
46881      static_assert(is_same<int, decltype(v)>::value == false, "");
46882      auto ac = c;
46883      auto av = v;
46884      auto sumi = ac + av + 'x';
46885      auto sumf = ac + av + 1.0;
46886      static_assert(is_same<int, decltype(ac)>::value == true, "");
46887      static_assert(is_same<int, decltype(av)>::value == true, "");
46888      static_assert(is_same<int, decltype(sumi)>::value == true, "");
46889      static_assert(is_same<int, decltype(sumf)>::value == false, "");
46890      static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
46891      return (sumf > 0.0) ? sumi : add(c, v);
46892    }
46893
46894  }
46895
46896  namespace test_noexcept
46897  {
46898
46899    int f() { return 0; }
46900    int g() noexcept { return 0; }
46901
46902    static_assert(noexcept(f()) == false, "");
46903    static_assert(noexcept(g()) == true, "");
46904
46905  }
46906
46907  namespace test_constexpr
46908  {
46909
46910    template < typename CharT >
46911    unsigned long constexpr
46912    strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
46913    {
46914      return *s ? strlen_c_r(s + 1, acc + 1) : acc;
46915    }
46916
46917    template < typename CharT >
46918    unsigned long constexpr
46919    strlen_c(const CharT *const s) noexcept
46920    {
46921      return strlen_c_r(s, 0UL);
46922    }
46923
46924    static_assert(strlen_c("") == 0UL, "");
46925    static_assert(strlen_c("1") == 1UL, "");
46926    static_assert(strlen_c("example") == 7UL, "");
46927    static_assert(strlen_c("another\0example") == 7UL, "");
46928
46929  }
46930
46931  namespace test_rvalue_references
46932  {
46933
46934    template < int N >
46935    struct answer
46936    {
46937      static constexpr int value = N;
46938    };
46939
46940    answer<1> f(int&)       { return answer<1>(); }
46941    answer<2> f(const int&) { return answer<2>(); }
46942    answer<3> f(int&&)      { return answer<3>(); }
46943
46944    void
46945    test()
46946    {
46947      int i = 0;
46948      const int c = 0;
46949      static_assert(decltype(f(i))::value == 1, "");
46950      static_assert(decltype(f(c))::value == 2, "");
46951      static_assert(decltype(f(0))::value == 3, "");
46952    }
46953
46954  }
46955
46956  namespace test_uniform_initialization
46957  {
46958
46959    struct test
46960    {
46961      static const int zero {};
46962      static const int one {1};
46963    };
46964
46965    static_assert(test::zero == 0, "");
46966    static_assert(test::one == 1, "");
46967
46968  }
46969
46970  namespace test_lambdas
46971  {
46972
46973    void
46974    test1()
46975    {
46976      auto lambda1 = [](){};
46977      auto lambda2 = lambda1;
46978      lambda1();
46979      lambda2();
46980    }
46981
46982    int
46983    test2()
46984    {
46985      auto a = [](int i, int j){ return i + j; }(1, 2);
46986      auto b = []() -> int { return '0'; }();
46987      auto c = [=](){ return a + b; }();
46988      auto d = [&](){ return c; }();
46989      auto e = [a, &b](int x) mutable {
46990        const auto identity = [](int y){ return y; };
46991        for (auto i = 0; i < a; ++i)
46992          a += b--;
46993        return x + identity(a + b);
46994      }(0);
46995      return a + b + c + d + e;
46996    }
46997
46998    int
46999    test3()
47000    {
47001      const auto nullary = [](){ return 0; };
47002      const auto unary = [](int x){ return x; };
47003      using nullary_t = decltype(nullary);
47004      using unary_t = decltype(unary);
47005      const auto higher1st = [](nullary_t f){ return f(); };
47006      const auto higher2nd = [unary](nullary_t f1){
47007        return [unary, f1](unary_t f2){ return f2(unary(f1())); };
47008      };
47009      return higher1st(nullary) + higher2nd(nullary)(unary);
47010    }
47011
47012  }
47013
47014  namespace test_variadic_templates
47015  {
47016
47017    template <int...>
47018    struct sum;
47019
47020    template <int N0, int... N1toN>
47021    struct sum<N0, N1toN...>
47022    {
47023      static constexpr auto value = N0 + sum<N1toN...>::value;
47024    };
47025
47026    template <>
47027    struct sum<>
47028    {
47029      static constexpr auto value = 0;
47030    };
47031
47032    static_assert(sum<>::value == 0, "");
47033    static_assert(sum<1>::value == 1, "");
47034    static_assert(sum<23>::value == 23, "");
47035    static_assert(sum<1, 2>::value == 3, "");
47036    static_assert(sum<5, 5, 11>::value == 21, "");
47037    static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
47038
47039  }
47040
47041  // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
47042  // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
47043  // because of this.
47044  namespace test_template_alias_sfinae
47045  {
47046
47047    struct foo {};
47048
47049    template<typename T>
47050    using member = typename T::member_type;
47051
47052    template<typename T>
47053    void func(...) {}
47054
47055    template<typename T>
47056    void func(member<T>*) {}
47057
47058    void test();
47059
47060    void test() { func<foo>(0); }
47061
47062  }
47063
47064}  // namespace cxx11
47065
47066#endif  // __cplusplus >= 201103L
47067
47068
47069
47070_ACEOF
47071if ac_fn_cxx_try_compile "$LINENO"
47072then :
47073  eval $cachevar=yes
47074else $as_nop
47075  eval $cachevar=no
47076fi
47077rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
47078           CXX="$ac_save_CXX"
47079fi
47080eval ac_res=\$$cachevar
47081	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
47082printf "%s\n" "$ac_res" >&6; }
47083      if eval test x\$$cachevar = xyes; then
47084        eval PHP_INTL_STDCXX="$switch"
47085        ac_success=yes
47086        break
47087      fi
47088    done
47089    if test x$ac_success = xyes; then
47090      break
47091    fi
47092  done
47093
47094  ac_ext=c
47095ac_cpp='$CPP $CPPFLAGS'
47096ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47097ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47098ac_compiler_gnu=$ac_cv_c_compiler_gnu
47099
47100  if test x$ax_cxx_compile_cxx11_required = xtrue; then
47101    if test x$ac_success = xno; then
47102      as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
47103    fi
47104  fi
47105  if test x$ac_success = xno; then
47106    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
47107printf "%s\n" "$as_me: No compiler with C++11 support was found" >&6;}
47108  fi
47109
47110
47111  PHP_INTL_CXX_FLAGS="$INTL_COMMON_FLAGS $PHP_INTL_STDCXX $ICU_CXXFLAGS"
47112  if test "$ext_shared" = "no"; then
47113
47114
47115  case ext/intl in
47116  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47117  /*) ac_srcdir=`echo "ext/intl"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47118  *) ac_srcdir="$abs_srcdir/ext/intl/"; ac_bdir="ext/intl/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47119  esac
47120
47121
47122
47123  b_c_pre=$php_c_pre
47124  b_cxx_pre=$php_cxx_pre
47125  b_c_meta=$php_c_meta
47126  b_cxx_meta=$php_cxx_meta
47127  b_c_post=$php_c_post
47128  b_cxx_post=$php_cxx_post
47129  b_lo=$php_lo
47130
47131
47132  old_IFS=$IFS
47133  for ac_src in $PHP_INTL_CXX_SOURCES; do
47134
47135      IFS=.
47136      set $ac_src
47137      ac_obj=$1
47138      IFS=$old_IFS
47139
47140      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47141
47142      case $ac_src in
47143        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47144        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47145        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47146        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47147      esac
47148
47149      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47150
47151    cat >>Makefile.objects<<EOF
47152-include $ac_bdir$ac_obj.dep
47153$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47154	$ac_comp
47155EOF
47156  done
47157
47158
47159  else
47160
47161  case ext/intl in
47162  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47163  /*) ac_srcdir=`echo "ext/intl"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47164  *) ac_srcdir="$abs_srcdir/ext/intl/"; ac_bdir="ext/intl/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47165  esac
47166
47167
47168
47169  b_c_pre=$shared_c_pre
47170  b_cxx_pre=$shared_cxx_pre
47171  b_c_meta=$shared_c_meta
47172  b_cxx_meta=$shared_cxx_meta
47173  b_c_post=$shared_c_post
47174  b_cxx_post=$shared_cxx_post
47175  b_lo=$shared_lo
47176
47177
47178  old_IFS=$IFS
47179  for ac_src in $PHP_INTL_CXX_SOURCES; do
47180
47181      IFS=.
47182      set $ac_src
47183      ac_obj=$1
47184      IFS=$old_IFS
47185
47186      shared_objects_intl="$shared_objects_intl $ac_bdir$ac_obj.lo"
47187
47188      case $ac_src in
47189        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47190        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47191        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47192        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $PHP_INTL_CXX_FLAGS -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47193      esac
47194
47195      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47196
47197    cat >>Makefile.objects<<EOF
47198-include $ac_bdir$ac_obj.dep
47199$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47200	$ac_comp
47201EOF
47202  done
47203
47204  fi
47205
47206
47207
47208    BUILD_DIR="$BUILD_DIR $ext_builddir/collator"
47209
47210
47211
47212
47213    BUILD_DIR="$BUILD_DIR $ext_builddir/converter"
47214
47215
47216
47217
47218    BUILD_DIR="$BUILD_DIR $ext_builddir/common"
47219
47220
47221
47222
47223    BUILD_DIR="$BUILD_DIR $ext_builddir/formatter"
47224
47225
47226
47227
47228    BUILD_DIR="$BUILD_DIR $ext_builddir/normalizer"
47229
47230
47231
47232
47233    BUILD_DIR="$BUILD_DIR $ext_builddir/dateformat"
47234
47235
47236
47237
47238    BUILD_DIR="$BUILD_DIR $ext_builddir/locale"
47239
47240
47241
47242
47243    BUILD_DIR="$BUILD_DIR $ext_builddir/msgformat"
47244
47245
47246
47247
47248    BUILD_DIR="$BUILD_DIR $ext_builddir/grapheme"
47249
47250
47251
47252
47253    BUILD_DIR="$BUILD_DIR $ext_builddir/resourcebundle"
47254
47255
47256
47257
47258    BUILD_DIR="$BUILD_DIR $ext_builddir/transliterator"
47259
47260
47261
47262
47263    BUILD_DIR="$BUILD_DIR $ext_builddir/timezone"
47264
47265
47266
47267
47268    BUILD_DIR="$BUILD_DIR $ext_builddir/calendar"
47269
47270
47271
47272
47273    BUILD_DIR="$BUILD_DIR $ext_builddir/idn"
47274
47275
47276
47277
47278    BUILD_DIR="$BUILD_DIR $ext_builddir/spoofchecker"
47279
47280
47281
47282
47283    BUILD_DIR="$BUILD_DIR $ext_builddir/breakiterator"
47284
47285
47286
47287
47288    BUILD_DIR="$BUILD_DIR $ext_builddir/uchar"
47289
47290
47291fi
47292
47293
47294
47295
47296
47297printf "%s\n" "#define HAVE_JSON 1 " >>confdefs.h
47298
47299
47300  ext_builddir=ext/json
47301  ext_srcdir=$abs_srcdir/ext/json
47302  ext_dir=ext/json
47303
47304  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
47305
47306  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
47307    PHP_JSON_SHARED=no
47308
47309
47310  case $ext_dir in
47311  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47312  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47313  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47314  esac
47315
47316
47317
47318  b_c_pre=$php_c_pre
47319  b_cxx_pre=$php_cxx_pre
47320  b_c_meta=$php_c_meta
47321  b_cxx_meta=$php_cxx_meta
47322  b_c_post=$php_c_post
47323  b_cxx_post=$php_cxx_post
47324  b_lo=$php_lo
47325
47326
47327  old_IFS=$IFS
47328  for ac_src in json.c \
47329	  json_encoder.c \
47330	  json_parser.tab.c \
47331	  json_scanner.c; do
47332
47333      IFS=.
47334      set $ac_src
47335      ac_obj=$1
47336      IFS=$old_IFS
47337
47338      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47339
47340      case $ac_src in
47341        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47342        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47343        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47344        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47345      esac
47346
47347      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47348
47349    cat >>Makefile.objects<<EOF
47350-include $ac_bdir$ac_obj.dep
47351$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47352	$ac_comp
47353EOF
47354  done
47355
47356
47357    EXT_STATIC="$EXT_STATIC json;$ext_dir"
47358    if test "no" != "nocli"; then
47359      EXT_CLI_STATIC="$EXT_CLI_STATIC json;$ext_dir"
47360    fi
47361  else
47362    if test "no" = "shared" || test "no" = "yes"; then
47363      PHP_JSON_SHARED=yes
47364
47365  case $ext_dir in
47366  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47367  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47368  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47369  esac
47370
47371
47372
47373  b_c_pre=$shared_c_pre
47374  b_cxx_pre=$shared_cxx_pre
47375  b_c_meta=$shared_c_meta
47376  b_cxx_meta=$shared_cxx_meta
47377  b_c_post=$shared_c_post
47378  b_cxx_post=$shared_cxx_post
47379  b_lo=$shared_lo
47380
47381
47382  old_IFS=$IFS
47383  for ac_src in json.c \
47384	  json_encoder.c \
47385	  json_parser.tab.c \
47386	  json_scanner.c; do
47387
47388      IFS=.
47389      set $ac_src
47390      ac_obj=$1
47391      IFS=$old_IFS
47392
47393      shared_objects_json="$shared_objects_json $ac_bdir$ac_obj.lo"
47394
47395      case $ac_src in
47396        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47397        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47398        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47399        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47400      esac
47401
47402      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47403
47404    cat >>Makefile.objects<<EOF
47405-include $ac_bdir$ac_obj.dep
47406$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47407	$ac_comp
47408EOF
47409  done
47410
47411
47412  install_modules="install-modules"
47413  suffix=la
47414
47415  case $host_alias in
47416    *aix*)
47417      additional_flags="-Wl,-G"
47418      ;;
47419  esac
47420
47421  if test "x" = "xyes"; then
47422    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/json.$suffix"
47423  else
47424    PHP_MODULES="$PHP_MODULES \$(phplibdir)/json.$suffix"
47425  fi
47426
47427  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_json"
47428
47429  cat >>Makefile.objects<<EOF
47430\$(phplibdir)/json.$suffix: $ext_builddir/json.$suffix
47431	\$(LIBTOOL) --mode=install cp $ext_builddir/json.$suffix \$(phplibdir)
47432
47433$ext_builddir/json.$suffix: \$(shared_objects_json) \$(JSON_SHARED_DEPENDENCIES)
47434	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_json) \$(JSON_SHARED_LIBADD)
47435
47436EOF
47437
47438
47439printf "%s\n" "#define COMPILE_DL_JSON 1" >>confdefs.h
47440
47441    fi
47442  fi
47443
47444  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
47445    PHP_JSON_SHARED=no
47446    case "$PHP_SAPI" in
47447      cgi|embed|phpdbg)
47448
47449
47450  case $ext_dir in
47451  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47452  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47453  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47454  esac
47455
47456
47457
47458  b_c_pre=$php_c_pre
47459  b_cxx_pre=$php_cxx_pre
47460  b_c_meta=$php_c_meta
47461  b_cxx_meta=$php_cxx_meta
47462  b_c_post=$php_c_post
47463  b_cxx_post=$php_cxx_post
47464  b_lo=$php_lo
47465
47466
47467  old_IFS=$IFS
47468  for ac_src in json.c \
47469	  json_encoder.c \
47470	  json_parser.tab.c \
47471	  json_scanner.c; do
47472
47473      IFS=.
47474      set $ac_src
47475      ac_obj=$1
47476      IFS=$old_IFS
47477
47478      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47479
47480      case $ac_src in
47481        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47482        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47483        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47484        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47485      esac
47486
47487      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47488
47489    cat >>Makefile.objects<<EOF
47490-include $ac_bdir$ac_obj.dep
47491$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47492	$ac_comp
47493EOF
47494  done
47495
47496
47497        EXT_STATIC="$EXT_STATIC json;$ext_dir"
47498        ;;
47499      *)
47500
47501
47502  case $ext_dir in
47503  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47504  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47505  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47506  esac
47507
47508
47509
47510  b_c_pre=$php_c_pre
47511  b_cxx_pre=$php_cxx_pre
47512  b_c_meta=$php_c_meta
47513  b_cxx_meta=$php_cxx_meta
47514  b_c_post=$php_c_post
47515  b_cxx_post=$php_cxx_post
47516  b_lo=$php_lo
47517
47518
47519  old_IFS=$IFS
47520  for ac_src in json.c \
47521	  json_encoder.c \
47522	  json_parser.tab.c \
47523	  json_scanner.c; do
47524
47525      IFS=.
47526      set $ac_src
47527      ac_obj=$1
47528      IFS=$old_IFS
47529
47530      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47531
47532      case $ac_src in
47533        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47534        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47535        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47536        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47537      esac
47538
47539      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47540
47541    cat >>Makefile.objects<<EOF
47542-include $ac_bdir$ac_obj.dep
47543$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47544	$ac_comp
47545EOF
47546  done
47547
47548
47549        ;;
47550    esac
47551    EXT_CLI_STATIC="$EXT_CLI_STATIC json;$ext_dir"
47552  fi
47553
47554
47555    BUILD_DIR="$BUILD_DIR $ext_builddir"
47556
47557
47558
47559  if test "$ext_builddir" = "."; then
47560    PHP_PECL_EXTENSION=json
47561
47562  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
47563
47564  fi
47565
47566
47567
47568    header_path=ext/json
47569    for header_file in php_json.h php_json_parser.h php_json_scanner.h; do
47570      hp_hf="$header_path/$header_file"
47571
47572
47573  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
47574
47575  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
47576  if test -n "$unique" && test "`eval $cmd`" = "" ; then
47577    eval "INSTALLHEADERS$unique=set"
47578
47579        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
47580
47581  fi
47582
47583    done
47584
47585
47586
47587  src=$ext_srcdir/Makefile.frag
47588  ac_srcdir=$ext_srcdir
47589  ac_builddir=$ext_builddir
47590  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
47591
47592
47593
47594
47595
47596
47597
47598
47599php_with_ldap=no
47600
47601{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LDAP support" >&5
47602printf %s "checking for LDAP support... " >&6; }
47603
47604# Check whether --with-ldap was given.
47605if test ${with_ldap+y}
47606then :
47607  withval=$with_ldap; PHP_LDAP=$withval
47608else $as_nop
47609
47610  PHP_LDAP=no
47611  test "$PHP_ENABLE_ALL" && PHP_LDAP=$PHP_ENABLE_ALL
47612
47613fi
47614
47615
47616
47617ext_output="yes, shared"
47618ext_shared=yes
47619case $PHP_LDAP in
47620shared,*)
47621  PHP_LDAP=`echo "$PHP_LDAP"|$SED 's/^shared,//'`
47622  ;;
47623shared)
47624  PHP_LDAP=yes
47625  ;;
47626no)
47627  ext_output=no
47628  ext_shared=no
47629  ;;
47630*)
47631  ext_output=yes
47632  ext_shared=no
47633  ;;
47634esac
47635
47636
47637
47638{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
47639printf "%s\n" "$ext_output" >&6; }
47640
47641
47642
47643
47644
47645php_with_ldap_sasl=no
47646
47647{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with LDAP Cyrus SASL support" >&5
47648printf %s "checking whether to build with LDAP Cyrus SASL support... " >&6; }
47649
47650# Check whether --with-ldap-sasl was given.
47651if test ${with_ldap_sasl+y}
47652then :
47653  withval=$with_ldap_sasl; PHP_LDAP_SASL=$withval
47654else $as_nop
47655
47656  PHP_LDAP_SASL=no
47657
47658
47659fi
47660
47661
47662ext_output=$PHP_LDAP_SASL
47663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
47664printf "%s\n" "$ext_output" >&6; }
47665
47666
47667
47668
47669if test "$PHP_LDAP" != "no"; then
47670
47671
47672  ext_builddir=ext/ldap
47673  ext_srcdir=$abs_srcdir/ext/ldap
47674  ext_dir=ext/ldap
47675
47676  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
47677
47678  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
47679    PHP_LDAP_SHARED=no
47680
47681
47682  case $ext_dir in
47683  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47684  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47685  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47686  esac
47687
47688
47689
47690  b_c_pre=$php_c_pre
47691  b_cxx_pre=$php_cxx_pre
47692  b_c_meta=$php_c_meta
47693  b_cxx_meta=$php_cxx_meta
47694  b_c_post=$php_c_post
47695  b_cxx_post=$php_cxx_post
47696  b_lo=$php_lo
47697
47698
47699  old_IFS=$IFS
47700  for ac_src in ldap.c; do
47701
47702      IFS=.
47703      set $ac_src
47704      ac_obj=$1
47705      IFS=$old_IFS
47706
47707      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47708
47709      case $ac_src in
47710        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47711        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47712        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47713        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47714      esac
47715
47716      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47717
47718    cat >>Makefile.objects<<EOF
47719-include $ac_bdir$ac_obj.dep
47720$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47721	$ac_comp
47722EOF
47723  done
47724
47725
47726    EXT_STATIC="$EXT_STATIC ldap;$ext_dir"
47727    if test "$ext_shared" != "nocli"; then
47728      EXT_CLI_STATIC="$EXT_CLI_STATIC ldap;$ext_dir"
47729    fi
47730  else
47731    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
47732      PHP_LDAP_SHARED=yes
47733
47734  case $ext_dir in
47735  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47736  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47737  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47738  esac
47739
47740
47741
47742  b_c_pre=$shared_c_pre
47743  b_cxx_pre=$shared_cxx_pre
47744  b_c_meta=$shared_c_meta
47745  b_cxx_meta=$shared_cxx_meta
47746  b_c_post=$shared_c_post
47747  b_cxx_post=$shared_cxx_post
47748  b_lo=$shared_lo
47749
47750
47751  old_IFS=$IFS
47752  for ac_src in ldap.c; do
47753
47754      IFS=.
47755      set $ac_src
47756      ac_obj=$1
47757      IFS=$old_IFS
47758
47759      shared_objects_ldap="$shared_objects_ldap $ac_bdir$ac_obj.lo"
47760
47761      case $ac_src in
47762        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47763        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47764        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47765        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47766      esac
47767
47768      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47769
47770    cat >>Makefile.objects<<EOF
47771-include $ac_bdir$ac_obj.dep
47772$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47773	$ac_comp
47774EOF
47775  done
47776
47777
47778  install_modules="install-modules"
47779  suffix=la
47780
47781  case $host_alias in
47782    *aix*)
47783      additional_flags="-Wl,-G"
47784      ;;
47785  esac
47786
47787  if test "x" = "xyes"; then
47788    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/ldap.$suffix"
47789  else
47790    PHP_MODULES="$PHP_MODULES \$(phplibdir)/ldap.$suffix"
47791  fi
47792
47793  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_ldap"
47794
47795  cat >>Makefile.objects<<EOF
47796\$(phplibdir)/ldap.$suffix: $ext_builddir/ldap.$suffix
47797	\$(LIBTOOL) --mode=install cp $ext_builddir/ldap.$suffix \$(phplibdir)
47798
47799$ext_builddir/ldap.$suffix: \$(shared_objects_ldap) \$(LDAP_SHARED_DEPENDENCIES)
47800	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_ldap) \$(LDAP_SHARED_LIBADD)
47801
47802EOF
47803
47804
47805printf "%s\n" "#define COMPILE_DL_LDAP 1" >>confdefs.h
47806
47807    fi
47808  fi
47809
47810  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
47811    PHP_LDAP_SHARED=no
47812    case "$PHP_SAPI" in
47813      cgi|embed|phpdbg)
47814
47815
47816  case $ext_dir in
47817  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47818  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47819  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47820  esac
47821
47822
47823
47824  b_c_pre=$php_c_pre
47825  b_cxx_pre=$php_cxx_pre
47826  b_c_meta=$php_c_meta
47827  b_cxx_meta=$php_cxx_meta
47828  b_c_post=$php_c_post
47829  b_cxx_post=$php_cxx_post
47830  b_lo=$php_lo
47831
47832
47833  old_IFS=$IFS
47834  for ac_src in ldap.c; do
47835
47836      IFS=.
47837      set $ac_src
47838      ac_obj=$1
47839      IFS=$old_IFS
47840
47841      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47842
47843      case $ac_src in
47844        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47845        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47846        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47847        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47848      esac
47849
47850      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47851
47852    cat >>Makefile.objects<<EOF
47853-include $ac_bdir$ac_obj.dep
47854$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47855	$ac_comp
47856EOF
47857  done
47858
47859
47860        EXT_STATIC="$EXT_STATIC ldap;$ext_dir"
47861        ;;
47862      *)
47863
47864
47865  case $ext_dir in
47866  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
47867  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
47868  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
47869  esac
47870
47871
47872
47873  b_c_pre=$php_c_pre
47874  b_cxx_pre=$php_cxx_pre
47875  b_c_meta=$php_c_meta
47876  b_cxx_meta=$php_cxx_meta
47877  b_c_post=$php_c_post
47878  b_cxx_post=$php_cxx_post
47879  b_lo=$php_lo
47880
47881
47882  old_IFS=$IFS
47883  for ac_src in ldap.c; do
47884
47885      IFS=.
47886      set $ac_src
47887      ac_obj=$1
47888      IFS=$old_IFS
47889
47890      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
47891
47892      case $ac_src in
47893        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47894        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47895        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
47896        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
47897      esac
47898
47899      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
47900
47901    cat >>Makefile.objects<<EOF
47902-include $ac_bdir$ac_obj.dep
47903$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
47904	$ac_comp
47905EOF
47906  done
47907
47908
47909        ;;
47910    esac
47911    EXT_CLI_STATIC="$EXT_CLI_STATIC ldap;$ext_dir"
47912  fi
47913
47914
47915    BUILD_DIR="$BUILD_DIR $ext_builddir"
47916
47917
47918
47919  if test "$ext_builddir" = "."; then
47920    PHP_PECL_EXTENSION=ldap
47921
47922  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
47923
47924  fi
47925
47926
47927  if test "$PHP_LDAP" = "yes"; then
47928    for i in /usr/local /usr; do
47929
47930  if test -f $i/include/ldap.h; then
47931    LDAP_DIR=$i
47932    LDAP_INCDIR=$i/include
47933    LDAP_LIBDIR=$i/$PHP_LIBDIR
47934  elif test -f $i/ldap/public/ldap.h; then
47935    LDAP_DIR=$i
47936    LDAP_INCDIR=$i/ldap/public
47937    LDAP_LIBDIR=$i/$PHP_LIBDIR
47938  else
47939
47940            # The cast to long int works around a bug in the HP C Compiler
47941# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
47942# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
47943# This bug is HP SR number 8606223364.
47944{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
47945printf %s "checking size of long... " >&6; }
47946if test ${ac_cv_sizeof_long+y}
47947then :
47948  printf %s "(cached) " >&6
47949else $as_nop
47950  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
47951then :
47952
47953else $as_nop
47954  if test "$ac_cv_type_long" = yes; then
47955     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47956printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
47957as_fn_error 77 "cannot compute sizeof (long)
47958See \`config.log' for more details" "$LINENO" 5; }
47959   else
47960     ac_cv_sizeof_long=0
47961   fi
47962fi
47963
47964fi
47965{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
47966printf "%s\n" "$ac_cv_sizeof_long" >&6; }
47967
47968
47969
47970printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
47971
47972
47973    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
47974printf %s "checking if we're at 64-bit platform... " >&6; }
47975    if test "$ac_cv_sizeof_long" -eq 4
47976then :
47977
47978      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
47979printf "%s\n" "no" >&6; }
47980      PHP_OCI8_IC_LIBDIR_SUFFIX=""
47981
47982else $as_nop
47983
47984      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47985printf "%s\n" "yes" >&6; }
47986      PHP_OCI8_IC_LIBDIR_SUFFIX=64
47987
47988fi
47989
47990    OCISDKRPMINC=`echo "$i" | $SED -e 's!^/usr/lib/oracle/\(.*\)/client\('${PHP_OCI8_IC_LIBDIR_SUFFIX}'\)*/lib/*$!/usr/include/oracle/\1/client\2!'`
47991
47992        if test -f $OCISDKRPMINC/ldap.h; then
47993      LDAP_DIR=$i
47994      LDAP_INCDIR=$OCISDKRPMINC
47995      LDAP_LIBDIR=$i
47996        elif test -f $i/sdk/include/ldap.h; then
47997      LDAP_DIR=$i
47998      LDAP_INCDIR=$i/sdk/include
47999      LDAP_LIBDIR=$i
48000    fi
48001  fi
48002
48003    done
48004  else
48005
48006  if test -f $PHP_LDAP/include/ldap.h; then
48007    LDAP_DIR=$PHP_LDAP
48008    LDAP_INCDIR=$PHP_LDAP/include
48009    LDAP_LIBDIR=$PHP_LDAP/$PHP_LIBDIR
48010  elif test -f $PHP_LDAP/ldap/public/ldap.h; then
48011    LDAP_DIR=$PHP_LDAP
48012    LDAP_INCDIR=$PHP_LDAP/ldap/public
48013    LDAP_LIBDIR=$PHP_LDAP/$PHP_LIBDIR
48014  else
48015
48016            # The cast to long int works around a bug in the HP C Compiler
48017# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
48018# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
48019# This bug is HP SR number 8606223364.
48020{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
48021printf %s "checking size of long... " >&6; }
48022if test ${ac_cv_sizeof_long+y}
48023then :
48024  printf %s "(cached) " >&6
48025else $as_nop
48026  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
48027then :
48028
48029else $as_nop
48030  if test "$ac_cv_type_long" = yes; then
48031     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
48032printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
48033as_fn_error 77 "cannot compute sizeof (long)
48034See \`config.log' for more details" "$LINENO" 5; }
48035   else
48036     ac_cv_sizeof_long=0
48037   fi
48038fi
48039
48040fi
48041{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
48042printf "%s\n" "$ac_cv_sizeof_long" >&6; }
48043
48044
48045
48046printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
48047
48048
48049    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
48050printf %s "checking if we're at 64-bit platform... " >&6; }
48051    if test "$ac_cv_sizeof_long" -eq 4
48052then :
48053
48054      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
48055printf "%s\n" "no" >&6; }
48056      PHP_OCI8_IC_LIBDIR_SUFFIX=""
48057
48058else $as_nop
48059
48060      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48061printf "%s\n" "yes" >&6; }
48062      PHP_OCI8_IC_LIBDIR_SUFFIX=64
48063
48064fi
48065
48066    OCISDKRPMINC=`echo "$PHP_LDAP" | $SED -e 's!^/usr/lib/oracle/\(.*\)/client\('${PHP_OCI8_IC_LIBDIR_SUFFIX}'\)*/lib/*$!/usr/include/oracle/\1/client\2!'`
48067
48068        if test -f $OCISDKRPMINC/ldap.h; then
48069      LDAP_DIR=$PHP_LDAP
48070      LDAP_INCDIR=$OCISDKRPMINC
48071      LDAP_LIBDIR=$PHP_LDAP
48072        elif test -f $PHP_LDAP/sdk/include/ldap.h; then
48073      LDAP_DIR=$PHP_LDAP
48074      LDAP_INCDIR=$PHP_LDAP/sdk/include
48075      LDAP_LIBDIR=$PHP_LDAP
48076    fi
48077  fi
48078
48079  fi
48080
48081  if test -z "$LDAP_DIR"; then
48082    as_fn_error $? "Cannot find ldap.h" "$LINENO" 5
48083  fi
48084
48085    MACHINE_INCLUDES=$($CC -dumpmachine | $SED 's/-pc//')
48086
48087  if test -f $LDAP_LIBDIR/liblber.a || test -f $LDAP_LIBDIR/liblber.$SHLIB_SUFFIX_NAME || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/liblber.a || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/liblber.$SHLIB_SUFFIX_NAME; then
48088
48089
48090  if test "$ext_shared" = "yes"; then
48091    LDAP_SHARED_LIBADD="-llber $LDAP_SHARED_LIBADD"
48092    if test -n "$LDAP_LIBDIR"; then
48093
48094  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48095
48096  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48097    ai_p=$LDAP_LIBDIR
48098  else
48099
48100    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48101
48102    ep_realdir=`(cd "$ep_dir" && pwd)`
48103    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48104  fi
48105
48106
48107      if test "$ext_shared" = "yes"; then
48108        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48109        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48110      else
48111
48112
48113
48114  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48115
48116  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48117  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48118    eval "LIBPATH$unique=set"
48119
48120    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48121    LDFLAGS="$LDFLAGS -L$ai_p"
48122    PHP_RPATHS="$PHP_RPATHS $ai_p"
48123
48124  fi
48125
48126
48127      fi
48128
48129  fi
48130
48131    fi
48132  else
48133
48134
48135  if test -n "$LDAP_LIBDIR"; then
48136
48137  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48138
48139  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48140    ai_p=$LDAP_LIBDIR
48141  else
48142
48143    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48144
48145    ep_realdir=`(cd "$ep_dir" && pwd)`
48146    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48147  fi
48148
48149
48150
48151
48152
48153  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48154
48155  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48156  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48157    eval "LIBPATH$unique=set"
48158
48159    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48160    LDFLAGS="$LDFLAGS -L$ai_p"
48161    PHP_RPATHS="$PHP_RPATHS $ai_p"
48162
48163  fi
48164
48165
48166
48167  fi
48168
48169  fi
48170
48171
48172  case lber in
48173  c|c_r) ;;
48174  *)
48175      LIBS="-llber $LIBS"
48176   ;;
48177  esac
48178
48179
48180
48181
48182  fi
48183
48184
48185
48186
48187  if test "$ext_shared" = "yes"; then
48188    LDAP_SHARED_LIBADD="-lldap $LDAP_SHARED_LIBADD"
48189    if test -n "$LDAP_LIBDIR"; then
48190
48191  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48192
48193  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48194    ai_p=$LDAP_LIBDIR
48195  else
48196
48197    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48198
48199    ep_realdir=`(cd "$ep_dir" && pwd)`
48200    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48201  fi
48202
48203
48204      if test "$ext_shared" = "yes"; then
48205        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48206        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48207      else
48208
48209
48210
48211  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48212
48213  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48214  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48215    eval "LIBPATH$unique=set"
48216
48217    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48218    LDFLAGS="$LDFLAGS -L$ai_p"
48219    PHP_RPATHS="$PHP_RPATHS $ai_p"
48220
48221  fi
48222
48223
48224      fi
48225
48226  fi
48227
48228    fi
48229  else
48230
48231
48232  if test -n "$LDAP_LIBDIR"; then
48233
48234  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48235
48236  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48237    ai_p=$LDAP_LIBDIR
48238  else
48239
48240    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48241
48242    ep_realdir=`(cd "$ep_dir" && pwd)`
48243    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48244  fi
48245
48246
48247
48248
48249
48250  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48251
48252  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48253  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48254    eval "LIBPATH$unique=set"
48255
48256    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48257    LDFLAGS="$LDFLAGS -L$ai_p"
48258    PHP_RPATHS="$PHP_RPATHS $ai_p"
48259
48260  fi
48261
48262
48263
48264  fi
48265
48266  fi
48267
48268
48269  case ldap in
48270  c|c_r) ;;
48271  *)
48272      LIBS="-lldap $LIBS"
48273   ;;
48274  esac
48275
48276
48277
48278
48279  fi
48280
48281
48282
48283  elif test -f $LDAP_LIBDIR/libldap.$SHLIB_SUFFIX_NAME || test -f $LDAP_LIBDIR/libldap.$SHLIB_SUFFIX_NAME.3 || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/libldap.$SHLIB_SUFFIX_NAME || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/libldap.$SHLIB_SUFFIX_NAME.3 || test -f $LDAP_LIBDIR/libldap.3.dylib; then
48284
48285
48286  if test "$ext_shared" = "yes"; then
48287    LDAP_SHARED_LIBADD="-lldap $LDAP_SHARED_LIBADD"
48288    if test -n "$LDAP_LIBDIR"; then
48289
48290  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48291
48292  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48293    ai_p=$LDAP_LIBDIR
48294  else
48295
48296    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48297
48298    ep_realdir=`(cd "$ep_dir" && pwd)`
48299    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48300  fi
48301
48302
48303      if test "$ext_shared" = "yes"; then
48304        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48305        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48306      else
48307
48308
48309
48310  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48311
48312  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48313  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48314    eval "LIBPATH$unique=set"
48315
48316    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48317    LDFLAGS="$LDFLAGS -L$ai_p"
48318    PHP_RPATHS="$PHP_RPATHS $ai_p"
48319
48320  fi
48321
48322
48323      fi
48324
48325  fi
48326
48327    fi
48328  else
48329
48330
48331  if test -n "$LDAP_LIBDIR"; then
48332
48333  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48334
48335  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48336    ai_p=$LDAP_LIBDIR
48337  else
48338
48339    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48340
48341    ep_realdir=`(cd "$ep_dir" && pwd)`
48342    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48343  fi
48344
48345
48346
48347
48348
48349  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48350
48351  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48352  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48353    eval "LIBPATH$unique=set"
48354
48355    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48356    LDFLAGS="$LDFLAGS -L$ai_p"
48357    PHP_RPATHS="$PHP_RPATHS $ai_p"
48358
48359  fi
48360
48361
48362
48363  fi
48364
48365  fi
48366
48367
48368  case ldap in
48369  c|c_r) ;;
48370  *)
48371      LIBS="-lldap $LIBS"
48372   ;;
48373  esac
48374
48375
48376
48377
48378  fi
48379
48380
48381
48382  elif test -f $LDAP_LIBDIR/libclntsh.$SHLIB_SUFFIX_NAME.12.1 || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/libclntsh.$SHLIB_SUFFIX_NAME.12.1; then
48383
48384
48385  if test "$ext_shared" = "yes"; then
48386    LDAP_SHARED_LIBADD="-lclntsh $LDAP_SHARED_LIBADD"
48387    if test -n "$LDAP_LIBDIR"; then
48388
48389  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48390
48391  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48392    ai_p=$LDAP_LIBDIR
48393  else
48394
48395    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48396
48397    ep_realdir=`(cd "$ep_dir" && pwd)`
48398    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48399  fi
48400
48401
48402      if test "$ext_shared" = "yes"; then
48403        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48404        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48405      else
48406
48407
48408
48409  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48410
48411  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48412  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48413    eval "LIBPATH$unique=set"
48414
48415    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48416    LDFLAGS="$LDFLAGS -L$ai_p"
48417    PHP_RPATHS="$PHP_RPATHS $ai_p"
48418
48419  fi
48420
48421
48422      fi
48423
48424  fi
48425
48426    fi
48427  else
48428
48429
48430  if test -n "$LDAP_LIBDIR"; then
48431
48432  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48433
48434  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48435    ai_p=$LDAP_LIBDIR
48436  else
48437
48438    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48439
48440    ep_realdir=`(cd "$ep_dir" && pwd)`
48441    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48442  fi
48443
48444
48445
48446
48447
48448  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48449
48450  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48451  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48452    eval "LIBPATH$unique=set"
48453
48454    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48455    LDFLAGS="$LDFLAGS -L$ai_p"
48456    PHP_RPATHS="$PHP_RPATHS $ai_p"
48457
48458  fi
48459
48460
48461
48462  fi
48463
48464  fi
48465
48466
48467  case clntsh in
48468  c|c_r) ;;
48469  *)
48470      LIBS="-lclntsh $LIBS"
48471   ;;
48472  esac
48473
48474
48475
48476
48477  fi
48478
48479
48480
48481printf "%s\n" "#define HAVE_ORALDAP 1" >>confdefs.h
48482
48483
48484  elif test -f $LDAP_LIBDIR/libclntsh.$SHLIB_SUFFIX_NAME.11.1 || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/libclntsh.$SHLIB_SUFFIX_NAME.11.1; then
48485
48486
48487  if test "$ext_shared" = "yes"; then
48488    LDAP_SHARED_LIBADD="-lclntsh $LDAP_SHARED_LIBADD"
48489    if test -n "$LDAP_LIBDIR"; then
48490
48491  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48492
48493  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48494    ai_p=$LDAP_LIBDIR
48495  else
48496
48497    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48498
48499    ep_realdir=`(cd "$ep_dir" && pwd)`
48500    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48501  fi
48502
48503
48504      if test "$ext_shared" = "yes"; then
48505        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48506        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48507      else
48508
48509
48510
48511  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48512
48513  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48514  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48515    eval "LIBPATH$unique=set"
48516
48517    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48518    LDFLAGS="$LDFLAGS -L$ai_p"
48519    PHP_RPATHS="$PHP_RPATHS $ai_p"
48520
48521  fi
48522
48523
48524      fi
48525
48526  fi
48527
48528    fi
48529  else
48530
48531
48532  if test -n "$LDAP_LIBDIR"; then
48533
48534  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48535
48536  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48537    ai_p=$LDAP_LIBDIR
48538  else
48539
48540    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48541
48542    ep_realdir=`(cd "$ep_dir" && pwd)`
48543    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48544  fi
48545
48546
48547
48548
48549
48550  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48551
48552  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48553  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48554    eval "LIBPATH$unique=set"
48555
48556    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48557    LDFLAGS="$LDFLAGS -L$ai_p"
48558    PHP_RPATHS="$PHP_RPATHS $ai_p"
48559
48560  fi
48561
48562
48563
48564  fi
48565
48566  fi
48567
48568
48569  case clntsh in
48570  c|c_r) ;;
48571  *)
48572      LIBS="-lclntsh $LIBS"
48573   ;;
48574  esac
48575
48576
48577
48578
48579  fi
48580
48581
48582
48583printf "%s\n" "#define HAVE_ORALDAP 1" >>confdefs.h
48584
48585
48586  elif test -f $LDAP_LIBDIR/libclntsh.$SHLIB_SUFFIX_NAME || test -f $LDAP_LIBDIR/$MACHINE_INCLUDES/libclntsh.$SHLIB_SUFFIX_NAME; then
48587
48588
48589  if test "$ext_shared" = "yes"; then
48590    LDAP_SHARED_LIBADD="-lclntsh $LDAP_SHARED_LIBADD"
48591    if test -n "$LDAP_LIBDIR"; then
48592
48593  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48594
48595  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48596    ai_p=$LDAP_LIBDIR
48597  else
48598
48599    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48600
48601    ep_realdir=`(cd "$ep_dir" && pwd)`
48602    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48603  fi
48604
48605
48606      if test "$ext_shared" = "yes"; then
48607        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
48608        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
48609      else
48610
48611
48612
48613  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48614
48615  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48616  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48617    eval "LIBPATH$unique=set"
48618
48619    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48620    LDFLAGS="$LDFLAGS -L$ai_p"
48621    PHP_RPATHS="$PHP_RPATHS $ai_p"
48622
48623  fi
48624
48625
48626      fi
48627
48628  fi
48629
48630    fi
48631  else
48632
48633
48634  if test -n "$LDAP_LIBDIR"; then
48635
48636  if test "$LDAP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$LDAP_LIBDIR" != "/usr/lib"; then
48637
48638  if test -z "$LDAP_LIBDIR" || echo "$LDAP_LIBDIR" | grep '^/' >/dev/null ; then
48639    ai_p=$LDAP_LIBDIR
48640  else
48641
48642    ep_dir=`echo $LDAP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
48643
48644    ep_realdir=`(cd "$ep_dir" && pwd)`
48645    ai_p="$ep_realdir"/`basename "$LDAP_LIBDIR"`
48646  fi
48647
48648
48649
48650
48651
48652  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48653
48654  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
48655  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48656    eval "LIBPATH$unique=set"
48657
48658    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
48659    LDFLAGS="$LDFLAGS -L$ai_p"
48660    PHP_RPATHS="$PHP_RPATHS $ai_p"
48661
48662  fi
48663
48664
48665
48666  fi
48667
48668  fi
48669
48670
48671  case clntsh in
48672  c|c_r) ;;
48673  *)
48674      LIBS="-lclntsh $LIBS"
48675   ;;
48676  esac
48677
48678
48679
48680
48681  fi
48682
48683
48684
48685printf "%s\n" "#define HAVE_ORALDAP 1" >>confdefs.h
48686
48687
48688  else
48689    as_fn_error $? "Cannot find ldap libraries in $LDAP_LIBDIR." "$LINENO" 5
48690  fi
48691
48692
48693  if test "$LDAP_INCDIR" != "/usr/include"; then
48694
48695  if test -z "$LDAP_INCDIR" || echo "$LDAP_INCDIR" | grep '^/' >/dev/null ; then
48696    ai_p=$LDAP_INCDIR
48697  else
48698
48699    ep_dir=`echo $LDAP_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
48700
48701    ep_realdir=`(cd "$ep_dir" && pwd)`
48702    ai_p="$ep_realdir"/`basename "$LDAP_INCDIR"`
48703  fi
48704
48705
48706
48707  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48708
48709  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
48710  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48711    eval "INCLUDEPATH$unique=set"
48712
48713      if test ""; then
48714        INCLUDES="-I$ai_p $INCLUDES"
48715      else
48716        INCLUDES="$INCLUDES -I$ai_p"
48717      fi
48718
48719  fi
48720
48721  fi
48722
48723
48724  PHP_VAR_SUBST="$PHP_VAR_SUBST LDAP_SHARED_LIBADD"
48725
48726
48727printf "%s\n" "#define HAVE_LDAP 1" >>confdefs.h
48728
48729
48730    _SAVE_CPPFLAGS=$CPPFLAGS
48731  _SAVE_LIBS=$LIBS
48732  CPPFLAGS="$CPPFLAGS -I$LDAP_INCDIR"
48733  LIBS="$LIBS $LDAP_SHARED_LIBADD"
48734
48735    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 3 arg ldap_set_rebind_proc" >&5
48736printf %s "checking for 3 arg ldap_set_rebind_proc... " >&6; }
48737if test ${ac_cv_3arg_setrebindproc+y}
48738then :
48739  printf %s "(cached) " >&6
48740else $as_nop
48741  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48742/* end confdefs.h.  */
48743#include <ldap.h>
48744int
48745main (void)
48746{
48747ldap_set_rebind_proc(0,0,0)
48748  ;
48749  return 0;
48750}
48751_ACEOF
48752if ac_fn_c_try_compile "$LINENO"
48753then :
48754  ac_cv_3arg_setrebindproc=yes
48755else $as_nop
48756  ac_cv_3arg_setrebindproc=no
48757fi
48758rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
48759fi
48760{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_3arg_setrebindproc" >&5
48761printf "%s\n" "$ac_cv_3arg_setrebindproc" >&6; }
48762  if test "$ac_cv_3arg_setrebindproc" = yes; then
48763
48764printf "%s\n" "#define HAVE_3ARG_SETREBINDPROC 1" >>confdefs.h
48765
48766  fi
48767
48768      ac_fn_c_check_func "$LINENO" "ldap_parse_result" "ac_cv_func_ldap_parse_result"
48769if test "x$ac_cv_func_ldap_parse_result" = xyes
48770then :
48771  printf "%s\n" "#define HAVE_LDAP_PARSE_RESULT 1" >>confdefs.h
48772
48773fi
48774ac_fn_c_check_func "$LINENO" "ldap_parse_reference" "ac_cv_func_ldap_parse_reference"
48775if test "x$ac_cv_func_ldap_parse_reference" = xyes
48776then :
48777  printf "%s\n" "#define HAVE_LDAP_PARSE_REFERENCE 1" >>confdefs.h
48778
48779fi
48780ac_fn_c_check_func "$LINENO" "ldap_start_tls_s" "ac_cv_func_ldap_start_tls_s"
48781if test "x$ac_cv_func_ldap_start_tls_s" = xyes
48782then :
48783  printf "%s\n" "#define HAVE_LDAP_START_TLS_S 1" >>confdefs.h
48784
48785fi
48786ac_fn_c_check_func "$LINENO" "ldap_control_find" "ac_cv_func_ldap_control_find"
48787if test "x$ac_cv_func_ldap_control_find" = xyes
48788then :
48789  printf "%s\n" "#define HAVE_LDAP_CONTROL_FIND 1" >>confdefs.h
48790
48791fi
48792ac_fn_c_check_func "$LINENO" "ldap_parse_extended_result" "ac_cv_func_ldap_parse_extended_result"
48793if test "x$ac_cv_func_ldap_parse_extended_result" = xyes
48794then :
48795  printf "%s\n" "#define HAVE_LDAP_PARSE_EXTENDED_RESULT 1" >>confdefs.h
48796
48797fi
48798ac_fn_c_check_func "$LINENO" "ldap_extended_operation" "ac_cv_func_ldap_extended_operation"
48799if test "x$ac_cv_func_ldap_extended_operation" = xyes
48800then :
48801  printf "%s\n" "#define HAVE_LDAP_EXTENDED_OPERATION 1" >>confdefs.h
48802
48803fi
48804ac_fn_c_check_func "$LINENO" "ldap_extended_operation_s" "ac_cv_func_ldap_extended_operation_s"
48805if test "x$ac_cv_func_ldap_extended_operation_s" = xyes
48806then :
48807  printf "%s\n" "#define HAVE_LDAP_EXTENDED_OPERATION_S 1" >>confdefs.h
48808
48809fi
48810ac_fn_c_check_func "$LINENO" "ldap_passwd" "ac_cv_func_ldap_passwd"
48811if test "x$ac_cv_func_ldap_passwd" = xyes
48812then :
48813  printf "%s\n" "#define HAVE_LDAP_PASSWD 1" >>confdefs.h
48814
48815fi
48816ac_fn_c_check_func "$LINENO" "ldap_whoami_s" "ac_cv_func_ldap_whoami_s"
48817if test "x$ac_cv_func_ldap_whoami_s" = xyes
48818then :
48819  printf "%s\n" "#define HAVE_LDAP_WHOAMI_S 1" >>confdefs.h
48820
48821fi
48822ac_fn_c_check_func "$LINENO" "ldap_refresh_s" "ac_cv_func_ldap_refresh_s"
48823if test "x$ac_cv_func_ldap_refresh_s" = xyes
48824then :
48825  printf "%s\n" "#define HAVE_LDAP_REFRESH_S 1" >>confdefs.h
48826
48827fi
48828
48829
48830    if test "$PHP_LDAP_SASL" != "no"; then
48831
48832pkg_failed=no
48833{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsasl2" >&5
48834printf %s "checking for libsasl2... " >&6; }
48835
48836if test -n "$SASL_CFLAGS"; then
48837    pkg_cv_SASL_CFLAGS="$SASL_CFLAGS"
48838 elif test -n "$PKG_CONFIG"; then
48839    if test -n "$PKG_CONFIG" && \
48840    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsasl2\""; } >&5
48841  ($PKG_CONFIG --exists --print-errors "libsasl2") 2>&5
48842  ac_status=$?
48843  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48844  test $ac_status = 0; }; then
48845  pkg_cv_SASL_CFLAGS=`$PKG_CONFIG --cflags "libsasl2" 2>/dev/null`
48846		      test "x$?" != "x0" && pkg_failed=yes
48847else
48848  pkg_failed=yes
48849fi
48850 else
48851    pkg_failed=untried
48852fi
48853if test -n "$SASL_LIBS"; then
48854    pkg_cv_SASL_LIBS="$SASL_LIBS"
48855 elif test -n "$PKG_CONFIG"; then
48856    if test -n "$PKG_CONFIG" && \
48857    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsasl2\""; } >&5
48858  ($PKG_CONFIG --exists --print-errors "libsasl2") 2>&5
48859  ac_status=$?
48860  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48861  test $ac_status = 0; }; then
48862  pkg_cv_SASL_LIBS=`$PKG_CONFIG --libs "libsasl2" 2>/dev/null`
48863		      test "x$?" != "x0" && pkg_failed=yes
48864else
48865  pkg_failed=yes
48866fi
48867 else
48868    pkg_failed=untried
48869fi
48870
48871
48872
48873if test $pkg_failed = yes; then
48874        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
48875printf "%s\n" "no" >&6; }
48876
48877if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
48878        _pkg_short_errors_supported=yes
48879else
48880        _pkg_short_errors_supported=no
48881fi
48882        if test $_pkg_short_errors_supported = yes; then
48883	        SASL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsasl2" 2>&1`
48884        else
48885	        SASL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsasl2" 2>&1`
48886        fi
48887	# Put the nasty error message in config.log where it belongs
48888	echo "$SASL_PKG_ERRORS" >&5
48889
48890	as_fn_error $? "Package requirements (libsasl2) were not met:
48891
48892$SASL_PKG_ERRORS
48893
48894Consider adjusting the PKG_CONFIG_PATH environment variable if you
48895installed software in a non-standard prefix.
48896
48897Alternatively, you may set the environment variables SASL_CFLAGS
48898and SASL_LIBS to avoid the need to call pkg-config.
48899See the pkg-config man page for more details." "$LINENO" 5
48900elif test $pkg_failed = untried; then
48901        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
48902printf "%s\n" "no" >&6; }
48903	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
48904printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
48905as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
48906is in your PATH or set the PKG_CONFIG environment variable to the full
48907path to pkg-config.
48908
48909Alternatively, you may set the environment variables SASL_CFLAGS
48910and SASL_LIBS to avoid the need to call pkg-config.
48911See the pkg-config man page for more details.
48912
48913To get pkg-config, see <http://pkg-config.freedesktop.org/>.
48914See \`config.log' for more details" "$LINENO" 5; }
48915else
48916	SASL_CFLAGS=$pkg_cv_SASL_CFLAGS
48917	SASL_LIBS=$pkg_cv_SASL_LIBS
48918        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48919printf "%s\n" "yes" >&6; }
48920
48921fi
48922
48923
48924  for ac_i in $SASL_CFLAGS; do
48925    case $ac_i in
48926    -I*)
48927      ac_ii=`echo $ac_i|cut -c 3-`
48928
48929  if test "$ac_ii" != "/usr/include"; then
48930
48931  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
48932    ai_p=$ac_ii
48933  else
48934
48935    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
48936
48937    ep_realdir=`(cd "$ep_dir" && pwd)`
48938    ai_p="$ep_realdir"/`basename "$ac_ii"`
48939  fi
48940
48941
48942
48943  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
48944
48945  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
48946  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48947    eval "INCLUDEPATH$unique=set"
48948
48949      if test ""; then
48950        INCLUDES="-I$ai_p $INCLUDES"
48951      else
48952        INCLUDES="$INCLUDES -I$ai_p"
48953      fi
48954
48955  fi
48956
48957  fi
48958
48959    ;;
48960    esac
48961  done
48962
48963
48964  for ac_i in $SASL_LIBS; do
48965    case $ac_i in
48966    -pthread)
48967      if test "$ext_shared" = "yes"; then
48968        LDAP_SHARED_LIBADD="$LDAP_SHARED_LIBADD -pthread"
48969      else
48970
48971
48972  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
48973
48974  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
48975  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48976    eval "EXTRA_LDFLAGS$unique=set"
48977    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
48978  fi
48979
48980
48981
48982  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
48983
48984  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
48985  if test -n "$unique" && test "`eval $cmd`" = "" ; then
48986    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
48987    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
48988  fi
48989
48990      fi
48991    ;;
48992    -l*)
48993      ac_ii=`echo $ac_i|cut -c 3-`
48994
48995
48996  case $ac_ii in
48997  c|c_r) ;;
48998  *)
48999    if test "$ext_shared" = "yes"; then
49000        LDAP_SHARED_LIBADD="$LDAP_SHARED_LIBADD -l$ac_ii"
49001    else
49002
49003
49004  case $ac_ii in
49005  c|c_r) ;;
49006  *)
49007      LIBS="$LIBS -l$ac_ii"
49008   ;;
49009  esac
49010
49011
49012    fi
49013   ;;
49014  esac
49015
49016
49017    ;;
49018    -L*)
49019      ac_ii=`echo $ac_i|cut -c 3-`
49020
49021  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
49022
49023  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
49024    ai_p=$ac_ii
49025  else
49026
49027    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
49028
49029    ep_realdir=`(cd "$ep_dir" && pwd)`
49030    ai_p="$ep_realdir"/`basename "$ac_ii"`
49031  fi
49032
49033
49034      if test "$ext_shared" = "yes"; then
49035        LDAP_SHARED_LIBADD="-L$ai_p $LDAP_SHARED_LIBADD"
49036        test -n "$ld_runpath_switch" && LDAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $LDAP_SHARED_LIBADD"
49037      else
49038
49039
49040
49041  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49042
49043  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
49044  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49045    eval "LIBPATH$unique=set"
49046
49047    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
49048    LDFLAGS="$LDFLAGS -L$ai_p"
49049    PHP_RPATHS="$PHP_RPATHS $ai_p"
49050
49051  fi
49052
49053
49054      fi
49055
49056  fi
49057
49058    ;;
49059    esac
49060  done
49061
49062
49063
49064printf "%s\n" "#define HAVE_LDAP_SASL 1" >>confdefs.h
49065
49066  fi
49067
49068    ac_fn_c_check_func "$LINENO" "ldap_bind_s" "ac_cv_func_ldap_bind_s"
49069if test "x$ac_cv_func_ldap_bind_s" = xyes
49070then :
49071
49072else $as_nop
49073
49074    as_fn_error $? "LDAP build check failed. Please check config.log for more information." "$LINENO" 5
49075
49076fi
49077
49078
49079    CPPFLAGS=$_SAVE_CPPFLAGS
49080  LIBS=$_SAVE_LIBS
49081fi
49082
49083
49084
49085
49086
49087
49088
49089
49090
49091
49092
49093
49094
49095
49096
49097
49098
49099
49100
49101
49102
49103
49104
49105
49106php_enable_mbstring=no
49107
49108{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable multibyte string support" >&5
49109printf %s "checking whether to enable multibyte string support... " >&6; }
49110# Check whether --enable-mbstring was given.
49111if test ${enable_mbstring+y}
49112then :
49113  enableval=$enable_mbstring; PHP_MBSTRING=$enableval
49114else $as_nop
49115
49116  PHP_MBSTRING=no
49117  test "$PHP_ENABLE_ALL" && PHP_MBSTRING=$PHP_ENABLE_ALL
49118
49119fi
49120
49121
49122
49123ext_output="yes, shared"
49124ext_shared=yes
49125case $PHP_MBSTRING in
49126shared,*)
49127  PHP_MBSTRING=`echo "$PHP_MBSTRING"|$SED 's/^shared,//'`
49128  ;;
49129shared)
49130  PHP_MBSTRING=yes
49131  ;;
49132no)
49133  ext_output=no
49134  ext_shared=no
49135  ;;
49136*)
49137  ext_output=yes
49138  ext_shared=no
49139  ;;
49140esac
49141
49142
49143
49144{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
49145printf "%s\n" "$ext_output" >&6; }
49146
49147
49148
49149
49150
49151php_enable_mbregex=yes
49152
49153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable multibyte regex support (requires oniguruma)" >&5
49154printf %s "checking whether to enable multibyte regex support (requires oniguruma)... " >&6; }
49155# Check whether --enable-mbregex was given.
49156if test ${enable_mbregex+y}
49157then :
49158  enableval=$enable_mbregex; PHP_MBREGEX=$enableval
49159else $as_nop
49160
49161  PHP_MBREGEX=yes
49162
49163
49164fi
49165
49166
49167ext_output=$PHP_MBREGEX
49168{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
49169printf "%s\n" "$ext_output" >&6; }
49170
49171
49172
49173
49174if test "$PHP_MBSTRING" != "no"; then
49175
49176printf "%s\n" "#define HAVE_MBSTRING 1" >>confdefs.h
49177
49178
49179
49180  PHP_MBSTRING_BASE_SOURCES="$PHP_MBSTRING_BASE_SOURCES mbstring.c php_unicode.c mb_gpc.c"
49181
49182
49183  if test "$PHP_MBREGEX" != "no"; then
49184
49185  if test "$PHP_MBREGEX" = "yes"; then
49186
49187pkg_failed=no
49188{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for oniguruma" >&5
49189printf %s "checking for oniguruma... " >&6; }
49190
49191if test -n "$ONIG_CFLAGS"; then
49192    pkg_cv_ONIG_CFLAGS="$ONIG_CFLAGS"
49193 elif test -n "$PKG_CONFIG"; then
49194    if test -n "$PKG_CONFIG" && \
49195    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"oniguruma\""; } >&5
49196  ($PKG_CONFIG --exists --print-errors "oniguruma") 2>&5
49197  ac_status=$?
49198  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49199  test $ac_status = 0; }; then
49200  pkg_cv_ONIG_CFLAGS=`$PKG_CONFIG --cflags "oniguruma" 2>/dev/null`
49201		      test "x$?" != "x0" && pkg_failed=yes
49202else
49203  pkg_failed=yes
49204fi
49205 else
49206    pkg_failed=untried
49207fi
49208if test -n "$ONIG_LIBS"; then
49209    pkg_cv_ONIG_LIBS="$ONIG_LIBS"
49210 elif test -n "$PKG_CONFIG"; then
49211    if test -n "$PKG_CONFIG" && \
49212    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"oniguruma\""; } >&5
49213  ($PKG_CONFIG --exists --print-errors "oniguruma") 2>&5
49214  ac_status=$?
49215  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49216  test $ac_status = 0; }; then
49217  pkg_cv_ONIG_LIBS=`$PKG_CONFIG --libs "oniguruma" 2>/dev/null`
49218		      test "x$?" != "x0" && pkg_failed=yes
49219else
49220  pkg_failed=yes
49221fi
49222 else
49223    pkg_failed=untried
49224fi
49225
49226
49227
49228if test $pkg_failed = yes; then
49229        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
49230printf "%s\n" "no" >&6; }
49231
49232if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
49233        _pkg_short_errors_supported=yes
49234else
49235        _pkg_short_errors_supported=no
49236fi
49237        if test $_pkg_short_errors_supported = yes; then
49238	        ONIG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "oniguruma" 2>&1`
49239        else
49240	        ONIG_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "oniguruma" 2>&1`
49241        fi
49242	# Put the nasty error message in config.log where it belongs
49243	echo "$ONIG_PKG_ERRORS" >&5
49244
49245	as_fn_error $? "Package requirements (oniguruma) were not met:
49246
49247$ONIG_PKG_ERRORS
49248
49249Consider adjusting the PKG_CONFIG_PATH environment variable if you
49250installed software in a non-standard prefix.
49251
49252Alternatively, you may set the environment variables ONIG_CFLAGS
49253and ONIG_LIBS to avoid the need to call pkg-config.
49254See the pkg-config man page for more details." "$LINENO" 5
49255elif test $pkg_failed = untried; then
49256        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
49257printf "%s\n" "no" >&6; }
49258	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
49259printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
49260as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
49261is in your PATH or set the PKG_CONFIG environment variable to the full
49262path to pkg-config.
49263
49264Alternatively, you may set the environment variables ONIG_CFLAGS
49265and ONIG_LIBS to avoid the need to call pkg-config.
49266See the pkg-config man page for more details.
49267
49268To get pkg-config, see <http://pkg-config.freedesktop.org/>.
49269See \`config.log' for more details" "$LINENO" 5; }
49270else
49271	ONIG_CFLAGS=$pkg_cv_ONIG_CFLAGS
49272	ONIG_LIBS=$pkg_cv_ONIG_LIBS
49273        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49274printf "%s\n" "yes" >&6; }
49275
49276fi
49277
49278  for ac_i in $ONIG_LIBS; do
49279    case $ac_i in
49280    -pthread)
49281      if test "$ext_shared" = "yes"; then
49282        MBSTRING_SHARED_LIBADD="$MBSTRING_SHARED_LIBADD -pthread"
49283      else
49284
49285
49286  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
49287
49288  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
49289  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49290    eval "EXTRA_LDFLAGS$unique=set"
49291    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
49292  fi
49293
49294
49295
49296  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
49297
49298  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
49299  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49300    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
49301    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
49302  fi
49303
49304      fi
49305    ;;
49306    -l*)
49307      ac_ii=`echo $ac_i|cut -c 3-`
49308
49309
49310  case $ac_ii in
49311  c|c_r) ;;
49312  *)
49313    if test "$ext_shared" = "yes"; then
49314        MBSTRING_SHARED_LIBADD="$MBSTRING_SHARED_LIBADD -l$ac_ii"
49315    else
49316
49317
49318  case $ac_ii in
49319  c|c_r) ;;
49320  *)
49321      LIBS="$LIBS -l$ac_ii"
49322   ;;
49323  esac
49324
49325
49326    fi
49327   ;;
49328  esac
49329
49330
49331    ;;
49332    -L*)
49333      ac_ii=`echo $ac_i|cut -c 3-`
49334
49335  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
49336
49337  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
49338    ai_p=$ac_ii
49339  else
49340
49341    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
49342
49343    ep_realdir=`(cd "$ep_dir" && pwd)`
49344    ai_p="$ep_realdir"/`basename "$ac_ii"`
49345  fi
49346
49347
49348      if test "$ext_shared" = "yes"; then
49349        MBSTRING_SHARED_LIBADD="-L$ai_p $MBSTRING_SHARED_LIBADD"
49350        test -n "$ld_runpath_switch" && MBSTRING_SHARED_LIBADD="$ld_runpath_switch$ai_p $MBSTRING_SHARED_LIBADD"
49351      else
49352
49353
49354
49355  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49356
49357  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
49358  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49359    eval "LIBPATH$unique=set"
49360
49361    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
49362    LDFLAGS="$LDFLAGS -L$ai_p"
49363    PHP_RPATHS="$PHP_RPATHS $ai_p"
49364
49365  fi
49366
49367
49368      fi
49369
49370  fi
49371
49372    ;;
49373    esac
49374  done
49375
49376
49377  for ac_i in $ONIG_CFLAGS; do
49378    case $ac_i in
49379    -I*)
49380      ac_ii=`echo $ac_i|cut -c 3-`
49381
49382  if test "$ac_ii" != "/usr/include"; then
49383
49384  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
49385    ai_p=$ac_ii
49386  else
49387
49388    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
49389
49390    ep_realdir=`(cd "$ep_dir" && pwd)`
49391    ai_p="$ep_realdir"/`basename "$ac_ii"`
49392  fi
49393
49394
49395
49396  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49397
49398  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
49399  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49400    eval "INCLUDEPATH$unique=set"
49401
49402      if test ""; then
49403        INCLUDES="-I$ai_p $INCLUDES"
49404      else
49405        INCLUDES="$INCLUDES -I$ai_p"
49406      fi
49407
49408  fi
49409
49410  fi
49411
49412    ;;
49413    esac
49414  done
49415
49416
49417    save_old_LDFLAGS=$LDFLAGS
49418
49419  for ac_i in $MBSTRING_SHARED_LIBADD; do
49420    case $ac_i in
49421    -pthread)
49422      if test "$ext_shared" = "yes"; then
49423        LDFLAGS="$LDFLAGS -pthread"
49424      else
49425
49426
49427  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
49428
49429  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
49430  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49431    eval "EXTRA_LDFLAGS$unique=set"
49432    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
49433  fi
49434
49435
49436
49437  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
49438
49439  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
49440  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49441    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
49442    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
49443  fi
49444
49445      fi
49446    ;;
49447    -l*)
49448      ac_ii=`echo $ac_i|cut -c 3-`
49449
49450
49451  case $ac_ii in
49452  c|c_r) ;;
49453  *)
49454    if test "$ext_shared" = "yes"; then
49455        LDFLAGS="$LDFLAGS -l$ac_ii"
49456    else
49457
49458
49459  case $ac_ii in
49460  c|c_r) ;;
49461  *)
49462      LIBS="$LIBS -l$ac_ii"
49463   ;;
49464  esac
49465
49466
49467    fi
49468   ;;
49469  esac
49470
49471
49472    ;;
49473    -L*)
49474      ac_ii=`echo $ac_i|cut -c 3-`
49475
49476  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
49477
49478  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
49479    ai_p=$ac_ii
49480  else
49481
49482    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
49483
49484    ep_realdir=`(cd "$ep_dir" && pwd)`
49485    ai_p="$ep_realdir"/`basename "$ac_ii"`
49486  fi
49487
49488
49489      if test "$ext_shared" = "yes"; then
49490        LDFLAGS="-L$ai_p $LDFLAGS"
49491        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
49492      else
49493
49494
49495
49496  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49497
49498  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
49499  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49500    eval "LIBPATH$unique=set"
49501
49502    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
49503    LDFLAGS="$LDFLAGS -L$ai_p"
49504    PHP_RPATHS="$PHP_RPATHS $ai_p"
49505
49506  fi
49507
49508
49509      fi
49510
49511  fi
49512
49513    ;;
49514    esac
49515  done
49516
49517    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if oniguruma has an invalid entry for KOI8 encoding" >&5
49518printf %s "checking if oniguruma has an invalid entry for KOI8 encoding... " >&6; }
49519    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49520/* end confdefs.h.  */
49521
49522#include <oniguruma.h>
49523
49524int
49525main (void)
49526{
49527
49528return (int)(ONIG_ENCODING_KOI8 + 1);
49529
49530  ;
49531  return 0;
49532}
49533_ACEOF
49534if ac_fn_c_try_link "$LINENO"
49535then :
49536
49537      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
49538printf "%s\n" "no" >&6; }
49539
49540else $as_nop
49541
49542      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49543printf "%s\n" "yes" >&6; }
49544
49545printf "%s\n" "#define PHP_ONIG_BAD_KOI8_ENTRY 1" >>confdefs.h
49546
49547
49548fi
49549rm -f core conftest.err conftest.$ac_objext conftest.beam \
49550    conftest$ac_exeext conftest.$ac_ext
49551    LDFLAGS=$save_old_LDFLAGS
49552
49553
49554  PHP_MBSTRING_CFLAGS="$PHP_MBSTRING_CFLAGS -DONIG_ESCAPE_UCHAR_COLLISION=1"
49555
49556
49557  PHP_MBSTRING_CFLAGS="$PHP_MBSTRING_CFLAGS -DUChar=OnigUChar"
49558
49559
49560
49561printf "%s\n" "#define HAVE_MBREGEX 1" >>confdefs.h
49562
49563
49564
49565  PHP_MBSTRING_BASE_SOURCES="$PHP_MBSTRING_BASE_SOURCES php_mbregex.c"
49566
49567
49568  PHP_MBSTRING_INSTALL_HEADERS="$PHP_MBSTRING_INSTALL_HEADERS php_mbregex.h php_onig_compat.h"
49569
49570  fi
49571
49572  fi
49573
49574
49575
49576  PHP_MBSTRING_EXTRA_BUILD_DIRS="$PHP_MBSTRING_EXTRA_BUILD_DIRS libmbfl"
49577
49578
49579  PHP_MBSTRING_EXTRA_BUILD_DIRS="$PHP_MBSTRING_EXTRA_BUILD_DIRS libmbfl/mbfl"
49580
49581
49582  PHP_MBSTRING_EXTRA_BUILD_DIRS="$PHP_MBSTRING_EXTRA_BUILD_DIRS libmbfl/filters"
49583
49584
49585  PHP_MBSTRING_EXTRA_BUILD_DIRS="$PHP_MBSTRING_EXTRA_BUILD_DIRS libmbfl/nls"
49586
49587
49588  PHP_MBSTRING_EXTRA_INCLUDES="$PHP_MBSTRING_EXTRA_INCLUDES libmbfl"
49589
49590
49591  PHP_MBSTRING_EXTRA_INCLUDES="$PHP_MBSTRING_EXTRA_INCLUDES libmbfl/mbfl"
49592
49593
49594
49595  PHP_MBSTRING_SOURCES="$PHP_MBSTRING_SOURCES
49596    libmbfl/filters/html_entities.c
49597    libmbfl/filters/mbfilter_7bit.c
49598    libmbfl/filters/mbfilter_base64.c
49599    libmbfl/filters/mbfilter_big5.c
49600    libmbfl/filters/mbfilter_cp5022x.c
49601    libmbfl/filters/mbfilter_cp51932.c
49602    libmbfl/filters/mbfilter_cp932.c
49603    libmbfl/filters/mbfilter_cp936.c
49604    libmbfl/filters/mbfilter_gb18030.c
49605    libmbfl/filters/mbfilter_euc_cn.c
49606    libmbfl/filters/mbfilter_euc_jp.c
49607    libmbfl/filters/mbfilter_euc_jp_2004.c
49608    libmbfl/filters/mbfilter_euc_jp_win.c
49609    libmbfl/filters/mbfilter_euc_kr.c
49610    libmbfl/filters/mbfilter_euc_tw.c
49611    libmbfl/filters/mbfilter_htmlent.c
49612    libmbfl/filters/mbfilter_hz.c
49613    libmbfl/filters/mbfilter_iso2022_jp_ms.c
49614    libmbfl/filters/mbfilter_iso2022jp_2004.c
49615    libmbfl/filters/mbfilter_iso2022jp_mobile.c
49616    libmbfl/filters/mbfilter_iso2022_kr.c
49617    libmbfl/filters/mbfilter_jis.c
49618    libmbfl/filters/mbfilter_qprint.c
49619    libmbfl/filters/mbfilter_singlebyte.c
49620    libmbfl/filters/mbfilter_sjis.c
49621    libmbfl/filters/mbfilter_sjis_mobile.c
49622    libmbfl/filters/mbfilter_sjis_mac.c
49623    libmbfl/filters/mbfilter_sjis_2004.c
49624    libmbfl/filters/mbfilter_tl_jisx0201_jisx0208.c
49625    libmbfl/filters/mbfilter_ucs2.c
49626    libmbfl/filters/mbfilter_ucs4.c
49627    libmbfl/filters/mbfilter_uhc.c
49628    libmbfl/filters/mbfilter_utf16.c
49629    libmbfl/filters/mbfilter_utf32.c
49630    libmbfl/filters/mbfilter_utf7.c
49631    libmbfl/filters/mbfilter_utf7imap.c
49632    libmbfl/filters/mbfilter_utf8.c
49633    libmbfl/filters/mbfilter_utf8_mobile.c
49634    libmbfl/filters/mbfilter_uuencode.c
49635    libmbfl/mbfl/mbfilter.c
49636    libmbfl/mbfl/mbfilter_8bit.c
49637    libmbfl/mbfl/mbfilter_pass.c
49638    libmbfl/mbfl/mbfilter_wchar.c
49639    libmbfl/mbfl/mbfl_convert.c
49640    libmbfl/mbfl/mbfl_encoding.c
49641    libmbfl/mbfl/mbfl_filter_output.c
49642    libmbfl/mbfl/mbfl_language.c
49643    libmbfl/mbfl/mbfl_memory_device.c
49644    libmbfl/mbfl/mbfl_string.c
49645    libmbfl/nls/nls_de.c
49646    libmbfl/nls/nls_en.c
49647    libmbfl/nls/nls_ja.c
49648    libmbfl/nls/nls_kr.c
49649    libmbfl/nls/nls_neutral.c
49650    libmbfl/nls/nls_ru.c
49651    libmbfl/nls/nls_uni.c
49652    libmbfl/nls/nls_zh.c
49653    libmbfl/nls/nls_hy.c
49654    libmbfl/nls/nls_tr.c
49655    libmbfl/nls/nls_ua.c
49656  "
49657
49658
49659  PHP_MBSTRING_INSTALL_HEADERS="$PHP_MBSTRING_INSTALL_HEADERS libmbfl/config.h libmbfl/mbfl/eaw_table.h libmbfl/mbfl/mbfilter.h libmbfl/mbfl/mbfilter_8bit.h libmbfl/mbfl/mbfilter_pass.h libmbfl/mbfl/mbfilter_wchar.h libmbfl/mbfl/mbfl_consts.h libmbfl/mbfl/mbfl_convert.h libmbfl/mbfl/mbfl_defs.h libmbfl/mbfl/mbfl_encoding.h libmbfl/mbfl/mbfl_filter_output.h libmbfl/mbfl/mbfl_language.h libmbfl/mbfl/mbfl_memory_device.h libmbfl/mbfl/mbfl_string.h"
49660
49661
49662
49663
49664  ext_builddir=ext/mbstring
49665  ext_srcdir=$abs_srcdir/ext/mbstring
49666  ext_dir=ext/mbstring
49667
49668  ac_extra=`echo "$PHP_MBSTRING_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
49669
49670  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
49671    PHP_MBSTRING_SHARED=no
49672
49673
49674  case $ext_dir in
49675  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
49676  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
49677  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
49678  esac
49679
49680
49681
49682  b_c_pre=$php_c_pre
49683  b_cxx_pre=$php_cxx_pre
49684  b_c_meta=$php_c_meta
49685  b_cxx_meta=$php_cxx_meta
49686  b_c_post=$php_c_post
49687  b_cxx_post=$php_cxx_post
49688  b_lo=$php_lo
49689
49690
49691  old_IFS=$IFS
49692  for ac_src in $PHP_MBSTRING_BASE_SOURCES $PHP_MBSTRING_SOURCES; do
49693
49694      IFS=.
49695      set $ac_src
49696      ac_obj=$1
49697      IFS=$old_IFS
49698
49699      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
49700
49701      case $ac_src in
49702        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49703        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49704        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49705        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
49706      esac
49707
49708      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
49709
49710    cat >>Makefile.objects<<EOF
49711-include $ac_bdir$ac_obj.dep
49712$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
49713	$ac_comp
49714EOF
49715  done
49716
49717
49718    EXT_STATIC="$EXT_STATIC mbstring;$ext_dir"
49719    if test "$ext_shared" != "nocli"; then
49720      EXT_CLI_STATIC="$EXT_CLI_STATIC mbstring;$ext_dir"
49721    fi
49722  else
49723    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
49724      PHP_MBSTRING_SHARED=yes
49725
49726  case $ext_dir in
49727  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
49728  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
49729  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
49730  esac
49731
49732
49733
49734  b_c_pre=$shared_c_pre
49735  b_cxx_pre=$shared_cxx_pre
49736  b_c_meta=$shared_c_meta
49737  b_cxx_meta=$shared_cxx_meta
49738  b_c_post=$shared_c_post
49739  b_cxx_post=$shared_cxx_post
49740  b_lo=$shared_lo
49741
49742
49743  old_IFS=$IFS
49744  for ac_src in $PHP_MBSTRING_BASE_SOURCES $PHP_MBSTRING_SOURCES; do
49745
49746      IFS=.
49747      set $ac_src
49748      ac_obj=$1
49749      IFS=$old_IFS
49750
49751      shared_objects_mbstring="$shared_objects_mbstring $ac_bdir$ac_obj.lo"
49752
49753      case $ac_src in
49754        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49755        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49756        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49757        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
49758      esac
49759
49760      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
49761
49762    cat >>Makefile.objects<<EOF
49763-include $ac_bdir$ac_obj.dep
49764$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
49765	$ac_comp
49766EOF
49767  done
49768
49769
49770  install_modules="install-modules"
49771  suffix=la
49772
49773  case $host_alias in
49774    *aix*)
49775      additional_flags="-Wl,-G"
49776      ;;
49777  esac
49778
49779  if test "x" = "xyes"; then
49780    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/mbstring.$suffix"
49781  else
49782    PHP_MODULES="$PHP_MODULES \$(phplibdir)/mbstring.$suffix"
49783  fi
49784
49785  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_mbstring"
49786
49787  cat >>Makefile.objects<<EOF
49788\$(phplibdir)/mbstring.$suffix: $ext_builddir/mbstring.$suffix
49789	\$(LIBTOOL) --mode=install cp $ext_builddir/mbstring.$suffix \$(phplibdir)
49790
49791$ext_builddir/mbstring.$suffix: \$(shared_objects_mbstring) \$(MBSTRING_SHARED_DEPENDENCIES)
49792	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_mbstring) \$(MBSTRING_SHARED_LIBADD)
49793
49794EOF
49795
49796
49797printf "%s\n" "#define COMPILE_DL_MBSTRING 1" >>confdefs.h
49798
49799    fi
49800  fi
49801
49802  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
49803    PHP_MBSTRING_SHARED=no
49804    case "$PHP_SAPI" in
49805      cgi|embed|phpdbg)
49806
49807
49808  case $ext_dir in
49809  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
49810  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
49811  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
49812  esac
49813
49814
49815
49816  b_c_pre=$php_c_pre
49817  b_cxx_pre=$php_cxx_pre
49818  b_c_meta=$php_c_meta
49819  b_cxx_meta=$php_cxx_meta
49820  b_c_post=$php_c_post
49821  b_cxx_post=$php_cxx_post
49822  b_lo=$php_lo
49823
49824
49825  old_IFS=$IFS
49826  for ac_src in $PHP_MBSTRING_BASE_SOURCES $PHP_MBSTRING_SOURCES; do
49827
49828      IFS=.
49829      set $ac_src
49830      ac_obj=$1
49831      IFS=$old_IFS
49832
49833      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
49834
49835      case $ac_src in
49836        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49837        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49838        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49839        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
49840      esac
49841
49842      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
49843
49844    cat >>Makefile.objects<<EOF
49845-include $ac_bdir$ac_obj.dep
49846$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
49847	$ac_comp
49848EOF
49849  done
49850
49851
49852        EXT_STATIC="$EXT_STATIC mbstring;$ext_dir"
49853        ;;
49854      *)
49855
49856
49857  case $ext_dir in
49858  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
49859  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
49860  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
49861  esac
49862
49863
49864
49865  b_c_pre=$php_c_pre
49866  b_cxx_pre=$php_cxx_pre
49867  b_c_meta=$php_c_meta
49868  b_cxx_meta=$php_cxx_meta
49869  b_c_post=$php_c_post
49870  b_cxx_post=$php_cxx_post
49871  b_lo=$php_lo
49872
49873
49874  old_IFS=$IFS
49875  for ac_src in $PHP_MBSTRING_BASE_SOURCES $PHP_MBSTRING_SOURCES; do
49876
49877      IFS=.
49878      set $ac_src
49879      ac_obj=$1
49880      IFS=$old_IFS
49881
49882      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
49883
49884      case $ac_src in
49885        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49886        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49887        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
49888        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
49889      esac
49890
49891      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
49892
49893    cat >>Makefile.objects<<EOF
49894-include $ac_bdir$ac_obj.dep
49895$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
49896	$ac_comp
49897EOF
49898  done
49899
49900
49901        ;;
49902    esac
49903    EXT_CLI_STATIC="$EXT_CLI_STATIC mbstring;$ext_dir"
49904  fi
49905
49906
49907    BUILD_DIR="$BUILD_DIR $ext_builddir"
49908
49909
49910
49911  if test "$ext_builddir" = "."; then
49912    PHP_PECL_EXTENSION=mbstring
49913
49914  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
49915
49916  fi
49917
49918
49919  PHP_VAR_SUBST="$PHP_VAR_SUBST MBSTRING_SHARED_LIBADD"
49920
49921
49922  for dir in $PHP_MBSTRING_EXTRA_BUILD_DIRS; do
49923
49924
49925    $php_shtool mkdir -p $ext_builddir/$dir
49926
49927
49928  done
49929
49930  for dir in $PHP_MBSTRING_EXTRA_INCLUDES; do
49931
49932  if test "$ext_srcdir/$dir" != "/usr/include"; then
49933
49934  if test -z "$ext_srcdir/$dir" || echo "$ext_srcdir/$dir" | grep '^/' >/dev/null ; then
49935    ai_p=$ext_srcdir/$dir
49936  else
49937
49938    ep_dir=`echo $ext_srcdir/$dir|$SED 's%/*[^/][^/]*/*$%%'`
49939
49940    ep_realdir=`(cd "$ep_dir" && pwd)`
49941    ai_p="$ep_realdir"/`basename "$ext_srcdir/$dir"`
49942  fi
49943
49944
49945
49946  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49947
49948  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
49949  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49950    eval "INCLUDEPATH$unique=set"
49951
49952      if test ""; then
49953        INCLUDES="-I$ai_p $INCLUDES"
49954      else
49955        INCLUDES="$INCLUDES -I$ai_p"
49956      fi
49957
49958  fi
49959
49960  fi
49961
49962
49963  if test "$ext_builddir/$dir" != "/usr/include"; then
49964
49965  if test -z "$ext_builddir/$dir" || echo "$ext_builddir/$dir" | grep '^/' >/dev/null ; then
49966    ai_p=$ext_builddir/$dir
49967  else
49968
49969    ep_dir=`echo $ext_builddir/$dir|$SED 's%/*[^/][^/]*/*$%%'`
49970
49971    ep_realdir=`(cd "$ep_dir" && pwd)`
49972    ai_p="$ep_realdir"/`basename "$ext_builddir/$dir"`
49973  fi
49974
49975
49976
49977  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
49978
49979  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
49980  if test -n "$unique" && test "`eval $cmd`" = "" ; then
49981    eval "INCLUDEPATH$unique=set"
49982
49983      if test ""; then
49984        INCLUDES="-I$ai_p $INCLUDES"
49985      else
49986        INCLUDES="$INCLUDES -I$ai_p"
49987      fi
49988
49989  fi
49990
49991  fi
49992
49993  done
49994
49995  out="php_config.h"
49996
49997  if test "$ext_shared" != "no" && test -f "$ext_builddir/config.h.in"; then
49998    out="$abs_builddir/config.h"
49999  fi
50000
50001  cat > $ext_builddir/libmbfl/config.h <<EOF
50002#include "$out"
50003EOF
50004
50005
50006  PHP_MBSTRING_INSTALL_HEADERS="$PHP_MBSTRING_INSTALL_HEADERS mbstring.h"
50007
50008
50009
50010    header_path=ext/mbstring
50011    for header_file in $PHP_MBSTRING_INSTALL_HEADERS; do
50012      hp_hf="$header_path/$header_file"
50013
50014
50015  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
50016
50017  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
50018  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50019    eval "INSTALLHEADERS$unique=set"
50020
50021        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
50022
50023  fi
50024
50025    done
50026
50027
50028
50029fi
50030
50031
50032
50033
50034
50035
50036
50037php_with_mysqli=no
50038
50039{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MySQLi support" >&5
50040printf %s "checking for MySQLi support... " >&6; }
50041
50042# Check whether --with-mysqli was given.
50043if test ${with_mysqli+y}
50044then :
50045  withval=$with_mysqli; PHP_MYSQLI=$withval
50046else $as_nop
50047
50048  PHP_MYSQLI=no
50049  test "$PHP_ENABLE_ALL" && PHP_MYSQLI=$PHP_ENABLE_ALL
50050
50051fi
50052
50053
50054
50055ext_output="yes, shared"
50056ext_shared=yes
50057case $PHP_MYSQLI in
50058shared,*)
50059  PHP_MYSQLI=`echo "$PHP_MYSQLI"|$SED 's/^shared,//'`
50060  ;;
50061shared)
50062  PHP_MYSQLI=yes
50063  ;;
50064no)
50065  ext_output=no
50066  ext_shared=no
50067  ;;
50068*)
50069  ext_output=yes
50070  ext_shared=no
50071  ;;
50072esac
50073
50074
50075
50076{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
50077printf "%s\n" "$ext_output" >&6; }
50078
50079
50080
50081
50082
50083php_with_mysql_sock=no
50084
50085{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for specified location of the MySQL UNIX socket" >&5
50086printf %s "checking for specified location of the MySQL UNIX socket... " >&6; }
50087
50088# Check whether --with-mysql-sock was given.
50089if test ${with_mysql_sock+y}
50090then :
50091  withval=$with_mysql_sock; PHP_MYSQL_SOCK=$withval
50092else $as_nop
50093
50094  PHP_MYSQL_SOCK=no
50095
50096
50097fi
50098
50099
50100ext_output=$PHP_MYSQL_SOCK
50101{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
50102printf "%s\n" "$ext_output" >&6; }
50103
50104
50105
50106
50107if test "$PHP_MYSQLI" = "yes" || test "$PHP_MYSQLI" = "mysqlnd"; then
50108    PHP_MYSQLND_ENABLED=yes
50109
50110elif test "$PHP_MYSQLI" != "no"; then
50111
50112  MYSQL_CONFIG=$PHP_MYSQLI
50113
50114  if test -x "$MYSQL_CONFIG" && $MYSQL_CONFIG --libs > /dev/null 2>&1; then
50115    MYSQLI_INCLINE=`$MYSQL_CONFIG --cflags | $SED -e "s/'//g"`
50116    MYSQLI_LIBLINE=`$MYSQL_CONFIG --libs | $SED -e "s/'//g"`
50117  else
50118    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: mysql_config not found" >&5
50119printf "%s\n" "mysql_config not found" >&6; }
50120    as_fn_error $? "Please reinstall the mysql distribution" "$LINENO" 5
50121  fi
50122
50123
50124  for ac_i in $MYSQLI_INCLINE; do
50125    case $ac_i in
50126    -I*)
50127      ac_ii=`echo $ac_i|cut -c 3-`
50128
50129  if test "$ac_ii" != "/usr/include"; then
50130
50131  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
50132    ai_p=$ac_ii
50133  else
50134
50135    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
50136
50137    ep_realdir=`(cd "$ep_dir" && pwd)`
50138    ai_p="$ep_realdir"/`basename "$ac_ii"`
50139  fi
50140
50141
50142
50143  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
50144
50145  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
50146  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50147    eval "INCLUDEPATH$unique=set"
50148
50149      if test ""; then
50150        INCLUDES="-I$ai_p $INCLUDES"
50151      else
50152        INCLUDES="$INCLUDES -I$ai_p"
50153      fi
50154
50155  fi
50156
50157  fi
50158
50159    ;;
50160    esac
50161  done
50162
50163
50164  for ac_i in $MYSQLI_LIBLINE; do
50165    case $ac_i in
50166    -pthread)
50167      if test "$ext_shared" = "yes"; then
50168        MYSQLI_SHARED_LIBADD="$MYSQLI_SHARED_LIBADD -pthread"
50169      else
50170
50171
50172  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
50173
50174  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
50175  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50176    eval "EXTRA_LDFLAGS$unique=set"
50177    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
50178  fi
50179
50180
50181
50182  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
50183
50184  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
50185  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50186    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
50187    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
50188  fi
50189
50190      fi
50191    ;;
50192    -l*)
50193      ac_ii=`echo $ac_i|cut -c 3-`
50194
50195
50196  case $ac_ii in
50197  c|c_r) ;;
50198  *)
50199    if test "$ext_shared" = "yes"; then
50200        MYSQLI_SHARED_LIBADD="$MYSQLI_SHARED_LIBADD -l$ac_ii"
50201    else
50202
50203
50204  case $ac_ii in
50205  c|c_r) ;;
50206  *)
50207      LIBS="$LIBS -l$ac_ii"
50208   ;;
50209  esac
50210
50211
50212    fi
50213   ;;
50214  esac
50215
50216
50217    ;;
50218    -L*)
50219      ac_ii=`echo $ac_i|cut -c 3-`
50220
50221  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
50222
50223  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
50224    ai_p=$ac_ii
50225  else
50226
50227    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
50228
50229    ep_realdir=`(cd "$ep_dir" && pwd)`
50230    ai_p="$ep_realdir"/`basename "$ac_ii"`
50231  fi
50232
50233
50234      if test "$ext_shared" = "yes"; then
50235        MYSQLI_SHARED_LIBADD="-L$ai_p $MYSQLI_SHARED_LIBADD"
50236        test -n "$ld_runpath_switch" && MYSQLI_SHARED_LIBADD="$ld_runpath_switch$ai_p $MYSQLI_SHARED_LIBADD"
50237      else
50238
50239
50240
50241  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
50242
50243  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
50244  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50245    eval "LIBPATH$unique=set"
50246
50247    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
50248    LDFLAGS="$LDFLAGS -L$ai_p"
50249    PHP_RPATHS="$PHP_RPATHS $ai_p"
50250
50251  fi
50252
50253
50254      fi
50255
50256  fi
50257
50258    ;;
50259    esac
50260  done
50261
50262
50263printf "%s\n" "#define HAVE_MYSQLILIB 1" >>confdefs.h
50264
50265fi
50266
50267if test "$PHP_MYSQLI" != "no"; then
50268  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MySQL UNIX socket location" >&5
50269printf %s "checking for MySQL UNIX socket location... " >&6; }
50270  if test "$PHP_MYSQL_SOCK" != "no" && test "$PHP_MYSQL_SOCK" != "yes"; then
50271    MYSQL_SOCK=$PHP_MYSQL_SOCK
50272
50273printf "%s\n" "#define PHP_MYSQL_UNIX_SOCK_ADDR \"$MYSQL_SOCK\"" >>confdefs.h
50274
50275    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MYSQL_SOCK" >&5
50276printf "%s\n" "$MYSQL_SOCK" >&6; }
50277  elif test "$PHP_MYSQL_SOCK" = "yes"; then
50278
50279  for i in  \
50280    /var/run/mysqld/mysqld.sock \
50281    /var/tmp/mysql.sock \
50282    /var/run/mysql/mysql.sock \
50283    /var/lib/mysql/mysql.sock \
50284    /var/mysql/mysql.sock \
50285    /usr/local/mysql/var/mysql.sock \
50286    /Private/tmp/mysql.sock \
50287    /private/tmp/mysql.sock \
50288    /tmp/mysql.sock \
50289  ; do
50290    if test -r $i; then
50291      MYSQL_SOCK=$i
50292      break 2
50293    fi
50294  done
50295
50296  if test -n "$MYSQL_SOCK"; then
50297
50298printf "%s\n" "#define PHP_MYSQL_UNIX_SOCK_ADDR \"$MYSQL_SOCK\"" >>confdefs.h
50299
50300    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MYSQL_SOCK" >&5
50301printf "%s\n" "$MYSQL_SOCK" >&6; }
50302  else
50303    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
50304printf "%s\n" "no" >&6; }
50305  fi
50306
50307  else
50308    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
50309printf "%s\n" "no" >&6; }
50310  fi
50311
50312  mysqli_sources="mysqli.c mysqli_api.c mysqli_prop.c mysqli_nonapi.c \
50313                  mysqli_report.c mysqli_driver.c mysqli_warning.c \
50314                  mysqli_exception.c mysqli_result_iterator.c"
50315
50316  ext_builddir=ext/mysqli
50317  ext_srcdir=$abs_srcdir/ext/mysqli
50318  ext_dir=ext/mysqli
50319
50320  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
50321
50322  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
50323    PHP_MYSQLI_SHARED=no
50324
50325
50326  case $ext_dir in
50327  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
50328  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
50329  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
50330  esac
50331
50332
50333
50334  b_c_pre=$php_c_pre
50335  b_cxx_pre=$php_cxx_pre
50336  b_c_meta=$php_c_meta
50337  b_cxx_meta=$php_cxx_meta
50338  b_c_post=$php_c_post
50339  b_cxx_post=$php_cxx_post
50340  b_lo=$php_lo
50341
50342
50343  old_IFS=$IFS
50344  for ac_src in $mysqli_sources; do
50345
50346      IFS=.
50347      set $ac_src
50348      ac_obj=$1
50349      IFS=$old_IFS
50350
50351      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
50352
50353      case $ac_src in
50354        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50355        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50356        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50357        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
50358      esac
50359
50360      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
50361
50362    cat >>Makefile.objects<<EOF
50363-include $ac_bdir$ac_obj.dep
50364$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
50365	$ac_comp
50366EOF
50367  done
50368
50369
50370    EXT_STATIC="$EXT_STATIC mysqli;$ext_dir"
50371    if test "$ext_shared" != "nocli"; then
50372      EXT_CLI_STATIC="$EXT_CLI_STATIC mysqli;$ext_dir"
50373    fi
50374  else
50375    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
50376      PHP_MYSQLI_SHARED=yes
50377
50378  case $ext_dir in
50379  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
50380  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
50381  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
50382  esac
50383
50384
50385
50386  b_c_pre=$shared_c_pre
50387  b_cxx_pre=$shared_cxx_pre
50388  b_c_meta=$shared_c_meta
50389  b_cxx_meta=$shared_cxx_meta
50390  b_c_post=$shared_c_post
50391  b_cxx_post=$shared_cxx_post
50392  b_lo=$shared_lo
50393
50394
50395  old_IFS=$IFS
50396  for ac_src in $mysqli_sources; do
50397
50398      IFS=.
50399      set $ac_src
50400      ac_obj=$1
50401      IFS=$old_IFS
50402
50403      shared_objects_mysqli="$shared_objects_mysqli $ac_bdir$ac_obj.lo"
50404
50405      case $ac_src in
50406        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50407        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50408        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50409        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
50410      esac
50411
50412      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
50413
50414    cat >>Makefile.objects<<EOF
50415-include $ac_bdir$ac_obj.dep
50416$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
50417	$ac_comp
50418EOF
50419  done
50420
50421
50422  install_modules="install-modules"
50423  suffix=la
50424
50425  case $host_alias in
50426    *aix*)
50427      additional_flags="-Wl,-G"
50428      ;;
50429  esac
50430
50431  if test "x" = "xyes"; then
50432    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/mysqli.$suffix"
50433  else
50434    PHP_MODULES="$PHP_MODULES \$(phplibdir)/mysqli.$suffix"
50435  fi
50436
50437  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_mysqli"
50438
50439  cat >>Makefile.objects<<EOF
50440\$(phplibdir)/mysqli.$suffix: $ext_builddir/mysqli.$suffix
50441	\$(LIBTOOL) --mode=install cp $ext_builddir/mysqli.$suffix \$(phplibdir)
50442
50443$ext_builddir/mysqli.$suffix: \$(shared_objects_mysqli) \$(MYSQLI_SHARED_DEPENDENCIES)
50444	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_mysqli) \$(MYSQLI_SHARED_LIBADD)
50445
50446EOF
50447
50448
50449printf "%s\n" "#define COMPILE_DL_MYSQLI 1" >>confdefs.h
50450
50451    fi
50452  fi
50453
50454  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
50455    PHP_MYSQLI_SHARED=no
50456    case "$PHP_SAPI" in
50457      cgi|embed|phpdbg)
50458
50459
50460  case $ext_dir in
50461  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
50462  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
50463  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
50464  esac
50465
50466
50467
50468  b_c_pre=$php_c_pre
50469  b_cxx_pre=$php_cxx_pre
50470  b_c_meta=$php_c_meta
50471  b_cxx_meta=$php_cxx_meta
50472  b_c_post=$php_c_post
50473  b_cxx_post=$php_cxx_post
50474  b_lo=$php_lo
50475
50476
50477  old_IFS=$IFS
50478  for ac_src in $mysqli_sources; do
50479
50480      IFS=.
50481      set $ac_src
50482      ac_obj=$1
50483      IFS=$old_IFS
50484
50485      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
50486
50487      case $ac_src in
50488        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50489        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50490        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50491        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
50492      esac
50493
50494      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
50495
50496    cat >>Makefile.objects<<EOF
50497-include $ac_bdir$ac_obj.dep
50498$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
50499	$ac_comp
50500EOF
50501  done
50502
50503
50504        EXT_STATIC="$EXT_STATIC mysqli;$ext_dir"
50505        ;;
50506      *)
50507
50508
50509  case $ext_dir in
50510  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
50511  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
50512  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
50513  esac
50514
50515
50516
50517  b_c_pre=$php_c_pre
50518  b_cxx_pre=$php_cxx_pre
50519  b_c_meta=$php_c_meta
50520  b_cxx_meta=$php_cxx_meta
50521  b_c_post=$php_c_post
50522  b_cxx_post=$php_cxx_post
50523  b_lo=$php_lo
50524
50525
50526  old_IFS=$IFS
50527  for ac_src in $mysqli_sources; do
50528
50529      IFS=.
50530      set $ac_src
50531      ac_obj=$1
50532      IFS=$old_IFS
50533
50534      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
50535
50536      case $ac_src in
50537        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50538        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50539        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
50540        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
50541      esac
50542
50543      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
50544
50545    cat >>Makefile.objects<<EOF
50546-include $ac_bdir$ac_obj.dep
50547$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
50548	$ac_comp
50549EOF
50550  done
50551
50552
50553        ;;
50554    esac
50555    EXT_CLI_STATIC="$EXT_CLI_STATIC mysqli;$ext_dir"
50556  fi
50557
50558
50559    BUILD_DIR="$BUILD_DIR $ext_builddir"
50560
50561
50562
50563  if test "$ext_builddir" = "."; then
50564    PHP_PECL_EXTENSION=mysqli
50565
50566  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
50567
50568  fi
50569
50570
50571  PHP_VAR_SUBST="$PHP_VAR_SUBST MYSQLI_SHARED_LIBADD"
50572
50573
50574
50575    for header_file in ext/mysqli/php_mysqli_structs.h; do
50576
50577
50578  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
50579
50580  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
50581  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50582    eval "INSTALLHEADERS$unique=set"
50583
50584        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
50585
50586  fi
50587
50588    done
50589
50590
50591
50592  if test "$PHP_MYSQLI" = "yes" || test "$PHP_MYSQLI" = "mysqlnd"; then
50593
50594  am_i_shared=$PHP_MYSQLI_SHARED
50595  is_it_shared=$PHP_MYSQLND_SHARED
50596  is_it_enabled=$PHP_MYSQLND
50597  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
50598    as_fn_error $? "
50599You've configured extension mysqli to build statically, but it
50600depends on extension mysqlnd, which you've configured to build shared.
50601You either need to build mysqli shared or build mysqlnd statically for the
50602build to be successful.
50603" "$LINENO" 5
50604  fi
50605  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
50606    as_fn_error $? "
50607You've configured extension mysqli, which depends on extension mysqlnd,
50608but you've either not enabled mysqlnd, or have disabled it.
50609" "$LINENO" 5
50610  fi
50611
50612
50613printf "%s\n" "#define MYSQLI_USE_MYSQLND 1" >>confdefs.h
50614
50615
50616
50617    for header_file in ext/mysqli/mysqli_mysqlnd.h; do
50618
50619
50620  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
50621
50622  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
50623  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50624    eval "INSTALLHEADERS$unique=set"
50625
50626        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
50627
50628  fi
50629
50630    done
50631
50632
50633  else
50634
50635
50636    for header_file in ext/mysqli/mysqli_libmysql.h; do
50637
50638
50639  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
50640
50641  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
50642  if test -n "$unique" && test "`eval $cmd`" = "" ; then
50643    eval "INSTALLHEADERS$unique=set"
50644
50645        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
50646
50647  fi
50648
50649    done
50650
50651
50652  fi
50653fi
50654
50655
50656
50657
50658if test -z "$SED"; then
50659  PHP_OCI8_SED="sed";
50660else
50661  PHP_OCI8_SED="$SED";
50662fi
50663
50664PHP_OCI8_TAIL1=`echo a | tail -n1 2>/dev/null`
50665if test "$PHP_OCI8_TAIL1" = "a"; then
50666    PHP_OCI8_TAIL1="tail -n1"
50667else
50668    PHP_OCI8_TAIL1="tail -1"
50669fi
50670
50671
50672
50673
50674
50675
50676
50677
50678
50679
50680php_with_oci8=no
50681
50682{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Oracle Database OCI8 support" >&5
50683printf %s "checking for Oracle Database OCI8 support... " >&6; }
50684
50685# Check whether --with-oci8 was given.
50686if test ${with_oci8+y}
50687then :
50688  withval=$with_oci8; PHP_OCI8=$withval
50689else $as_nop
50690
50691  PHP_OCI8=no
50692  test "$PHP_ENABLE_ALL" && PHP_OCI8=$PHP_ENABLE_ALL
50693
50694fi
50695
50696
50697
50698ext_output="yes, shared"
50699ext_shared=yes
50700case $PHP_OCI8 in
50701shared,*)
50702  PHP_OCI8=`echo "$PHP_OCI8"|$SED 's/^shared,//'`
50703  ;;
50704shared)
50705  PHP_OCI8=yes
50706  ;;
50707no)
50708  ext_output=no
50709  ext_shared=no
50710  ;;
50711*)
50712  ext_output=yes
50713  ext_shared=no
50714  ;;
50715esac
50716
50717
50718
50719{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
50720printf "%s\n" "$ext_output" >&6; }
50721
50722
50723
50724
50725if test "$PHP_OCI8" != "no"; then
50726
50727  if test -z "$PHP_OCI8"; then
50728            as_fn_error $? "Empty parameter value passed to --with-oci8" "$LINENO" 5
50729  fi
50730
50731    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking PHP version" >&5
50732printf %s "checking PHP version... " >&6; }
50733
50734  tmp_version=$PHP_VERSION
50735  if test -z "$tmp_version"; then
50736    if test -z "$PHP_CONFIG"; then
50737      as_fn_error $? "php-config not found" "$LINENO" 5
50738    fi
50739    php_version=`$PHP_CONFIG --version 2>/dev/null|head -n 1|$PHP_OCI8_SED -e 's#\([0-9]\.[0-9]*\.[0-9]*\)\(.*\)#\1#'`
50740  else
50741    php_version=`echo "$tmp_version"|$PHP_OCI8_SED -e 's#\([0-9]\.[0-9]*\.[0-9]*\)\(.*\)#\1#'`
50742  fi
50743
50744  if test -z "$php_version"; then
50745    as_fn_error $? "failed to detect PHP version, please report" "$LINENO" 5
50746  fi
50747
50748  ac_IFS=$IFS
50749  IFS="."
50750  set $php_version
50751  IFS=$ac_IFS
50752  oci8_php_version=`expr $1 \* 1000000 + $2 \* 1000 + $3`
50753
50754  if test "$oci8_php_version" -lt "5002000"; then
50755    as_fn_error $? "You need at least PHP 5.2.0 to be able to use this version of OCI8. PHP $php_version found" "$LINENO" 5
50756  else
50757    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_version, ok" >&5
50758printf "%s\n" "$php_version, ok" >&6; }
50759  fi
50760
50761        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking OCI8 DTrace support" >&5
50762printf %s "checking OCI8 DTrace support... " >&6; }
50763  oci8_do_dtrace="`echo $PHP_OCI8 | cut -d, -f3`"
50764  if test "$PHP_DTRACE" = "yes" -o "$oci8_do_dtrace" = "dtrace" ; then
50765    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
50766printf "%s\n" "yes" >&6; }
50767    if test "$ext_shared" = "no"; then
50768      as_fn_error $? "For DTrace support OCI8 must be configured as a shared extension" "$LINENO" 5
50769    else
50770             for ac_header in sys/sdt.h
50771do :
50772  ac_fn_c_check_header_compile "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default"
50773if test "x$ac_cv_header_sys_sdt_h" = xyes
50774then :
50775  printf "%s\n" "#define HAVE_SYS_SDT_H 1" >>confdefs.h
50776
50777
50778  ac_srcdir=$abs_srcdir/ext/oci8/
50779  ac_bdir=ext/oci8/
50780
50781  ac_provsrc=oci8_dtrace.d
50782
50783  ac_hdrobj=oci8_dtrace_gen.h
50784
50785  old_IFS=$IFS
50786  for ac_src in oci8.c oci8_statement.c; do
50787    IFS=.
50788    set $ac_src
50789    ac_obj=$1
50790    IFS=$old_IFS
50791
50792    OCI8_DTRACE_OBJS="$OCI8_DTRACE_OBJS $ac_bdir$ac_obj.lo"
50793  done;
50794
50795  for ac_lo in $OCI8_DTRACE_OBJS; do
50796    dtrace_oci8_objs="$dtrace_oci8_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
50797  done;
50798
50799  cat>>Makefile.objects<<EOF
50800
50801$abs_srcdir/ext/oci8/$ac_provsrc:;
50802
50803$ac_bdir$ac_hdrobj: $ac_srcdir$ac_provsrc
50804	CFLAGS="\$(CFLAGS_CLEAN)" dtrace -h -C -s $ac_srcdir$ac_provsrc -o \$@.bak && \$(SED) -e 's,PHPOCI_,DTRACE_,g' \$@.bak > \$@
50805
50806\$(OCI8_DTRACE_OBJS): $ac_bdir$ac_hdrobj
50807
50808EOF
50809
50810  case $host_alias in
50811  *solaris*|*linux*)
50812    dtrace_prov_name="`echo $ac_provsrc | $SED -e 's#\(.*\)\/##'`.o"
50813    dtrace_lib_dir="`echo $ac_bdir$ac_provsrc | $SED -e 's#\(.*\)/[^/]*#\1#'`/.libs"
50814    dtrace_d_obj="`echo $ac_bdir$ac_provsrc | $SED -e 's#\(.*\)/\([^/]*\)#\1/.libs/\2#'`.o"
50815    dtrace_nolib_objs='$(OCI8_DTRACE_OBJS:.lo=.o)'
50816    for ac_lo in $OCI8_DTRACE_OBJS; do
50817      dtrace_oci8_lib_objs="$dtrace_oci8_lib_objs `echo $ac_lo | $SED -e 's,\.lo$,.o,' -e 's#\(.*\)\/#\1\/.libs\/#'`"
50818    done;
50819
50820        cat>>Makefile.objects<<EOF
50821$ac_bdir$ac_provsrc.lo: \$(OCI8_DTRACE_OBJS)
50822	echo "# Generated by Makefile for libtool" > \$@
50823	@test -d "$dtrace_lib_dir" || mkdir $dtrace_lib_dir
50824	if CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o $dtrace_d_obj -s $ac_srcdir$ac_provsrc $dtrace_oci8_lib_objs 2> /dev/null && test -f "$dtrace_d_obj"; then \\
50825	  echo "pic_object='.libs/$dtrace_prov_name'" >> \$@ ;\\
50826	else \\
50827	  echo "pic_object='none'" >> \$@ ;\\
50828	fi
50829	if CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o $ac_bdir$ac_provsrc.o -s $ac_srcdir$ac_provsrc $dtrace_nolib_objs 2> /dev/null && test -f "$ac_bdir$ac_provsrc.o"; then \\
50830	  echo "non_pic_object='$dtrace_prov_name'" >> \$@ ;\\
50831	else \\
50832	  echo "non_pic_object='none'" >> \$@ ;\\
50833	fi
50834
50835EOF
50836    ;;
50837  *)
50838    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: OCI8 extension: OCI8 DTrace support is not confirmed on this platform" >&5
50839printf "%s\n" "$as_me: WARNING: OCI8 extension: OCI8 DTrace support is not confirmed on this platform" >&2;}
50840cat>>Makefile.objects<<EOF
50841$ac_bdir$ac_provsrc.o: \$(OCI8_DTRACE_OBJS)
50842	CFLAGS="\$(CFLAGS_CLEAN)" dtrace -G -o \$@ -s $ac_srcdir$ac_provsrc $dtrace_oci8_objs
50843
50844EOF
50845    ;;
50846  esac
50847
50848
50849
50850else $as_nop
50851
50852	 as_fn_error $? "Cannot find sys/sdt.h which is required for DTrace support" "$LINENO" 5
50853
50854fi
50855
50856done
50857
50858  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_DTRACE_OBJS"
50859
50860
50861printf "%s\n" "#define HAVE_OCI8_DTRACE 1" >>confdefs.h
50862
50863                  shared_objects_oci8="$shared_objects_oci8 ext/oci8/oci8_dtrace.d.lo"
50864    fi
50865  else
50866    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
50867printf "%s\n" "no" >&6; }
50868  fi
50869
50870    # The cast to long int works around a bug in the HP C Compiler
50871# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
50872# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
50873# This bug is HP SR number 8606223364.
50874{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
50875printf %s "checking size of long... " >&6; }
50876if test ${ac_cv_sizeof_long+y}
50877then :
50878  printf %s "(cached) " >&6
50879else $as_nop
50880  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
50881then :
50882
50883else $as_nop
50884  if test "$ac_cv_type_long" = yes; then
50885     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
50886printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
50887as_fn_error 77 "cannot compute sizeof (long)
50888See \`config.log' for more details" "$LINENO" 5; }
50889   else
50890     ac_cv_sizeof_long=0
50891   fi
50892fi
50893
50894fi
50895{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
50896printf "%s\n" "$ac_cv_sizeof_long" >&6; }
50897
50898
50899
50900printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
50901
50902
50903  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
50904printf %s "checking if we're at 64-bit platform... " >&6; }
50905  if test "$ac_cv_sizeof_long" -eq 4
50906then :
50907
50908    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
50909printf "%s\n" "no" >&6; }
50910    PHP_OCI8_OH_LIBDIR=lib32
50911    PHP_OCI8_IC_LIBDIR_SUFFIX=""
50912
50913else $as_nop
50914
50915    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
50916printf "%s\n" "yes" >&6; }
50917    PHP_OCI8_OH_LIBDIR=lib
50918    PHP_OCI8_IC_LIBDIR_SUFFIX=64
50919
50920fi
50921
50922
50923  PHP_OCI8_INSTANT_CLIENT="no"
50924
50925            if test "$PHP_OCI8" = "yes" && test -z "$ORACLE_HOME"; then
50926    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: OCI8 extension: ORACLE_HOME is not set, looking for default Oracle Instant Client instead" >&5
50927printf "%s\n" "$as_me: WARNING: OCI8 extension: ORACLE_HOME is not set, looking for default Oracle Instant Client instead" >&2;}
50928    PHP_OCI8=instantclient
50929  fi
50930
50931  if test "`echo $PHP_OCI8`" = "instantclient"; then
50932    PHP_OCI8_INSTANT_CLIENT="yes"
50933  elif test "`echo $PHP_OCI8 | cut -d, -f2`" = "instantclient"; then
50934    PHP_OCI8_INSTANT_CLIENT="`echo $PHP_OCI8 | cut -d, -f3`"
50935    PHP_OCI8="`echo $PHP_OCI8 | cut -d, -f1,4`"
50936    if test "$PHP_OCI8_INSTANT_CLIENT" = ""; then
50937	PHP_OCI8_INSTANT_CLIENT="yes"
50938    fi
50939    if test -z "$PHP_OCI8"; then
50940	PHP_OCI8=yes
50941    fi
50942  elif test "`echo $PHP_OCI8 | cut -d, -f1`" = "instantclient"; then
50943    PHP_OCI8_INSTANT_CLIENT="`echo $PHP_OCI8 | cut -d, -f2`"
50944    PHP_OCI8="`echo $PHP_OCI8 | cut -d, -f3,4`"
50945    if test "$PHP_OCI8_INSTANT_CLIENT" = ""; then
50946	PHP_OCI8_INSTANT_CLIENT="yes"
50947    fi
50948    if test -z "$PHP_OCI8"; then
50949	PHP_OCI8=yes
50950    fi
50951  fi
50952
50953  if test "$PHP_OCI8_INSTANT_CLIENT" = "no"; then
50954
50955    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle ORACLE_HOME install directory" >&5
50956printf %s "checking Oracle ORACLE_HOME install directory... " >&6; }
50957
50958    if test "$PHP_OCI8" = "yes"; then
50959      OCI8_DIR=$ORACLE_HOME
50960    else
50961      OCI8_DIR=$PHP_OCI8
50962    fi
50963    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCI8_DIR" >&5
50964printf "%s\n" "$OCI8_DIR" >&6; }
50965
50966
50967  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking ORACLE_HOME library validity" >&5
50968printf %s "checking ORACLE_HOME library validity... " >&6; }
50969  if test ! -d "$OCI8_DIR"; then
50970    as_fn_error $? "${OCI8_DIR} is not a directory" "$LINENO" 5
50971  fi
50972  if test -d "$OCI8_DIR/lib" && test ! -d "$OCI8_DIR/lib32"; then
50973    OCI8_LIB_DIR=lib
50974  elif test ! -d "$OCI8_DIR/lib" && test -d "$OCI8_DIR/lib32"; then
50975    OCI8_LIB_DIR=lib32
50976  elif test -d "$OCI8_DIR/lib" && test -d "$OCI8_DIR/lib32"; then
50977    OCI8_LIB_DIR=$PHP_OCI8_OH_LIBDIR
50978  else
50979            if test -f "$OCI8_DIR/libociei.$SHLIB_SUFFIX_NAME"; then
50980      as_fn_error $? "Expected an ORACLE_HOME top level directory but ${OCI8_DIR} appears to be an Instant Client directory. Try --with-oci8=instantclient,${OCI8_DIR}" "$LINENO" 5
50981    else
50982      as_fn_error $? "Oracle library directory not found in ${OCI8_DIR}" "$LINENO" 5
50983    fi
50984  fi
50985  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCI8_LIB_DIR" >&5
50986printf "%s\n" "$OCI8_LIB_DIR" >&6; }
50987
50988
50989    if test -d "$OCI8_DIR/rdbms/public"; then
50990
50991  if test "$OCI8_DIR/rdbms/public" != "/usr/include"; then
50992
50993  if test -z "$OCI8_DIR/rdbms/public" || echo "$OCI8_DIR/rdbms/public" | grep '^/' >/dev/null ; then
50994    ai_p=$OCI8_DIR/rdbms/public
50995  else
50996
50997    ep_dir=`echo $OCI8_DIR/rdbms/public|$SED 's%/*[^/][^/]*/*$%%'`
50998
50999    ep_realdir=`(cd "$ep_dir" && pwd)`
51000    ai_p="$ep_realdir"/`basename "$OCI8_DIR/rdbms/public"`
51001  fi
51002
51003
51004
51005  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51006
51007  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51008  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51009    eval "INCLUDEPATH$unique=set"
51010
51011      if test ""; then
51012        INCLUDES="-I$ai_p $INCLUDES"
51013      else
51014        INCLUDES="$INCLUDES -I$ai_p"
51015      fi
51016
51017  fi
51018
51019  fi
51020
51021      OCI8_INCLUDES="$OCI8_INCLUDES -I$OCI8_DIR/rdbms/public"
51022    fi
51023    if test -d "$OCI8_DIR/rdbms/demo"; then
51024
51025  if test "$OCI8_DIR/rdbms/demo" != "/usr/include"; then
51026
51027  if test -z "$OCI8_DIR/rdbms/demo" || echo "$OCI8_DIR/rdbms/demo" | grep '^/' >/dev/null ; then
51028    ai_p=$OCI8_DIR/rdbms/demo
51029  else
51030
51031    ep_dir=`echo $OCI8_DIR/rdbms/demo|$SED 's%/*[^/][^/]*/*$%%'`
51032
51033    ep_realdir=`(cd "$ep_dir" && pwd)`
51034    ai_p="$ep_realdir"/`basename "$OCI8_DIR/rdbms/demo"`
51035  fi
51036
51037
51038
51039  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51040
51041  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51042  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51043    eval "INCLUDEPATH$unique=set"
51044
51045      if test ""; then
51046        INCLUDES="-I$ai_p $INCLUDES"
51047      else
51048        INCLUDES="$INCLUDES -I$ai_p"
51049      fi
51050
51051  fi
51052
51053  fi
51054
51055      OCI8_INCLUDES="$OCI8_INCLUDES -I$OCI8_DIR/rdbms/demo"
51056    fi
51057    if test -d "$OCI8_DIR/network/public"; then
51058
51059  if test "$OCI8_DIR/network/public" != "/usr/include"; then
51060
51061  if test -z "$OCI8_DIR/network/public" || echo "$OCI8_DIR/network/public" | grep '^/' >/dev/null ; then
51062    ai_p=$OCI8_DIR/network/public
51063  else
51064
51065    ep_dir=`echo $OCI8_DIR/network/public|$SED 's%/*[^/][^/]*/*$%%'`
51066
51067    ep_realdir=`(cd "$ep_dir" && pwd)`
51068    ai_p="$ep_realdir"/`basename "$OCI8_DIR/network/public"`
51069  fi
51070
51071
51072
51073  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51074
51075  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51076  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51077    eval "INCLUDEPATH$unique=set"
51078
51079      if test ""; then
51080        INCLUDES="-I$ai_p $INCLUDES"
51081      else
51082        INCLUDES="$INCLUDES -I$ai_p"
51083      fi
51084
51085  fi
51086
51087  fi
51088
51089      OCI8_INCLUDES="$OCI8_INCLUDES -I$OCI8_DIR/network/public"
51090    fi
51091    if test -d "$OCI8_DIR/plsql/public"; then
51092
51093  if test "$OCI8_DIR/plsql/public" != "/usr/include"; then
51094
51095  if test -z "$OCI8_DIR/plsql/public" || echo "$OCI8_DIR/plsql/public" | grep '^/' >/dev/null ; then
51096    ai_p=$OCI8_DIR/plsql/public
51097  else
51098
51099    ep_dir=`echo $OCI8_DIR/plsql/public|$SED 's%/*[^/][^/]*/*$%%'`
51100
51101    ep_realdir=`(cd "$ep_dir" && pwd)`
51102    ai_p="$ep_realdir"/`basename "$OCI8_DIR/plsql/public"`
51103  fi
51104
51105
51106
51107  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51108
51109  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51110  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51111    eval "INCLUDEPATH$unique=set"
51112
51113      if test ""; then
51114        INCLUDES="-I$ai_p $INCLUDES"
51115      else
51116        INCLUDES="$INCLUDES -I$ai_p"
51117      fi
51118
51119  fi
51120
51121  fi
51122
51123      OCI8_INCLUDES="$OCI8_INCLUDES -I$OCI8_DIR/plsql/public"
51124    fi
51125
51126    if test -f "$OCI8_DIR/$OCI8_LIB_DIR/sysliblist"; then
51127
51128  for ac_i in `cat $OCI8_DIR/$OCI8_LIB_DIR/sysliblist`; do
51129    case $ac_i in
51130    -pthread)
51131      if test "$ext_shared" = "yes"; then
51132        OCI8_SYSLIB="$OCI8_SYSLIB -pthread"
51133      else
51134
51135
51136  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51137
51138  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
51139  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51140    eval "EXTRA_LDFLAGS$unique=set"
51141    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
51142  fi
51143
51144
51145
51146  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51147
51148  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
51149  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51150    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
51151    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
51152  fi
51153
51154      fi
51155    ;;
51156    -l*)
51157      ac_ii=`echo $ac_i|cut -c 3-`
51158
51159
51160  case $ac_ii in
51161  c|c_r) ;;
51162  *)
51163    if test "$ext_shared" = "yes"; then
51164        OCI8_SYSLIB="$OCI8_SYSLIB -l$ac_ii"
51165    else
51166
51167
51168  case $ac_ii in
51169  c|c_r) ;;
51170  *)
51171      LIBS="$LIBS -l$ac_ii"
51172   ;;
51173  esac
51174
51175
51176    fi
51177   ;;
51178  esac
51179
51180
51181    ;;
51182    -L*)
51183      ac_ii=`echo $ac_i|cut -c 3-`
51184
51185  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
51186
51187  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
51188    ai_p=$ac_ii
51189  else
51190
51191    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
51192
51193    ep_realdir=`(cd "$ep_dir" && pwd)`
51194    ai_p="$ep_realdir"/`basename "$ac_ii"`
51195  fi
51196
51197
51198      if test "$ext_shared" = "yes"; then
51199        OCI8_SYSLIB="-L$ai_p $OCI8_SYSLIB"
51200        test -n "$ld_runpath_switch" && OCI8_SYSLIB="$ld_runpath_switch$ai_p $OCI8_SYSLIB"
51201      else
51202
51203
51204
51205  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51206
51207  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
51208  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51209    eval "LIBPATH$unique=set"
51210
51211    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
51212    LDFLAGS="$LDFLAGS -L$ai_p"
51213    PHP_RPATHS="$PHP_RPATHS $ai_p"
51214
51215  fi
51216
51217
51218      fi
51219
51220  fi
51221
51222    ;;
51223    esac
51224  done
51225
51226    elif test -f "$OCI8_DIR/rdbms/$OCI8_LIB_DIR/sysliblist"; then
51227
51228  for ac_i in `cat $OCI8_DIR/rdbms/$OCI8_LIB_DIR/sysliblist`; do
51229    case $ac_i in
51230    -pthread)
51231      if test "$ext_shared" = "yes"; then
51232        OCI8_SYSLIB="$OCI8_SYSLIB -pthread"
51233      else
51234
51235
51236  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51237
51238  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
51239  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51240    eval "EXTRA_LDFLAGS$unique=set"
51241    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
51242  fi
51243
51244
51245
51246  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51247
51248  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
51249  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51250    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
51251    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
51252  fi
51253
51254      fi
51255    ;;
51256    -l*)
51257      ac_ii=`echo $ac_i|cut -c 3-`
51258
51259
51260  case $ac_ii in
51261  c|c_r) ;;
51262  *)
51263    if test "$ext_shared" = "yes"; then
51264        OCI8_SYSLIB="$OCI8_SYSLIB -l$ac_ii"
51265    else
51266
51267
51268  case $ac_ii in
51269  c|c_r) ;;
51270  *)
51271      LIBS="$LIBS -l$ac_ii"
51272   ;;
51273  esac
51274
51275
51276    fi
51277   ;;
51278  esac
51279
51280
51281    ;;
51282    -L*)
51283      ac_ii=`echo $ac_i|cut -c 3-`
51284
51285  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
51286
51287  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
51288    ai_p=$ac_ii
51289  else
51290
51291    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
51292
51293    ep_realdir=`(cd "$ep_dir" && pwd)`
51294    ai_p="$ep_realdir"/`basename "$ac_ii"`
51295  fi
51296
51297
51298      if test "$ext_shared" = "yes"; then
51299        OCI8_SYSLIB="-L$ai_p $OCI8_SYSLIB"
51300        test -n "$ld_runpath_switch" && OCI8_SYSLIB="$ld_runpath_switch$ai_p $OCI8_SYSLIB"
51301      else
51302
51303
51304
51305  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51306
51307  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
51308  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51309    eval "LIBPATH$unique=set"
51310
51311    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
51312    LDFLAGS="$LDFLAGS -L$ai_p"
51313    PHP_RPATHS="$PHP_RPATHS $ai_p"
51314
51315  fi
51316
51317
51318      fi
51319
51320  fi
51321
51322    ;;
51323    esac
51324  done
51325
51326    fi
51327
51328
51329  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle library version compatibility" >&5
51330printf %s "checking Oracle library version compatibility... " >&6; }
51331  OCI8_LCS_BASE=$OCI8_DIR/$OCI8_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME
51332    OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1`
51333  if test -s "$OCI8_DIR/orainst/unix.rgs"; then
51334    OCI8_ORACLE_VERSION=`grep '"ocommon"' $OCI8_DIR/orainst/unix.rgs | $PHP_OCI8_SED 's/  */:/g' | cut -d: -f 6 | cut -c 2-4`
51335    test -z "$OCI8_ORACLE_VERSION" && OCI8_ORACLE_VERSION=7.3
51336  elif test -f "$OCI8_LCS"; then
51337            OCI8_ORACLE_VERSION=`echo $OCI8_LCS | $PHP_OCI8_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
51338  elif test -f $OCI8_LCS_BASE.9.0; then
51339            OCI8_ORACLE_VERSION=9.0
51340  elif test -f $OCI8_LCS_BASE.8.0; then
51341    OCI8_ORACLE_VERSION=8.1
51342  elif test -f $OCI8_LCS_BASE.1.0; then
51343    OCI8_ORACLE_VERSION=8.0
51344  elif test -f $OCI8_DIR/$OCI8_LIB_DIR/libclntsh.a; then
51345    if test -f $OCI8_DIR/$OCI8_LIB_DIR/libcore4.a; then
51346      OCI8_ORACLE_VERSION=8.0
51347    else
51348      OCI8_ORACLE_VERSION=8.1
51349    fi
51350  else
51351    as_fn_error $? "Oracle libclntsh.$SHLIB_SUFFIX_NAME client library not found" "$LINENO" 5
51352  fi
51353  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCI8_ORACLE_VERSION" >&5
51354printf "%s\n" "$OCI8_ORACLE_VERSION" >&6; }
51355
51356
51357    case $OCI8_ORACLE_VERSION in
51358      7.3|8.0|8.1|9.0)
51359	as_fn_error $? "Oracle client libraries < 10 are not supported" "$LINENO" 5
51360	;;
51361    esac
51362
51363
51364
51365  case clntsh in
51366  c|c_r) ;;
51367  *)
51368    if test "$ext_shared" = "yes"; then
51369        OCI8_SHARED_LIBADD="$OCI8_SHARED_LIBADD -lclntsh"
51370    else
51371
51372
51373  case clntsh in
51374  c|c_r) ;;
51375  *)
51376      LIBS="$LIBS -lclntsh"
51377   ;;
51378  esac
51379
51380
51381    fi
51382   ;;
51383  esac
51384
51385
51386
51387  if test "$OCI8_DIR/$OCI8_LIB_DIR" != "/usr/$PHP_LIBDIR" && test "$OCI8_DIR/$OCI8_LIB_DIR" != "/usr/lib"; then
51388
51389  if test -z "$OCI8_DIR/$OCI8_LIB_DIR" || echo "$OCI8_DIR/$OCI8_LIB_DIR" | grep '^/' >/dev/null ; then
51390    ai_p=$OCI8_DIR/$OCI8_LIB_DIR
51391  else
51392
51393    ep_dir=`echo $OCI8_DIR/$OCI8_LIB_DIR|$SED 's%/*[^/][^/]*/*$%%'`
51394
51395    ep_realdir=`(cd "$ep_dir" && pwd)`
51396    ai_p="$ep_realdir"/`basename "$OCI8_DIR/$OCI8_LIB_DIR"`
51397  fi
51398
51399
51400      if test "$ext_shared" = "yes"; then
51401        OCI8_SHARED_LIBADD="-L$ai_p $OCI8_SHARED_LIBADD"
51402        test -n "$ld_runpath_switch" && OCI8_SHARED_LIBADD="$ld_runpath_switch$ai_p $OCI8_SHARED_LIBADD"
51403      else
51404
51405
51406
51407  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51408
51409  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
51410  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51411    eval "LIBPATH$unique=set"
51412
51413    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
51414    LDFLAGS="$LDFLAGS -L$ai_p"
51415    PHP_RPATHS="$PHP_RPATHS $ai_p"
51416
51417  fi
51418
51419
51420      fi
51421
51422  fi
51423
51424
51425  ext_builddir=ext/oci8
51426  ext_srcdir=$abs_srcdir/ext/oci8
51427  ext_dir=ext/oci8
51428
51429  ac_extra=
51430
51431  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
51432    PHP_OCI8_SHARED=no
51433
51434
51435  case $ext_dir in
51436  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
51437  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
51438  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
51439  esac
51440
51441
51442
51443  b_c_pre=$php_c_pre
51444  b_cxx_pre=$php_cxx_pre
51445  b_c_meta=$php_c_meta
51446  b_cxx_meta=$php_cxx_meta
51447  b_c_post=$php_c_post
51448  b_cxx_post=$php_cxx_post
51449  b_lo=$php_lo
51450
51451
51452  old_IFS=$IFS
51453  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
51454
51455      IFS=.
51456      set $ac_src
51457      ac_obj=$1
51458      IFS=$old_IFS
51459
51460      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
51461
51462      case $ac_src in
51463        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51464        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51465        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51466        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
51467      esac
51468
51469      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
51470
51471    cat >>Makefile.objects<<EOF
51472-include $ac_bdir$ac_obj.dep
51473$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
51474	$ac_comp
51475EOF
51476  done
51477
51478
51479    EXT_STATIC="$EXT_STATIC oci8;$ext_dir"
51480    if test "$ext_shared" != "nocli"; then
51481      EXT_CLI_STATIC="$EXT_CLI_STATIC oci8;$ext_dir"
51482    fi
51483  else
51484    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
51485      PHP_OCI8_SHARED=yes
51486
51487  case $ext_dir in
51488  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
51489  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
51490  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
51491  esac
51492
51493
51494
51495  b_c_pre=$shared_c_pre
51496  b_cxx_pre=$shared_cxx_pre
51497  b_c_meta=$shared_c_meta
51498  b_cxx_meta=$shared_cxx_meta
51499  b_c_post=$shared_c_post
51500  b_cxx_post=$shared_cxx_post
51501  b_lo=$shared_lo
51502
51503
51504  old_IFS=$IFS
51505  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
51506
51507      IFS=.
51508      set $ac_src
51509      ac_obj=$1
51510      IFS=$old_IFS
51511
51512      shared_objects_oci8="$shared_objects_oci8 $ac_bdir$ac_obj.lo"
51513
51514      case $ac_src in
51515        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51516        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51517        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51518        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
51519      esac
51520
51521      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
51522
51523    cat >>Makefile.objects<<EOF
51524-include $ac_bdir$ac_obj.dep
51525$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
51526	$ac_comp
51527EOF
51528  done
51529
51530
51531  install_modules="install-modules"
51532  suffix=la
51533
51534  case $host_alias in
51535    *aix*)
51536      additional_flags="-Wl,-G"
51537      ;;
51538  esac
51539
51540  if test "x" = "xyes"; then
51541    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/oci8.$suffix"
51542  else
51543    PHP_MODULES="$PHP_MODULES \$(phplibdir)/oci8.$suffix"
51544  fi
51545
51546  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_oci8"
51547
51548  cat >>Makefile.objects<<EOF
51549\$(phplibdir)/oci8.$suffix: $ext_builddir/oci8.$suffix
51550	\$(LIBTOOL) --mode=install cp $ext_builddir/oci8.$suffix \$(phplibdir)
51551
51552$ext_builddir/oci8.$suffix: \$(shared_objects_oci8) \$(OCI8_SHARED_DEPENDENCIES)
51553	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_oci8) \$(OCI8_SHARED_LIBADD)
51554
51555EOF
51556
51557
51558printf "%s\n" "#define COMPILE_DL_OCI8 1" >>confdefs.h
51559
51560    fi
51561  fi
51562
51563  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
51564    PHP_OCI8_SHARED=no
51565    case "$PHP_SAPI" in
51566      cgi|embed|phpdbg)
51567
51568
51569  case $ext_dir in
51570  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
51571  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
51572  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
51573  esac
51574
51575
51576
51577  b_c_pre=$php_c_pre
51578  b_cxx_pre=$php_cxx_pre
51579  b_c_meta=$php_c_meta
51580  b_cxx_meta=$php_cxx_meta
51581  b_c_post=$php_c_post
51582  b_cxx_post=$php_cxx_post
51583  b_lo=$php_lo
51584
51585
51586  old_IFS=$IFS
51587  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
51588
51589      IFS=.
51590      set $ac_src
51591      ac_obj=$1
51592      IFS=$old_IFS
51593
51594      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
51595
51596      case $ac_src in
51597        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51598        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51599        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51600        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
51601      esac
51602
51603      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
51604
51605    cat >>Makefile.objects<<EOF
51606-include $ac_bdir$ac_obj.dep
51607$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
51608	$ac_comp
51609EOF
51610  done
51611
51612
51613        EXT_STATIC="$EXT_STATIC oci8;$ext_dir"
51614        ;;
51615      *)
51616
51617
51618  case $ext_dir in
51619  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
51620  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
51621  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
51622  esac
51623
51624
51625
51626  b_c_pre=$php_c_pre
51627  b_cxx_pre=$php_cxx_pre
51628  b_c_meta=$php_c_meta
51629  b_cxx_meta=$php_cxx_meta
51630  b_c_post=$php_c_post
51631  b_cxx_post=$php_cxx_post
51632  b_lo=$php_lo
51633
51634
51635  old_IFS=$IFS
51636  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
51637
51638      IFS=.
51639      set $ac_src
51640      ac_obj=$1
51641      IFS=$old_IFS
51642
51643      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
51644
51645      case $ac_src in
51646        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51647        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51648        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
51649        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
51650      esac
51651
51652      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
51653
51654    cat >>Makefile.objects<<EOF
51655-include $ac_bdir$ac_obj.dep
51656$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
51657	$ac_comp
51658EOF
51659  done
51660
51661
51662        ;;
51663    esac
51664    EXT_CLI_STATIC="$EXT_CLI_STATIC oci8;$ext_dir"
51665  fi
51666
51667
51668    BUILD_DIR="$BUILD_DIR $ext_builddir"
51669
51670
51671
51672  if test "$ext_builddir" = "."; then
51673    PHP_PECL_EXTENSION=oci8
51674
51675  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
51676
51677  fi
51678
51679
51680printf "%s\n" "#define HAVE_OCI8 1" >>confdefs.h
51681
51682
51683
51684
51685
51686  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_SHARED_LIBADD"
51687
51688
51689
51690
51691
51692  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_DIR"
51693
51694
51695
51696
51697
51698  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_ORACLE_VERSION"
51699
51700
51701
51702
51703printf "%s\n" "#define PHP_OCI8_DEF_DIR \"$OCI8_DIR\"" >>confdefs.h
51704
51705
51706printf "%s\n" "#define PHP_OCI8_DEF_SHARED_LIBADD \"$OCI8_SHARED_LIBADD\"" >>confdefs.h
51707
51708
51709  else
51710
51711    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle Instant Client directory" >&5
51712printf %s "checking Oracle Instant Client directory... " >&6; }
51713
51714    if test "$PHP_OCI8_INSTANT_CLIENT" = "yes"; then
51715                                    PHP_OCI8_INSTANT_CLIENT=`ls -d /usr/lib/oracle/*/client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib/libclntsh.* 2> /dev/null | $PHP_OCI8_TAIL1 | $PHP_OCI8_SED -e 's#/libclntsh[^/]*##'`
51716      if test -z "$PHP_OCI8_INSTANT_CLIENT"; then
51717	as_fn_error $? "Oracle Instant Client directory /usr/lib/oracle/.../client${PHP_OCI8_IC_LIBDIR_SUFFIX}/lib libraries not found. Try --with-oci8=instantclient,DIR" "$LINENO" 5
51718      fi
51719    fi
51720    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_OCI8_INSTANT_CLIENT" >&5
51721printf "%s\n" "$PHP_OCI8_INSTANT_CLIENT" >&6; }
51722
51723    OCI8_DIR=$PHP_OCI8_INSTANT_CLIENT
51724
51725    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle Instant Client SDK header directory" >&5
51726printf %s "checking Oracle Instant Client SDK header directory... " >&6; }
51727
51728        OCISDKRPMINC=`echo "$PHP_OCI8_INSTANT_CLIENT" | $PHP_OCI8_SED -e 's!^/usr/lib/oracle/\(.*\)/client\('${PHP_OCI8_IC_LIBDIR_SUFFIX}'\)*/lib/*$!/usr/include/oracle/\1/client\2!'`
51729
51730        OCISDKZIPINC=$PHP_OCI8_INSTANT_CLIENT/sdk/include
51731
51732        OCISDKMANINC=`echo "$PHP_OCI8_INSTANT_CLIENT" | $PHP_OCI8_SED -e 's!\(.*\)/lib/*$!\1/include!'`
51733
51734    if test -f "$OCISDKRPMINC/oci.h"; then
51735      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKRPMINC" >&5
51736printf "%s\n" "$OCISDKRPMINC" >&6; }
51737
51738  if test "$OCISDKRPMINC" != "/usr/include"; then
51739
51740  if test -z "$OCISDKRPMINC" || echo "$OCISDKRPMINC" | grep '^/' >/dev/null ; then
51741    ai_p=$OCISDKRPMINC
51742  else
51743
51744    ep_dir=`echo $OCISDKRPMINC|$SED 's%/*[^/][^/]*/*$%%'`
51745
51746    ep_realdir=`(cd "$ep_dir" && pwd)`
51747    ai_p="$ep_realdir"/`basename "$OCISDKRPMINC"`
51748  fi
51749
51750
51751
51752  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51753
51754  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51755  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51756    eval "INCLUDEPATH$unique=set"
51757
51758      if test ""; then
51759        INCLUDES="-I$ai_p $INCLUDES"
51760      else
51761        INCLUDES="$INCLUDES -I$ai_p"
51762      fi
51763
51764  fi
51765
51766  fi
51767
51768      OCI8INCDIR=$OCISDKRPMINC
51769    elif test -f "$OCISDKZIPINC/oci.h"; then
51770      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKZIPINC" >&5
51771printf "%s\n" "$OCISDKZIPINC" >&6; }
51772
51773  if test "$OCISDKZIPINC" != "/usr/include"; then
51774
51775  if test -z "$OCISDKZIPINC" || echo "$OCISDKZIPINC" | grep '^/' >/dev/null ; then
51776    ai_p=$OCISDKZIPINC
51777  else
51778
51779    ep_dir=`echo $OCISDKZIPINC|$SED 's%/*[^/][^/]*/*$%%'`
51780
51781    ep_realdir=`(cd "$ep_dir" && pwd)`
51782    ai_p="$ep_realdir"/`basename "$OCISDKZIPINC"`
51783  fi
51784
51785
51786
51787  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51788
51789  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51790  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51791    eval "INCLUDEPATH$unique=set"
51792
51793      if test ""; then
51794        INCLUDES="-I$ai_p $INCLUDES"
51795      else
51796        INCLUDES="$INCLUDES -I$ai_p"
51797      fi
51798
51799  fi
51800
51801  fi
51802
51803      OCI8INCDIR=$OCISDKZIPINC
51804    elif test -f "$OCISDKMANINC/oci.h"; then
51805      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKMANINC" >&5
51806printf "%s\n" "$OCISDKMANINC" >&6; }
51807
51808  if test "$OCISDKMANINC" != "/usr/include"; then
51809
51810  if test -z "$OCISDKMANINC" || echo "$OCISDKMANINC" | grep '^/' >/dev/null ; then
51811    ai_p=$OCISDKMANINC
51812  else
51813
51814    ep_dir=`echo $OCISDKMANINC|$SED 's%/*[^/][^/]*/*$%%'`
51815
51816    ep_realdir=`(cd "$ep_dir" && pwd)`
51817    ai_p="$ep_realdir"/`basename "$OCISDKMANINC"`
51818  fi
51819
51820
51821
51822  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51823
51824  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
51825  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51826    eval "INCLUDEPATH$unique=set"
51827
51828      if test ""; then
51829        INCLUDES="-I$ai_p $INCLUDES"
51830      else
51831        INCLUDES="$INCLUDES -I$ai_p"
51832      fi
51833
51834  fi
51835
51836  fi
51837
51838      OCI8INCDIR=$OCISDKMANINC
51839    else
51840      as_fn_error $? "Oracle Instant Client SDK header files not found" "$LINENO" 5
51841    fi
51842
51843    OCISYSLIBLIST=`echo "$OCI8INCDIR" | $PHP_OCI8_SED -e 's!\(.*\)/include$!\1/demo/sysliblist!'`
51844    if test -f "$OCISYSLIBLIST"; then
51845
51846  for ac_i in `cat $OCISYSLIBLIST`; do
51847    case $ac_i in
51848    -pthread)
51849      if test "$ext_shared" = "yes"; then
51850        OCI8_SYSLIB="$OCI8_SYSLIB -pthread"
51851      else
51852
51853
51854  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51855
51856  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
51857  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51858    eval "EXTRA_LDFLAGS$unique=set"
51859    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
51860  fi
51861
51862
51863
51864  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
51865
51866  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
51867  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51868    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
51869    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
51870  fi
51871
51872      fi
51873    ;;
51874    -l*)
51875      ac_ii=`echo $ac_i|cut -c 3-`
51876
51877
51878  case $ac_ii in
51879  c|c_r) ;;
51880  *)
51881    if test "$ext_shared" = "yes"; then
51882        OCI8_SYSLIB="$OCI8_SYSLIB -l$ac_ii"
51883    else
51884
51885
51886  case $ac_ii in
51887  c|c_r) ;;
51888  *)
51889      LIBS="$LIBS -l$ac_ii"
51890   ;;
51891  esac
51892
51893
51894    fi
51895   ;;
51896  esac
51897
51898
51899    ;;
51900    -L*)
51901      ac_ii=`echo $ac_i|cut -c 3-`
51902
51903  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
51904
51905  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
51906    ai_p=$ac_ii
51907  else
51908
51909    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
51910
51911    ep_realdir=`(cd "$ep_dir" && pwd)`
51912    ai_p="$ep_realdir"/`basename "$ac_ii"`
51913  fi
51914
51915
51916      if test "$ext_shared" = "yes"; then
51917        OCI8_SYSLIB="-L$ai_p $OCI8_SYSLIB"
51918        test -n "$ld_runpath_switch" && OCI8_SYSLIB="$ld_runpath_switch$ai_p $OCI8_SYSLIB"
51919      else
51920
51921
51922
51923  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
51924
51925  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
51926  if test -n "$unique" && test "`eval $cmd`" = "" ; then
51927    eval "LIBPATH$unique=set"
51928
51929    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
51930    LDFLAGS="$LDFLAGS -L$ai_p"
51931    PHP_RPATHS="$PHP_RPATHS $ai_p"
51932
51933  fi
51934
51935
51936      fi
51937
51938  fi
51939
51940    ;;
51941    esac
51942  done
51943
51944    fi
51945
51946
51947  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle Instant Client library version compatibility" >&5
51948printf %s "checking Oracle Instant Client library version compatibility... " >&6; }
51949  OCI8_LCS_BASE=$PHP_OCI8_INSTANT_CLIENT/libclntsh.$SHLIB_SUFFIX_NAME
51950    OCI8_LCS=`ls $OCI8_LCS_BASE.*.1 2> /dev/null | $PHP_OCI8_TAIL1`
51951  OCI8_NNZ=`ls $PHP_OCI8_INSTANT_CLIENT/libnnz*.$SHLIB_SUFFIX_NAME 2> /dev/null | $PHP_OCI8_TAIL1`
51952  if test -f "$OCI8_NNZ" && test -f "$OCI8_LCS"; then
51953    if test ! -f "$OCI8_LCS_BASE"; then
51954      as_fn_error $? "Link from $OCI8_LCS_BASE to $OCI8_LCS_BASE.*.1 not found" "$LINENO" 5
51955    fi
51956    OCI8_ORACLE_VERSION=`echo $OCI8_LCS | $PHP_OCI8_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
51957  else
51958    as_fn_error $? "Oracle Instant Client libraries libnnz.$SHLIB_SUFFIX_NAME and libclntsh.$SHLIB_SUFFIX_NAME not found" "$LINENO" 5
51959  fi
51960  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCI8_ORACLE_VERSION" >&5
51961printf "%s\n" "$OCI8_ORACLE_VERSION" >&6; }
51962
51963
51964
51965  case clntsh in
51966  c|c_r) ;;
51967  *)
51968    if test "$ext_shared" = "yes"; then
51969        OCI8_SHARED_LIBADD="$OCI8_SHARED_LIBADD -lclntsh"
51970    else
51971
51972
51973  case clntsh in
51974  c|c_r) ;;
51975  *)
51976      LIBS="$LIBS -lclntsh"
51977   ;;
51978  esac
51979
51980
51981    fi
51982   ;;
51983  esac
51984
51985
51986
51987  if test "$PHP_OCI8_INSTANT_CLIENT" != "/usr/$PHP_LIBDIR" && test "$PHP_OCI8_INSTANT_CLIENT" != "/usr/lib"; then
51988
51989  if test -z "$PHP_OCI8_INSTANT_CLIENT" || echo "$PHP_OCI8_INSTANT_CLIENT" | grep '^/' >/dev/null ; then
51990    ai_p=$PHP_OCI8_INSTANT_CLIENT
51991  else
51992
51993    ep_dir=`echo $PHP_OCI8_INSTANT_CLIENT|$SED 's%/*[^/][^/]*/*$%%'`
51994
51995    ep_realdir=`(cd "$ep_dir" && pwd)`
51996    ai_p="$ep_realdir"/`basename "$PHP_OCI8_INSTANT_CLIENT"`
51997  fi
51998
51999
52000      if test "$ext_shared" = "yes"; then
52001        OCI8_SHARED_LIBADD="-L$ai_p $OCI8_SHARED_LIBADD"
52002        test -n "$ld_runpath_switch" && OCI8_SHARED_LIBADD="$ld_runpath_switch$ai_p $OCI8_SHARED_LIBADD"
52003      else
52004
52005
52006
52007  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52008
52009  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
52010  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52011    eval "LIBPATH$unique=set"
52012
52013    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
52014    LDFLAGS="$LDFLAGS -L$ai_p"
52015    PHP_RPATHS="$PHP_RPATHS $ai_p"
52016
52017  fi
52018
52019
52020      fi
52021
52022  fi
52023
52024
52025
52026printf "%s\n" "#define HAVE_OCI_INSTANT_CLIENT 1" >>confdefs.h
52027
52028
52029
52030  ext_builddir=ext/oci8
52031  ext_srcdir=$abs_srcdir/ext/oci8
52032  ext_dir=ext/oci8
52033
52034  ac_extra=
52035
52036  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
52037    PHP_OCI8_SHARED=no
52038
52039
52040  case $ext_dir in
52041  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
52042  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
52043  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
52044  esac
52045
52046
52047
52048  b_c_pre=$php_c_pre
52049  b_cxx_pre=$php_cxx_pre
52050  b_c_meta=$php_c_meta
52051  b_cxx_meta=$php_cxx_meta
52052  b_c_post=$php_c_post
52053  b_cxx_post=$php_cxx_post
52054  b_lo=$php_lo
52055
52056
52057  old_IFS=$IFS
52058  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
52059
52060      IFS=.
52061      set $ac_src
52062      ac_obj=$1
52063      IFS=$old_IFS
52064
52065      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
52066
52067      case $ac_src in
52068        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52069        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52070        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52071        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
52072      esac
52073
52074      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
52075
52076    cat >>Makefile.objects<<EOF
52077-include $ac_bdir$ac_obj.dep
52078$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
52079	$ac_comp
52080EOF
52081  done
52082
52083
52084    EXT_STATIC="$EXT_STATIC oci8;$ext_dir"
52085    if test "$ext_shared" != "nocli"; then
52086      EXT_CLI_STATIC="$EXT_CLI_STATIC oci8;$ext_dir"
52087    fi
52088  else
52089    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
52090      PHP_OCI8_SHARED=yes
52091
52092  case $ext_dir in
52093  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
52094  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
52095  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
52096  esac
52097
52098
52099
52100  b_c_pre=$shared_c_pre
52101  b_cxx_pre=$shared_cxx_pre
52102  b_c_meta=$shared_c_meta
52103  b_cxx_meta=$shared_cxx_meta
52104  b_c_post=$shared_c_post
52105  b_cxx_post=$shared_cxx_post
52106  b_lo=$shared_lo
52107
52108
52109  old_IFS=$IFS
52110  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
52111
52112      IFS=.
52113      set $ac_src
52114      ac_obj=$1
52115      IFS=$old_IFS
52116
52117      shared_objects_oci8="$shared_objects_oci8 $ac_bdir$ac_obj.lo"
52118
52119      case $ac_src in
52120        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52121        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52122        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52123        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
52124      esac
52125
52126      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
52127
52128    cat >>Makefile.objects<<EOF
52129-include $ac_bdir$ac_obj.dep
52130$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
52131	$ac_comp
52132EOF
52133  done
52134
52135
52136  install_modules="install-modules"
52137  suffix=la
52138
52139  case $host_alias in
52140    *aix*)
52141      additional_flags="-Wl,-G"
52142      ;;
52143  esac
52144
52145  if test "x" = "xyes"; then
52146    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/oci8.$suffix"
52147  else
52148    PHP_MODULES="$PHP_MODULES \$(phplibdir)/oci8.$suffix"
52149  fi
52150
52151  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_oci8"
52152
52153  cat >>Makefile.objects<<EOF
52154\$(phplibdir)/oci8.$suffix: $ext_builddir/oci8.$suffix
52155	\$(LIBTOOL) --mode=install cp $ext_builddir/oci8.$suffix \$(phplibdir)
52156
52157$ext_builddir/oci8.$suffix: \$(shared_objects_oci8) \$(OCI8_SHARED_DEPENDENCIES)
52158	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_oci8) \$(OCI8_SHARED_LIBADD)
52159
52160EOF
52161
52162
52163printf "%s\n" "#define COMPILE_DL_OCI8 1" >>confdefs.h
52164
52165    fi
52166  fi
52167
52168  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
52169    PHP_OCI8_SHARED=no
52170    case "$PHP_SAPI" in
52171      cgi|embed|phpdbg)
52172
52173
52174  case $ext_dir in
52175  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
52176  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
52177  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
52178  esac
52179
52180
52181
52182  b_c_pre=$php_c_pre
52183  b_cxx_pre=$php_cxx_pre
52184  b_c_meta=$php_c_meta
52185  b_cxx_meta=$php_cxx_meta
52186  b_c_post=$php_c_post
52187  b_cxx_post=$php_cxx_post
52188  b_lo=$php_lo
52189
52190
52191  old_IFS=$IFS
52192  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
52193
52194      IFS=.
52195      set $ac_src
52196      ac_obj=$1
52197      IFS=$old_IFS
52198
52199      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
52200
52201      case $ac_src in
52202        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52203        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52204        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52205        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
52206      esac
52207
52208      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
52209
52210    cat >>Makefile.objects<<EOF
52211-include $ac_bdir$ac_obj.dep
52212$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
52213	$ac_comp
52214EOF
52215  done
52216
52217
52218        EXT_STATIC="$EXT_STATIC oci8;$ext_dir"
52219        ;;
52220      *)
52221
52222
52223  case $ext_dir in
52224  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
52225  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
52226  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
52227  esac
52228
52229
52230
52231  b_c_pre=$php_c_pre
52232  b_cxx_pre=$php_cxx_pre
52233  b_c_meta=$php_c_meta
52234  b_cxx_meta=$php_cxx_meta
52235  b_c_post=$php_c_post
52236  b_cxx_post=$php_cxx_post
52237  b_lo=$php_lo
52238
52239
52240  old_IFS=$IFS
52241  for ac_src in oci8.c oci8_lob.c oci8_statement.c oci8_collection.c oci8_interface.c oci8_failover.c; do
52242
52243      IFS=.
52244      set $ac_src
52245      ac_obj=$1
52246      IFS=$old_IFS
52247
52248      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
52249
52250      case $ac_src in
52251        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52252        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52253        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
52254        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
52255      esac
52256
52257      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
52258
52259    cat >>Makefile.objects<<EOF
52260-include $ac_bdir$ac_obj.dep
52261$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
52262	$ac_comp
52263EOF
52264  done
52265
52266
52267        ;;
52268    esac
52269    EXT_CLI_STATIC="$EXT_CLI_STATIC oci8;$ext_dir"
52270  fi
52271
52272
52273    BUILD_DIR="$BUILD_DIR $ext_builddir"
52274
52275
52276
52277  if test "$ext_builddir" = "."; then
52278    PHP_PECL_EXTENSION=oci8
52279
52280  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
52281
52282  fi
52283
52284
52285printf "%s\n" "#define HAVE_OCI8 1" >>confdefs.h
52286
52287
52288
52289
52290
52291  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_SHARED_LIBADD"
52292
52293
52294
52295
52296
52297  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_DIR"
52298
52299
52300
52301
52302
52303  PHP_VAR_SUBST="$PHP_VAR_SUBST OCI8_ORACLE_VERSION"
52304
52305
52306
52307  fi
52308fi
52309
52310
52311
52312
52313
52314
52315
52316
52317
52318
52319
52320
52321
52322
52323
52324
52325php_with_odbcver=0x0350
52326
52327
52328
52329# Check whether --with-odbcver was given.
52330if test ${with_odbcver+y}
52331then :
52332  withval=$with_odbcver; PHP_ODBCVER=$withval
52333else $as_nop
52334
52335  PHP_ODBCVER=0x0350
52336  test "$PHP_ENABLE_ALL" && PHP_ODBCVER=$PHP_ENABLE_ALL
52337
52338fi
52339
52340
52341
52342ext_output="yes, shared"
52343ext_shared=yes
52344case $PHP_ODBCVER in
52345shared,*)
52346  PHP_ODBCVER=`echo "$PHP_ODBCVER"|$SED 's/^shared,//'`
52347  ;;
52348shared)
52349  PHP_ODBCVER=yes
52350  ;;
52351no)
52352  ext_output=no
52353  ext_shared=no
52354  ;;
52355*)
52356  ext_output=yes
52357  ext_shared=no
52358  ;;
52359esac
52360
52361
52362
52363
52364
52365
52366
52367
52368if test -z "$ODBC_TYPE"; then
52369
52370php_with_adabas=no
52371
52372
52373
52374# Check whether --with-adabas was given.
52375if test ${with_adabas+y}
52376then :
52377  withval=$with_adabas; PHP_ADABAS=$withval
52378else $as_nop
52379
52380  PHP_ADABAS=no
52381  test "$PHP_ENABLE_ALL" && PHP_ADABAS=$PHP_ENABLE_ALL
52382
52383fi
52384
52385
52386
52387ext_output="yes, shared"
52388ext_shared=yes
52389case $PHP_ADABAS in
52390shared,*)
52391  PHP_ADABAS=`echo "$PHP_ADABAS"|$SED 's/^shared,//'`
52392  ;;
52393shared)
52394  PHP_ADABAS=yes
52395  ;;
52396no)
52397  ext_output=no
52398  ext_shared=no
52399  ;;
52400*)
52401  ext_output=yes
52402  ext_shared=no
52403  ;;
52404esac
52405
52406
52407
52408
52409
52410
52411
52412
52413  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Adabas support" >&5
52414printf %s "checking for Adabas support... " >&6; }
52415  if test "$PHP_ADABAS" != "no"; then
52416    if test "$PHP_ADABAS" = "yes"; then
52417      PHP_ADABAS=/usr/local
52418    fi
52419
52420  if test "$PHP_ADABAS/incl" != "/usr/include"; then
52421
52422  if test -z "$PHP_ADABAS/incl" || echo "$PHP_ADABAS/incl" | grep '^/' >/dev/null ; then
52423    ai_p=$PHP_ADABAS/incl
52424  else
52425
52426    ep_dir=`echo $PHP_ADABAS/incl|$SED 's%/*[^/][^/]*/*$%%'`
52427
52428    ep_realdir=`(cd "$ep_dir" && pwd)`
52429    ai_p="$ep_realdir"/`basename "$PHP_ADABAS/incl"`
52430  fi
52431
52432
52433
52434  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52435
52436  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
52437  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52438    eval "INCLUDEPATH$unique=set"
52439
52440      if test ""; then
52441        INCLUDES="-I$ai_p $INCLUDES"
52442      else
52443        INCLUDES="$INCLUDES -I$ai_p"
52444      fi
52445
52446  fi
52447
52448  fi
52449
52450
52451  if test "$PHP_ADABAS/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PHP_ADABAS/$PHP_LIBDIR" != "/usr/lib"; then
52452
52453  if test -z "$PHP_ADABAS/$PHP_LIBDIR" || echo "$PHP_ADABAS/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
52454    ai_p=$PHP_ADABAS/$PHP_LIBDIR
52455  else
52456
52457    ep_dir=`echo $PHP_ADABAS/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
52458
52459    ep_realdir=`(cd "$ep_dir" && pwd)`
52460    ai_p="$ep_realdir"/`basename "$PHP_ADABAS/$PHP_LIBDIR"`
52461  fi
52462
52463
52464
52465
52466
52467  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52468
52469  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
52470  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52471    eval "LIBPATH$unique=set"
52472
52473    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
52474    LDFLAGS="$LDFLAGS -L$ai_p"
52475    PHP_RPATHS="$PHP_RPATHS $ai_p"
52476
52477  fi
52478
52479
52480
52481  fi
52482
52483    ODBC_OBJS="$PHP_ADABAS/$PHP_LIBDIR/odbclib.a"
52484    ODBC_LIB="$abs_builddir/ext/odbc/libodbc_adabas.a"
52485    $srcdir/build/shtool mkdir -f -p ext/odbc
52486    rm -f "$ODBC_LIB"
52487    cp "$ODBC_OBJS" "$ODBC_LIB"
52488
52489
52490  case sqlptc in
52491  c|c_r) ;;
52492  *)
52493      LIBS="-lsqlptc $LIBS"
52494   ;;
52495  esac
52496
52497
52498
52499
52500  case sqlrte in
52501  c|c_r) ;;
52502  *)
52503      LIBS="-lsqlrte $LIBS"
52504   ;;
52505  esac
52506
52507
52508
52509
52510  if test -n "$abs_builddir/ext/odbc"; then
52511
52512  if test "$abs_builddir/ext/odbc" != "/usr/$PHP_LIBDIR" && test "$abs_builddir/ext/odbc" != "/usr/lib"; then
52513
52514  if test -z "$abs_builddir/ext/odbc" || echo "$abs_builddir/ext/odbc" | grep '^/' >/dev/null ; then
52515    ai_p=$abs_builddir/ext/odbc
52516  else
52517
52518    ep_dir=`echo $abs_builddir/ext/odbc|$SED 's%/*[^/][^/]*/*$%%'`
52519
52520    ep_realdir=`(cd "$ep_dir" && pwd)`
52521    ai_p="$ep_realdir"/`basename "$abs_builddir/ext/odbc"`
52522  fi
52523
52524
52525
52526
52527
52528  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52529
52530  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
52531  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52532    eval "LIBPATH$unique=set"
52533
52534    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
52535    LDFLAGS="$LDFLAGS -L$ai_p"
52536    PHP_RPATHS="$PHP_RPATHS $ai_p"
52537
52538  fi
52539
52540
52541
52542  fi
52543
52544  fi
52545
52546
52547  case odbc_adabas in
52548  c|c_r) ;;
52549  *)
52550      LIBS="-lodbc_adabas $LIBS"
52551   ;;
52552  esac
52553
52554
52555
52556
52557    ODBC_TYPE=adabas
52558    ODBC_INCDIR=$PHP_ADABAS/incl
52559
52560if ! test -f "$ODBC_INCDIR/sqlext.h"; then
52561  as_fn_error $? "ODBC header file '$ODBC_INCDIR/sqlext.h' not found!" "$LINENO" 5
52562fi
52563
52564
52565printf "%s\n" "#define HAVE_ADABAS 1" >>confdefs.h
52566
52567    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
52568printf "%s\n" "$ext_output" >&6; }
52569  else
52570    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
52571printf "%s\n" "no" >&6; }
52572  fi
52573fi
52574
52575if test -z "$ODBC_TYPE"; then
52576
52577php_with_sapdb=no
52578
52579
52580
52581# Check whether --with-sapdb was given.
52582if test ${with_sapdb+y}
52583then :
52584  withval=$with_sapdb; PHP_SAPDB=$withval
52585else $as_nop
52586
52587  PHP_SAPDB=no
52588  test "$PHP_ENABLE_ALL" && PHP_SAPDB=$PHP_ENABLE_ALL
52589
52590fi
52591
52592
52593
52594ext_output="yes, shared"
52595ext_shared=yes
52596case $PHP_SAPDB in
52597shared,*)
52598  PHP_SAPDB=`echo "$PHP_SAPDB"|$SED 's/^shared,//'`
52599  ;;
52600shared)
52601  PHP_SAPDB=yes
52602  ;;
52603no)
52604  ext_output=no
52605  ext_shared=no
52606  ;;
52607*)
52608  ext_output=yes
52609  ext_shared=no
52610  ;;
52611esac
52612
52613
52614
52615
52616
52617
52618
52619
52620  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SAP DB support" >&5
52621printf %s "checking for SAP DB support... " >&6; }
52622  if test "$PHP_SAPDB" != "no"; then
52623    if test "$PHP_SAPDB" = "yes"; then
52624      PHP_SAPDB=/usr/local
52625    fi
52626
52627  if test "$PHP_SAPDB/incl" != "/usr/include"; then
52628
52629  if test -z "$PHP_SAPDB/incl" || echo "$PHP_SAPDB/incl" | grep '^/' >/dev/null ; then
52630    ai_p=$PHP_SAPDB/incl
52631  else
52632
52633    ep_dir=`echo $PHP_SAPDB/incl|$SED 's%/*[^/][^/]*/*$%%'`
52634
52635    ep_realdir=`(cd "$ep_dir" && pwd)`
52636    ai_p="$ep_realdir"/`basename "$PHP_SAPDB/incl"`
52637  fi
52638
52639
52640
52641  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52642
52643  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
52644  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52645    eval "INCLUDEPATH$unique=set"
52646
52647      if test ""; then
52648        INCLUDES="-I$ai_p $INCLUDES"
52649      else
52650        INCLUDES="$INCLUDES -I$ai_p"
52651      fi
52652
52653  fi
52654
52655  fi
52656
52657
52658  if test "$PHP_SAPDB/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PHP_SAPDB/$PHP_LIBDIR" != "/usr/lib"; then
52659
52660  if test -z "$PHP_SAPDB/$PHP_LIBDIR" || echo "$PHP_SAPDB/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
52661    ai_p=$PHP_SAPDB/$PHP_LIBDIR
52662  else
52663
52664    ep_dir=`echo $PHP_SAPDB/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
52665
52666    ep_realdir=`(cd "$ep_dir" && pwd)`
52667    ai_p="$ep_realdir"/`basename "$PHP_SAPDB/$PHP_LIBDIR"`
52668  fi
52669
52670
52671
52672
52673
52674  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
52675
52676  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
52677  if test -n "$unique" && test "`eval $cmd`" = "" ; then
52678    eval "LIBPATH$unique=set"
52679
52680    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
52681    LDFLAGS="$LDFLAGS -L$ai_p"
52682    PHP_RPATHS="$PHP_RPATHS $ai_p"
52683
52684  fi
52685
52686
52687
52688  fi
52689
52690
52691
52692  case sqlod in
52693  c|c_r) ;;
52694  *)
52695      LIBS="-lsqlod $LIBS"
52696   ;;
52697  esac
52698
52699
52700    ODBC_TYPE=sapdb
52701
52702printf "%s\n" "#define HAVE_SAPDB 1" >>confdefs.h
52703
52704    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
52705printf "%s\n" "$ext_output" >&6; }
52706  else
52707    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
52708printf "%s\n" "no" >&6; }
52709  fi
52710fi
52711
52712if test -z "$ODBC_TYPE"; then
52713
52714php_with_solid=no
52715
52716
52717
52718# Check whether --with-solid was given.
52719if test ${with_solid+y}
52720then :
52721  withval=$with_solid; PHP_SOLID=$withval
52722else $as_nop
52723
52724  PHP_SOLID=no
52725  test "$PHP_ENABLE_ALL" && PHP_SOLID=$PHP_ENABLE_ALL
52726
52727fi
52728
52729
52730
52731ext_output="yes, shared"
52732ext_shared=yes
52733case $PHP_SOLID in
52734shared,*)
52735  PHP_SOLID=`echo "$PHP_SOLID"|$SED 's/^shared,//'`
52736  ;;
52737shared)
52738  PHP_SOLID=yes
52739  ;;
52740no)
52741  ext_output=no
52742  ext_shared=no
52743  ;;
52744*)
52745  ext_output=yes
52746  ext_shared=no
52747  ;;
52748esac
52749
52750
52751
52752
52753
52754
52755
52756
52757  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Solid support" >&5
52758printf %s "checking for Solid support... " >&6; }
52759  if test "$PHP_SOLID" != "no"; then
52760    if test "$PHP_SOLID" = "yes"; then
52761      PHP_SOLID=/usr/local/solid
52762    fi
52763    ODBC_INCDIR=$PHP_SOLID/include
52764    ODBC_LIBDIR=$PHP_SOLID/$PHP_LIBDIR
52765    ODBC_CFLAGS=-I$ODBC_INCDIR
52766    ODBC_TYPE=solid
52767    if test -f $ODBC_LIBDIR/soc*35.a; then
52768
52769printf "%s\n" "#define HAVE_SOLID_35 1" >>confdefs.h
52770
52771    elif test -f $ODBC_LIBDIR/scl*30.a; then
52772
52773printf "%s\n" "#define HAVE_SOLID_30 1" >>confdefs.h
52774
52775    elif test -f $ODBC_LIBDIR/scl*23.a; then
52776
52777printf "%s\n" "#define HAVE_SOLID 1" >>confdefs.h
52778
52779    fi
52780    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
52781printf "%s\n" "$ext_output" >&6; }
52782
52783  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Solid library file" >&5
52784printf %s "checking Solid library file... " >&6; }
52785  ac_solid_uname_r=`uname -r 2>/dev/null`
52786  ac_solid_uname_s=`uname -s 2>/dev/null`
52787  case $ac_solid_uname_s in
52788    AIX) ac_solid_os=a3x;;   # a4x for AIX4/ Solid 2.3/3.0 only
52789    HP-UX) ac_solid_os=h9x;; # h1x for hpux11, h0x for hpux10
52790    IRIX) ac_solid_os=irx;;  # Solid 2.3(?)/ 3.0 only
52791    Linux)
52792      if ldd -v /bin/sh | grep GLIBC > /dev/null; then
52793
52794printf "%s\n" "#define SS_LINUX 1" >>confdefs.h
52795
52796        ac_solid_os=l2x
52797      else
52798
52799printf "%s\n" "#define SS_LINUX 1" >>confdefs.h
52800
52801        ac_solid_os=lux
52802      fi;;
52803    SunOS)
52804      ac_solid_os=ssx;; # should we deal with SunOS 4?
52805    FreeBSD)
52806      if test `expr $ac_solid_uname_r : '\(.\)'` -gt "2"; then
52807
52808printf "%s\n" "#define SS_FBX 1" >>confdefs.h
52809
52810        ac_solid_os=fex
52811      else
52812
52813printf "%s\n" "#define SS_FBX 1" >>confdefs.h
52814
52815        ac_solid_os=fbx
52816      fi;;
52817  esac
52818
52819  if test -f $ODBC_LIBDIR/soc${ac_solid_os}35.a; then
52820    ac_solid_version=35
52821    ac_solid_prefix=soc
52822  elif test -f $ODBC_LIBDIR/scl${ac_solid_os}30.a; then
52823    ac_solid_version=30
52824    ac_solid_prefix=scl
52825  elif test -f $ODBC_LIBDIR/scl${ac_solid_os}23.a; then
52826    ac_solid_version=23
52827    ac_solid_prefix=scl
52828  fi
52829
52830if test ! -f $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so -a \
52831  ! -f $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a; then
52832    echo ""
52833  echo "*********************************************************************"
52834  echo "* Unable to locate $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so or $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a"
52835  echo "* Please correct this by creating the following links and reconfiguring:"
52836  echo "* $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a -> $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.a"
52837  echo "* $ODBC_LIBDIR/${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so -> $ODBC_LIBDIR/lib${ac_solid_prefix}${ac_solid_os}${ac_solid_version}.so"
52838  echo "*********************************************************************"
52839else
52840  ODBC_LFLAGS=-L$ODBC_LIBDIR
52841  ODBC_LIBS=-l${ac_solid_prefix}${ac_solid_os}${ac_solid_version}
52842fi
52843
52844  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \`echo $ODBC_LIBS | sed -e 's!.*/!!'\`" >&5
52845printf "%s\n" "\`echo $ODBC_LIBS | sed -e 's!.*/!!'\`" >&6; }
52846
52847  else
52848    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
52849printf "%s\n" "no" >&6; }
52850  fi
52851fi
52852
52853if test -z "$ODBC_TYPE"; then
52854
52855php_with_ibm_db2=no
52856
52857
52858
52859# Check whether --with-ibm-db2 was given.
52860if test ${with_ibm_db2+y}
52861then :
52862  withval=$with_ibm_db2; PHP_IBM_DB2=$withval
52863else $as_nop
52864
52865  PHP_IBM_DB2=no
52866  test "$PHP_ENABLE_ALL" && PHP_IBM_DB2=$PHP_ENABLE_ALL
52867
52868fi
52869
52870
52871
52872ext_output="yes, shared"
52873ext_shared=yes
52874case $PHP_IBM_DB2 in
52875shared,*)
52876  PHP_IBM_DB2=`echo "$PHP_IBM_DB2"|$SED 's/^shared,//'`
52877  ;;
52878shared)
52879  PHP_IBM_DB2=yes
52880  ;;
52881no)
52882  ext_output=no
52883  ext_shared=no
52884  ;;
52885*)
52886  ext_output=yes
52887  ext_shared=no
52888  ;;
52889esac
52890
52891
52892
52893
52894
52895
52896
52897
52898  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for IBM DB2 support" >&5
52899printf %s "checking for IBM DB2 support... " >&6; }
52900  if test "$PHP_IBM_DB2" != "no"; then
52901    if test "$PHP_IBM_DB2" = "yes"; then
52902      ODBC_INCDIR=/home/db2inst1/sqllib/include
52903      ODBC_LIBDIR=/home/db2inst1/sqllib/lib
52904    else
52905      ODBC_INCDIR=$PHP_IBM_DB2/include
52906      ODBC_LIBDIR=$PHP_IBM_DB2/$PHP_LIBDIR
52907    fi
52908
52909
52910if ! test -f "$ODBC_INCDIR/sqlcli1.h"; then
52911  as_fn_error $? "ODBC header file '$ODBC_INCDIR/sqlcli1.h' not found!" "$LINENO" 5
52912fi
52913
52914
52915    ODBC_CFLAGS=-I$ODBC_INCDIR
52916    ODBC_LFLAGS=-L$ODBC_LIBDIR
52917    ODBC_TYPE=ibm-db2
52918    ODBC_LIBS=-ldb2
52919
52920
52921  old_LIBS=$LIBS
52922  LIBS="
52923      $ODBC_LFLAGS $ODBC_LIBS
52924     $LIBS"
52925  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
52926/* end confdefs.h.  */
52927
52928
52929    char SQLExecute();
52930    int main() {
52931      SQLExecute();
52932      return 0;
52933    }
52934
52935_ACEOF
52936if ac_fn_c_try_link "$LINENO"
52937then :
52938
52939    LIBS=$old_LIBS
52940
52941
52942printf "%s\n" "#define HAVE_IBMDB2 1" >>confdefs.h
52943
52944      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
52945printf "%s\n" "$ext_output" >&6; }
52946
52947
52948else $as_nop
52949
52950    LIBS=$old_LIBS
52951
52952      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
52953printf "%s\n" "no" >&6; }
52954      as_fn_error $? "
52955build test failed. Please check the config.log for details.
52956You need to source your DB2 environment before running PHP configure:
52957# . \$IBM_DB2/db2profile
52958" "$LINENO" 5
52959
52960
52961fi
52962rm -f core conftest.err conftest.$ac_objext conftest.beam \
52963    conftest$ac_exeext conftest.$ac_ext
52964
52965  else
52966    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
52967printf "%s\n" "no" >&6; }
52968  fi
52969fi
52970
52971if test -z "$ODBC_TYPE"; then
52972
52973php_with_empress=no
52974
52975
52976
52977# Check whether --with-empress was given.
52978if test ${with_empress+y}
52979then :
52980  withval=$with_empress; PHP_EMPRESS=$withval
52981else $as_nop
52982
52983  PHP_EMPRESS=no
52984  test "$PHP_ENABLE_ALL" && PHP_EMPRESS=$PHP_ENABLE_ALL
52985
52986fi
52987
52988
52989
52990ext_output="yes, shared"
52991ext_shared=yes
52992case $PHP_EMPRESS in
52993shared,*)
52994  PHP_EMPRESS=`echo "$PHP_EMPRESS"|$SED 's/^shared,//'`
52995  ;;
52996shared)
52997  PHP_EMPRESS=yes
52998  ;;
52999no)
53000  ext_output=no
53001  ext_shared=no
53002  ;;
53003*)
53004  ext_output=yes
53005  ext_shared=no
53006  ;;
53007esac
53008
53009
53010
53011
53012
53013
53014
53015
53016  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Empress support" >&5
53017printf %s "checking for Empress support... " >&6; }
53018  if test "$PHP_EMPRESS" != "no"; then
53019    if test "$PHP_EMPRESS" = "yes"; then
53020      ODBC_INCDIR=$EMPRESSPATH/include/odbc
53021      ODBC_LIBDIR=$EMPRESSPATH/shlib
53022    else
53023      ODBC_INCDIR=$PHP_EMPRESS/include/odbc
53024      ODBC_LIBDIR=$PHP_EMPRESS/shlib
53025    fi
53026    ODBC_CFLAGS=-I$ODBC_INCDIR
53027    ODBC_LFLAGS=-L$ODBC_LIBDIR
53028    ODBC_TYPE=empress
53029
53030printf "%s\n" "#define HAVE_EMPRESS 1" >>confdefs.h
53031
53032    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
53033printf "%s\n" "$ext_output" >&6; }
53034
53035  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Empress library file" >&5
53036printf %s "checking Empress library file... " >&6; }
53037  ODBC_LIBS=`echo $ODBC_LIBDIR/libempodbccl.so | cut -d' ' -f1`
53038  if test ! -f $ODBC_LIBS; then
53039    ODBC_LIBS=`echo $ODBC_LIBDIR/libempodbccl.so | cut -d' ' -f1`
53040  fi
53041  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \`echo $ODBC_LIBS | sed -e 's!.*/!!'\`" >&5
53042printf "%s\n" "\`echo $ODBC_LIBS | sed -e 's!.*/!!'\`" >&6; }
53043
53044  else
53045    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53046printf "%s\n" "no" >&6; }
53047  fi
53048fi
53049
53050if test -z "$ODBC_TYPE"; then
53051
53052php_with_empress_bcs=no
53053
53054
53055
53056# Check whether --with-empress-bcs was given.
53057if test ${with_empress_bcs+y}
53058then :
53059  withval=$with_empress_bcs; PHP_EMPRESS_BCS=$withval
53060else $as_nop
53061
53062  PHP_EMPRESS_BCS=no
53063  test "$PHP_ENABLE_ALL" && PHP_EMPRESS_BCS=$PHP_ENABLE_ALL
53064
53065fi
53066
53067
53068
53069ext_output="yes, shared"
53070ext_shared=yes
53071case $PHP_EMPRESS_BCS in
53072shared,*)
53073  PHP_EMPRESS_BCS=`echo "$PHP_EMPRESS_BCS"|$SED 's/^shared,//'`
53074  ;;
53075shared)
53076  PHP_EMPRESS_BCS=yes
53077  ;;
53078no)
53079  ext_output=no
53080  ext_shared=no
53081  ;;
53082*)
53083  ext_output=yes
53084  ext_shared=no
53085  ;;
53086esac
53087
53088
53089
53090
53091
53092
53093
53094
53095  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Empress local access support" >&5
53096printf %s "checking for Empress local access support... " >&6; }
53097  if test "$PHP_EMPRESS_BCS" != "no"; then
53098    if test "$PHP_EMPRESS_BCS" = "yes"; then
53099      ODBC_INCDIR=$EMPRESSPATH/include/odbc
53100      ODBC_LIBDIR=$EMPRESSPATH/shlib
53101    else
53102      ODBC_INCDIR=$PHP_EMPRESS_BCS/include/odbc
53103      ODBC_LIBDIR=$PHP_EMPRESS_BCS/shlib
53104    fi
53105    CC="empocc -bcs";export CC;
53106    LD="empocc -bcs";export LD;
53107    ODBC_CFLAGS=-I$ODBC_INCDIR
53108    ODBC_LFLAGS=-L$ODBC_LIBDIR
53109    LIST=`empocc -listlines -bcs -o a a.c`
53110
53111    NEWLIST=
53112    for I in $LIST
53113    do
53114      case $I in
53115        $EMPRESSPATH/odbccl/lib/* | \
53116        $EMPRESSPATH/rdbms/lib/* | \
53117        $EMPRESSPATH/common/lib/*)
53118              NEWLIST="$NEWLIST $I"
53119              ;;
53120      esac
53121    done
53122    ODBC_LIBS="-lempphpbcs -lms -lmscfg -lbasic -lbasic_os -lnlscstab -lnlsmsgtab -lm -ldl -lcrypt"
53123    ODBC_TYPE=empress-bcs
53124
53125printf "%s\n" "#define HAVE_EMPRESS 1" >>confdefs.h
53126
53127    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
53128printf "%s\n" "$ext_output" >&6; }
53129
53130  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Empress local access library file" >&5
53131printf %s "checking Empress local access library file... " >&6; }
53132  ODBCBCS_LIBS=`echo $ODBC_LIBDIR/libempodbcbcs.a | cut -d' ' -f1`
53133  if test ! -f $ODBCBCS_LIBS; then
53134    ODBCBCS_LIBS=`echo $ODBC_LIBDIR/libempodbcbcs.a | cut -d' ' -f1`
53135  fi
53136  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \`echo $ODBCBCS_LIBS | sed -e 's!.*/!!'\`" >&5
53137printf "%s\n" "\`echo $ODBCBCS_LIBS | sed -e 's!.*/!!'\`" >&6; }
53138
53139  else
53140    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53141printf "%s\n" "no" >&6; }
53142  fi
53143fi
53144
53145if test -z "$ODBC_TYPE"; then
53146
53147php_with_custom_odbc=no
53148
53149
53150
53151# Check whether --with-custom-odbc was given.
53152if test ${with_custom_odbc+y}
53153then :
53154  withval=$with_custom_odbc; PHP_CUSTOM_ODBC=$withval
53155else $as_nop
53156
53157  PHP_CUSTOM_ODBC=no
53158  test "$PHP_ENABLE_ALL" && PHP_CUSTOM_ODBC=$PHP_ENABLE_ALL
53159
53160fi
53161
53162
53163
53164ext_output="yes, shared"
53165ext_shared=yes
53166case $PHP_CUSTOM_ODBC in
53167shared,*)
53168  PHP_CUSTOM_ODBC=`echo "$PHP_CUSTOM_ODBC"|$SED 's/^shared,//'`
53169  ;;
53170shared)
53171  PHP_CUSTOM_ODBC=yes
53172  ;;
53173no)
53174  ext_output=no
53175  ext_shared=no
53176  ;;
53177*)
53178  ext_output=yes
53179  ext_shared=no
53180  ;;
53181esac
53182
53183
53184
53185
53186
53187
53188
53189
53190  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a custom ODBC support" >&5
53191printf %s "checking for a custom ODBC support... " >&6; }
53192  if test "$PHP_CUSTOM_ODBC" != "no"; then
53193    if test "$PHP_CUSTOM_ODBC" = "yes"; then
53194      PHP_CUSTOM_ODBC=/usr/local
53195    fi
53196    ODBC_INCDIR=$PHP_CUSTOM_ODBC/include
53197    ODBC_LIBDIR=$PHP_CUSTOM_ODBC/$PHP_LIBDIR
53198    ODBC_LFLAGS=-L$ODBC_LIBDIR
53199    ODBC_CFLAGS=-I$ODBC_INCDIR
53200    ODBC_LIBS=$CUSTOM_ODBC_LIBS
53201    ODBC_TYPE=custom-odbc
53202
53203printf "%s\n" "#define HAVE_CODBC 1" >>confdefs.h
53204
53205    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
53206printf "%s\n" "$ext_output" >&6; }
53207  else
53208    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53209printf "%s\n" "no" >&6; }
53210  fi
53211fi
53212
53213if test -z "$ODBC_TYPE"; then
53214
53215php_with_iodbc=no
53216
53217
53218
53219# Check whether --with-iodbc was given.
53220if test ${with_iodbc+y}
53221then :
53222  withval=$with_iodbc; PHP_IODBC=$withval
53223else $as_nop
53224
53225  PHP_IODBC=no
53226  test "$PHP_ENABLE_ALL" && PHP_IODBC=$PHP_ENABLE_ALL
53227
53228fi
53229
53230
53231
53232ext_output="yes, shared"
53233ext_shared=yes
53234case $PHP_IODBC in
53235shared,*)
53236  PHP_IODBC=`echo "$PHP_IODBC"|$SED 's/^shared,//'`
53237  ;;
53238shared)
53239  PHP_IODBC=yes
53240  ;;
53241no)
53242  ext_output=no
53243  ext_shared=no
53244  ;;
53245*)
53246  ext_output=yes
53247  ext_shared=no
53248  ;;
53249esac
53250
53251
53252
53253
53254
53255
53256
53257
53258  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with iODBC support" >&5
53259printf %s "checking whether to build with iODBC support... " >&6; }
53260  if test "$PHP_IODBC" != "no"; then
53261    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
53262printf "%s\n" "yes" >&6; }
53263
53264pkg_failed=no
53265{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libiodbc" >&5
53266printf %s "checking for libiodbc... " >&6; }
53267
53268if test -n "$ODBC_CFLAGS"; then
53269    pkg_cv_ODBC_CFLAGS="$ODBC_CFLAGS"
53270 elif test -n "$PKG_CONFIG"; then
53271    if test -n "$PKG_CONFIG" && \
53272    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libiodbc\""; } >&5
53273  ($PKG_CONFIG --exists --print-errors "libiodbc") 2>&5
53274  ac_status=$?
53275  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
53276  test $ac_status = 0; }; then
53277  pkg_cv_ODBC_CFLAGS=`$PKG_CONFIG --cflags "libiodbc" 2>/dev/null`
53278		      test "x$?" != "x0" && pkg_failed=yes
53279else
53280  pkg_failed=yes
53281fi
53282 else
53283    pkg_failed=untried
53284fi
53285if test -n "$ODBC_LIBS"; then
53286    pkg_cv_ODBC_LIBS="$ODBC_LIBS"
53287 elif test -n "$PKG_CONFIG"; then
53288    if test -n "$PKG_CONFIG" && \
53289    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libiodbc\""; } >&5
53290  ($PKG_CONFIG --exists --print-errors "libiodbc") 2>&5
53291  ac_status=$?
53292  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
53293  test $ac_status = 0; }; then
53294  pkg_cv_ODBC_LIBS=`$PKG_CONFIG --libs "libiodbc" 2>/dev/null`
53295		      test "x$?" != "x0" && pkg_failed=yes
53296else
53297  pkg_failed=yes
53298fi
53299 else
53300    pkg_failed=untried
53301fi
53302
53303
53304
53305if test $pkg_failed = yes; then
53306        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53307printf "%s\n" "no" >&6; }
53308
53309if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
53310        _pkg_short_errors_supported=yes
53311else
53312        _pkg_short_errors_supported=no
53313fi
53314        if test $_pkg_short_errors_supported = yes; then
53315	        ODBC_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libiodbc" 2>&1`
53316        else
53317	        ODBC_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libiodbc" 2>&1`
53318        fi
53319	# Put the nasty error message in config.log where it belongs
53320	echo "$ODBC_PKG_ERRORS" >&5
53321
53322	as_fn_error $? "Package requirements (libiodbc) were not met:
53323
53324$ODBC_PKG_ERRORS
53325
53326Consider adjusting the PKG_CONFIG_PATH environment variable if you
53327installed software in a non-standard prefix.
53328
53329Alternatively, you may set the environment variables ODBC_CFLAGS
53330and ODBC_LIBS to avoid the need to call pkg-config.
53331See the pkg-config man page for more details." "$LINENO" 5
53332elif test $pkg_failed = untried; then
53333        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53334printf "%s\n" "no" >&6; }
53335	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
53336printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
53337as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
53338is in your PATH or set the PKG_CONFIG environment variable to the full
53339path to pkg-config.
53340
53341Alternatively, you may set the environment variables ODBC_CFLAGS
53342and ODBC_LIBS to avoid the need to call pkg-config.
53343See the pkg-config man page for more details.
53344
53345To get pkg-config, see <http://pkg-config.freedesktop.org/>.
53346See \`config.log' for more details" "$LINENO" 5; }
53347else
53348	ODBC_CFLAGS=$pkg_cv_ODBC_CFLAGS
53349	ODBC_LIBS=$pkg_cv_ODBC_LIBS
53350        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
53351printf "%s\n" "yes" >&6; }
53352
53353fi
53354
53355  for ac_i in $ODBC_CFLAGS; do
53356    case $ac_i in
53357    -I*)
53358      ac_ii=`echo $ac_i|cut -c 3-`
53359
53360  if test "$ac_ii" != "/usr/include"; then
53361
53362  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
53363    ai_p=$ac_ii
53364  else
53365
53366    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
53367
53368    ep_realdir=`(cd "$ep_dir" && pwd)`
53369    ai_p="$ep_realdir"/`basename "$ac_ii"`
53370  fi
53371
53372
53373
53374  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
53375
53376  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
53377  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53378    eval "INCLUDEPATH$unique=set"
53379
53380      if test ""; then
53381        INCLUDES="-I$ai_p $INCLUDES"
53382      else
53383        INCLUDES="$INCLUDES -I$ai_p"
53384      fi
53385
53386  fi
53387
53388  fi
53389
53390    ;;
53391    esac
53392  done
53393
53394    ODBC_TYPE=iodbc
53395
53396printf "%s\n" "#define HAVE_IODBC 1" >>confdefs.h
53397
53398
53399printf "%s\n" "#define HAVE_ODBC2 1" >>confdefs.h
53400
53401  else
53402    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53403printf "%s\n" "no" >&6; }
53404  fi
53405fi
53406
53407if test -z "$ODBC_TYPE"; then
53408
53409php_with_esoob=no
53410
53411
53412
53413# Check whether --with-esoob was given.
53414if test ${with_esoob+y}
53415then :
53416  withval=$with_esoob; PHP_ESOOB=$withval
53417else $as_nop
53418
53419  PHP_ESOOB=no
53420  test "$PHP_ENABLE_ALL" && PHP_ESOOB=$PHP_ENABLE_ALL
53421
53422fi
53423
53424
53425
53426ext_output="yes, shared"
53427ext_shared=yes
53428case $PHP_ESOOB in
53429shared,*)
53430  PHP_ESOOB=`echo "$PHP_ESOOB"|$SED 's/^shared,//'`
53431  ;;
53432shared)
53433  PHP_ESOOB=yes
53434  ;;
53435no)
53436  ext_output=no
53437  ext_shared=no
53438  ;;
53439*)
53440  ext_output=yes
53441  ext_shared=no
53442  ;;
53443esac
53444
53445
53446
53447
53448
53449
53450
53451
53452  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Easysoft ODBC-ODBC Bridge support" >&5
53453printf %s "checking for Easysoft ODBC-ODBC Bridge support... " >&6; }
53454  if test "$PHP_ESOOB" != "no"; then
53455    if test "$PHP_ESOOB" = "yes"; then
53456      PHP_ESOOB=/usr/local/easysoft/oob/client
53457    fi
53458    ODBC_INCDIR=$PHP_ESOOB/include
53459    ODBC_LIBDIR=$PHP_ESOOB/$PHP_LIBDIR
53460    ODBC_LFLAGS=-L$ODBC_LIBDIR
53461    ODBC_CFLAGS=-I$ODBC_INCDIR
53462    ODBC_LIBS=-lesoobclient
53463    ODBC_TYPE=esoob
53464
53465printf "%s\n" "#define HAVE_ESOOB 1" >>confdefs.h
53466
53467    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
53468printf "%s\n" "$ext_output" >&6; }
53469  else
53470    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53471printf "%s\n" "no" >&6; }
53472  fi
53473fi
53474
53475if test -z "$ODBC_TYPE"; then
53476
53477php_with_unixodbc=no
53478
53479
53480
53481# Check whether --with-unixODBC was given.
53482if test ${with_unixODBC+y}
53483then :
53484  withval=$with_unixODBC; PHP_UNIXODBC=$withval
53485else $as_nop
53486
53487  PHP_UNIXODBC=no
53488  test "$PHP_ENABLE_ALL" && PHP_UNIXODBC=$PHP_ENABLE_ALL
53489
53490fi
53491
53492
53493
53494ext_output="yes, shared"
53495ext_shared=yes
53496case $PHP_UNIXODBC in
53497shared,*)
53498  PHP_UNIXODBC=`echo "$PHP_UNIXODBC"|$SED 's/^shared,//'`
53499  ;;
53500shared)
53501  PHP_UNIXODBC=yes
53502  ;;
53503no)
53504  ext_output=no
53505  ext_shared=no
53506  ;;
53507*)
53508  ext_output=yes
53509  ext_shared=no
53510  ;;
53511esac
53512
53513
53514
53515
53516
53517
53518
53519
53520  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with unixODBC support" >&5
53521printf %s "checking whether to build with unixODBC support... " >&6; }
53522  if test "$PHP_UNIXODBC" != "no"; then
53523    if test "$PHP_UNIXODBC" = "yes"; then
53524      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes from pkgconfig" >&5
53525printf "%s\n" "yes from pkgconfig" >&6; }
53526
53527pkg_failed=no
53528{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for odbc" >&5
53529printf %s "checking for odbc... " >&6; }
53530
53531if test -n "$ODBC_CFLAGS"; then
53532    pkg_cv_ODBC_CFLAGS="$ODBC_CFLAGS"
53533 elif test -n "$PKG_CONFIG"; then
53534    if test -n "$PKG_CONFIG" && \
53535    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"odbc\""; } >&5
53536  ($PKG_CONFIG --exists --print-errors "odbc") 2>&5
53537  ac_status=$?
53538  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
53539  test $ac_status = 0; }; then
53540  pkg_cv_ODBC_CFLAGS=`$PKG_CONFIG --cflags "odbc" 2>/dev/null`
53541		      test "x$?" != "x0" && pkg_failed=yes
53542else
53543  pkg_failed=yes
53544fi
53545 else
53546    pkg_failed=untried
53547fi
53548if test -n "$ODBC_LIBS"; then
53549    pkg_cv_ODBC_LIBS="$ODBC_LIBS"
53550 elif test -n "$PKG_CONFIG"; then
53551    if test -n "$PKG_CONFIG" && \
53552    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"odbc\""; } >&5
53553  ($PKG_CONFIG --exists --print-errors "odbc") 2>&5
53554  ac_status=$?
53555  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
53556  test $ac_status = 0; }; then
53557  pkg_cv_ODBC_LIBS=`$PKG_CONFIG --libs "odbc" 2>/dev/null`
53558		      test "x$?" != "x0" && pkg_failed=yes
53559else
53560  pkg_failed=yes
53561fi
53562 else
53563    pkg_failed=untried
53564fi
53565
53566
53567
53568if test $pkg_failed = yes; then
53569        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53570printf "%s\n" "no" >&6; }
53571
53572if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
53573        _pkg_short_errors_supported=yes
53574else
53575        _pkg_short_errors_supported=no
53576fi
53577        if test $_pkg_short_errors_supported = yes; then
53578	        ODBC_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "odbc" 2>&1`
53579        else
53580	        ODBC_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "odbc" 2>&1`
53581        fi
53582	# Put the nasty error message in config.log where it belongs
53583	echo "$ODBC_PKG_ERRORS" >&5
53584
53585	as_fn_error $? "Package requirements (odbc) were not met:
53586
53587$ODBC_PKG_ERRORS
53588
53589Consider adjusting the PKG_CONFIG_PATH environment variable if you
53590installed software in a non-standard prefix.
53591
53592Alternatively, you may set the environment variables ODBC_CFLAGS
53593and ODBC_LIBS to avoid the need to call pkg-config.
53594See the pkg-config man page for more details." "$LINENO" 5
53595elif test $pkg_failed = untried; then
53596        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53597printf "%s\n" "no" >&6; }
53598	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
53599printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
53600as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
53601is in your PATH or set the PKG_CONFIG environment variable to the full
53602path to pkg-config.
53603
53604Alternatively, you may set the environment variables ODBC_CFLAGS
53605and ODBC_LIBS to avoid the need to call pkg-config.
53606See the pkg-config man page for more details.
53607
53608To get pkg-config, see <http://pkg-config.freedesktop.org/>.
53609See \`config.log' for more details" "$LINENO" 5; }
53610else
53611	ODBC_CFLAGS=$pkg_cv_ODBC_CFLAGS
53612	ODBC_LIBS=$pkg_cv_ODBC_LIBS
53613        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
53614printf "%s\n" "yes" >&6; }
53615
53616fi
53617
53618  for ac_i in $ODBC_CFLAGS; do
53619    case $ac_i in
53620    -I*)
53621      ac_ii=`echo $ac_i|cut -c 3-`
53622
53623  if test "$ac_ii" != "/usr/include"; then
53624
53625  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
53626    ai_p=$ac_ii
53627  else
53628
53629    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
53630
53631    ep_realdir=`(cd "$ep_dir" && pwd)`
53632    ai_p="$ep_realdir"/`basename "$ac_ii"`
53633  fi
53634
53635
53636
53637  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
53638
53639  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
53640  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53641    eval "INCLUDEPATH$unique=set"
53642
53643      if test ""; then
53644        INCLUDES="-I$ai_p $INCLUDES"
53645      else
53646        INCLUDES="$INCLUDES -I$ai_p"
53647      fi
53648
53649  fi
53650
53651  fi
53652
53653    ;;
53654    esac
53655  done
53656
53657    else
53658            ODBC_INCDIR=$PHP_UNIXODBC/include
53659      ODBC_LIBDIR=$PHP_UNIXODBC/$PHP_LIBDIR
53660      ODBC_LFLAGS=-L$ODBC_LIBDIR
53661      ODBC_CFLAGS=-I$ODBC_INCDIR
53662      ODBC_LIBS=-lodbc
53663
53664if ! test -f "$ODBC_INCDIR/sqlext.h"; then
53665  as_fn_error $? "ODBC header file '$ODBC_INCDIR/sqlext.h' not found!" "$LINENO" 5
53666fi
53667
53668      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes in $PHP_UNIXODBC" >&5
53669printf "%s\n" "yes in $PHP_UNIXODBC" >&6; }
53670    fi
53671    ODBC_TYPE=unixODBC
53672
53673printf "%s\n" "#define HAVE_UNIXODBC 1" >>confdefs.h
53674
53675  else
53676    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53677printf "%s\n" "no" >&6; }
53678  fi
53679fi
53680
53681if test -z "$ODBC_TYPE"; then
53682
53683php_with_dbmaker=no
53684
53685
53686
53687# Check whether --with-dbmaker was given.
53688if test ${with_dbmaker+y}
53689then :
53690  withval=$with_dbmaker; PHP_DBMAKER=$withval
53691else $as_nop
53692
53693  PHP_DBMAKER=no
53694  test "$PHP_ENABLE_ALL" && PHP_DBMAKER=$PHP_ENABLE_ALL
53695
53696fi
53697
53698
53699
53700ext_output="yes, shared"
53701ext_shared=yes
53702case $PHP_DBMAKER in
53703shared,*)
53704  PHP_DBMAKER=`echo "$PHP_DBMAKER"|$SED 's/^shared,//'`
53705  ;;
53706shared)
53707  PHP_DBMAKER=yes
53708  ;;
53709no)
53710  ext_output=no
53711  ext_shared=no
53712  ;;
53713*)
53714  ext_output=yes
53715  ext_shared=no
53716  ;;
53717esac
53718
53719
53720
53721
53722
53723
53724
53725
53726  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for DBMaker support" >&5
53727printf %s "checking for DBMaker support... " >&6; }
53728  if test "$PHP_DBMAKER" != "no"; then
53729    if test "$PHP_DBMAKER" = "yes"; then
53730            DBMAKER_HOME=`grep "^dbmaker:" /etc/passwd | $AWK -F: '{print $6}'`
53731
53732            DBMAKER_VERSION=5.0
53733
53734      while test ! -d $DBMAKER_HOME/$DBMAKER_VERSION -a "$DBMAKER_VERSION" != "2.9"; do
53735        DM_VER=`echo $DBMAKER_VERSION | sed -e 's/\.//' | $AWK '{ print $1-1;}'`
53736        MAJOR_V=`echo $DM_VER | $AWK '{ print $1/10; }'  | $AWK -F. '{ print $1; }'`
53737        MINOR_V=`echo $DM_VER | $AWK '{ print $1%10; }'`
53738        DBMAKER_VERSION=$MAJOR_V.$MINOR_V
53739      done
53740
53741      if test "$DBMAKER_VERSION" = "2.9"; then
53742        PHP_DBMAKER=$DBMAKER_HOME
53743      else
53744        PHP_DBMAKER=$DBMAKER_HOME/$DBMAKER_VERSION
53745      fi
53746    fi
53747
53748    ODBC_INCDIR=$PHP_DBMAKER/include
53749    ODBC_LIBDIR=$PHP_DBMAKER/$PHP_LIBDIR
53750    ODBC_CFLAGS=-I$ODBC_INCDIR
53751    ODBC_LFLAGS=-L$ODBC_LIBDIR
53752    ODBC_LIBS="-ldmapic -lc"
53753    ODBC_TYPE=dbmaker
53754
53755
53756printf "%s\n" "#define HAVE_DBMAKER 1" >>confdefs.h
53757
53758
53759    if test "$ext_shared" = "yes"; then
53760      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (shared)" >&5
53761printf "%s\n" "yes (shared)" >&6; }
53762      ODBC_LIBS="-ldmapic -lc -lm"
53763      ODBC_SHARED="odbc.la"
53764    else
53765      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (static)" >&5
53766printf "%s\n" "yes (static)" >&6; }
53767
53768
53769  if test -n "$ODBC_LIBDIR"; then
53770
53771  if test "$ODBC_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$ODBC_LIBDIR" != "/usr/lib"; then
53772
53773  if test -z "$ODBC_LIBDIR" || echo "$ODBC_LIBDIR" | grep '^/' >/dev/null ; then
53774    ai_p=$ODBC_LIBDIR
53775  else
53776
53777    ep_dir=`echo $ODBC_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
53778
53779    ep_realdir=`(cd "$ep_dir" && pwd)`
53780    ai_p="$ep_realdir"/`basename "$ODBC_LIBDIR"`
53781  fi
53782
53783
53784
53785
53786
53787  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
53788
53789  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
53790  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53791    eval "LIBPATH$unique=set"
53792
53793    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
53794    LDFLAGS="$LDFLAGS -L$ai_p"
53795    PHP_RPATHS="$PHP_RPATHS $ai_p"
53796
53797  fi
53798
53799
53800
53801  fi
53802
53803  fi
53804
53805
53806  case dmapic in
53807  c|c_r) ;;
53808  *)
53809      LIBS="-ldmapic $LIBS"
53810   ;;
53811  esac
53812
53813
53814
53815
53816
53817  if test "$ODBC_INCDIR" != "/usr/include"; then
53818
53819  if test -z "$ODBC_INCDIR" || echo "$ODBC_INCDIR" | grep '^/' >/dev/null ; then
53820    ai_p=$ODBC_INCDIR
53821  else
53822
53823    ep_dir=`echo $ODBC_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
53824
53825    ep_realdir=`(cd "$ep_dir" && pwd)`
53826    ai_p="$ep_realdir"/`basename "$ODBC_INCDIR"`
53827  fi
53828
53829
53830
53831  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
53832
53833  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
53834  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53835    eval "INCLUDEPATH$unique=set"
53836
53837      if test ""; then
53838        INCLUDES="-I$ai_p $INCLUDES"
53839      else
53840        INCLUDES="$INCLUDES -I$ai_p"
53841      fi
53842
53843  fi
53844
53845  fi
53846
53847      ODBC_STATIC="libphpext_odbc.la"
53848    fi
53849  else
53850    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
53851printf "%s\n" "no" >&6; }
53852  fi
53853fi
53854
53855if test "no" != "$PHP_ODBCVER"; then
53856  if test "$PHP_ODBCVER" != "0"; then
53857
53858printf "%s\n" "#define ODBCVER $PHP_ODBCVER" >>confdefs.h
53859
53860  fi
53861else
53862
53863printf "%s\n" "#define ODBCVER 0x0300" >>confdefs.h
53864
53865fi
53866
53867if test -n "$ODBC_TYPE"; then
53868  if test "$ODBC_TYPE" != "dbmaker"; then
53869
53870  for ac_i in $ODBC_LFLAGS $ODBC_LIBS; do
53871    case $ac_i in
53872    -pthread)
53873      if test "$ext_shared" = "yes"; then
53874        ODBC_SHARED_LIBADD="$ODBC_SHARED_LIBADD -pthread"
53875      else
53876
53877
53878  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
53879
53880  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
53881  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53882    eval "EXTRA_LDFLAGS$unique=set"
53883    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
53884  fi
53885
53886
53887
53888  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
53889
53890  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
53891  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53892    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
53893    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
53894  fi
53895
53896      fi
53897    ;;
53898    -l*)
53899      ac_ii=`echo $ac_i|cut -c 3-`
53900
53901
53902  case $ac_ii in
53903  c|c_r) ;;
53904  *)
53905    if test "$ext_shared" = "yes"; then
53906        ODBC_SHARED_LIBADD="$ODBC_SHARED_LIBADD -l$ac_ii"
53907    else
53908
53909
53910  case $ac_ii in
53911  c|c_r) ;;
53912  *)
53913      LIBS="$LIBS -l$ac_ii"
53914   ;;
53915  esac
53916
53917
53918    fi
53919   ;;
53920  esac
53921
53922
53923    ;;
53924    -L*)
53925      ac_ii=`echo $ac_i|cut -c 3-`
53926
53927  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
53928
53929  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
53930    ai_p=$ac_ii
53931  else
53932
53933    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
53934
53935    ep_realdir=`(cd "$ep_dir" && pwd)`
53936    ai_p="$ep_realdir"/`basename "$ac_ii"`
53937  fi
53938
53939
53940      if test "$ext_shared" = "yes"; then
53941        ODBC_SHARED_LIBADD="-L$ai_p $ODBC_SHARED_LIBADD"
53942        test -n "$ld_runpath_switch" && ODBC_SHARED_LIBADD="$ld_runpath_switch$ai_p $ODBC_SHARED_LIBADD"
53943      else
53944
53945
53946
53947  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
53948
53949  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
53950  if test -n "$unique" && test "`eval $cmd`" = "" ; then
53951    eval "LIBPATH$unique=set"
53952
53953    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
53954    LDFLAGS="$LDFLAGS -L$ai_p"
53955    PHP_RPATHS="$PHP_RPATHS $ai_p"
53956
53957  fi
53958
53959
53960      fi
53961
53962  fi
53963
53964    ;;
53965    esac
53966  done
53967
53968    if test "$ODBC_TYPE" != "solid"; then
53969
53970printf "%s\n" "#define HAVE_SQLDATASOURCES 1" >>confdefs.h
53971
53972    fi
53973  fi
53974
53975
53976printf "%s\n" "#define HAVE_UODBC 1" >>confdefs.h
53977
53978
53979  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_SHARED_LIBADD"
53980
53981
53982  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_INCDIR"
53983
53984
53985  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_LIBDIR"
53986
53987
53988
53989
53990  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_CFLAGS"
53991
53992
53993
53994
53995
53996  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_LIBS"
53997
53998
53999
54000
54001
54002  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_LFLAGS"
54003
54004
54005
54006
54007
54008  PHP_VAR_SUBST="$PHP_VAR_SUBST ODBC_TYPE"
54009
54010
54011
54012
54013  ext_builddir=ext/odbc
54014  ext_srcdir=$abs_srcdir/ext/odbc
54015  ext_dir=ext/odbc
54016
54017  ac_extra=`echo "$ODBC_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
54018
54019  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
54020    PHP_ODBC_SHARED=no
54021
54022
54023  case $ext_dir in
54024  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
54025  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
54026  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
54027  esac
54028
54029
54030
54031  b_c_pre=$php_c_pre
54032  b_cxx_pre=$php_cxx_pre
54033  b_c_meta=$php_c_meta
54034  b_cxx_meta=$php_cxx_meta
54035  b_c_post=$php_c_post
54036  b_cxx_post=$php_cxx_post
54037  b_lo=$php_lo
54038
54039
54040  old_IFS=$IFS
54041  for ac_src in php_odbc.c; do
54042
54043      IFS=.
54044      set $ac_src
54045      ac_obj=$1
54046      IFS=$old_IFS
54047
54048      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
54049
54050      case $ac_src in
54051        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54052        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54053        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54054        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
54055      esac
54056
54057      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
54058
54059    cat >>Makefile.objects<<EOF
54060-include $ac_bdir$ac_obj.dep
54061$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
54062	$ac_comp
54063EOF
54064  done
54065
54066
54067    EXT_STATIC="$EXT_STATIC odbc;$ext_dir"
54068    if test "$ext_shared" != "nocli"; then
54069      EXT_CLI_STATIC="$EXT_CLI_STATIC odbc;$ext_dir"
54070    fi
54071  else
54072    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
54073      PHP_ODBC_SHARED=yes
54074
54075  case $ext_dir in
54076  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
54077  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
54078  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
54079  esac
54080
54081
54082
54083  b_c_pre=$shared_c_pre
54084  b_cxx_pre=$shared_cxx_pre
54085  b_c_meta=$shared_c_meta
54086  b_cxx_meta=$shared_cxx_meta
54087  b_c_post=$shared_c_post
54088  b_cxx_post=$shared_cxx_post
54089  b_lo=$shared_lo
54090
54091
54092  old_IFS=$IFS
54093  for ac_src in php_odbc.c; do
54094
54095      IFS=.
54096      set $ac_src
54097      ac_obj=$1
54098      IFS=$old_IFS
54099
54100      shared_objects_odbc="$shared_objects_odbc $ac_bdir$ac_obj.lo"
54101
54102      case $ac_src in
54103        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54104        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54105        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54106        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
54107      esac
54108
54109      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
54110
54111    cat >>Makefile.objects<<EOF
54112-include $ac_bdir$ac_obj.dep
54113$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
54114	$ac_comp
54115EOF
54116  done
54117
54118
54119  install_modules="install-modules"
54120  suffix=la
54121
54122  case $host_alias in
54123    *aix*)
54124      additional_flags="-Wl,-G"
54125      ;;
54126  esac
54127
54128  if test "x" = "xyes"; then
54129    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/odbc.$suffix"
54130  else
54131    PHP_MODULES="$PHP_MODULES \$(phplibdir)/odbc.$suffix"
54132  fi
54133
54134  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_odbc"
54135
54136  cat >>Makefile.objects<<EOF
54137\$(phplibdir)/odbc.$suffix: $ext_builddir/odbc.$suffix
54138	\$(LIBTOOL) --mode=install cp $ext_builddir/odbc.$suffix \$(phplibdir)
54139
54140$ext_builddir/odbc.$suffix: \$(shared_objects_odbc) \$(ODBC_SHARED_DEPENDENCIES)
54141	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_odbc) \$(ODBC_SHARED_LIBADD)
54142
54143EOF
54144
54145
54146printf "%s\n" "#define COMPILE_DL_ODBC 1" >>confdefs.h
54147
54148    fi
54149  fi
54150
54151  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
54152    PHP_ODBC_SHARED=no
54153    case "$PHP_SAPI" in
54154      cgi|embed|phpdbg)
54155
54156
54157  case $ext_dir in
54158  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
54159  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
54160  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
54161  esac
54162
54163
54164
54165  b_c_pre=$php_c_pre
54166  b_cxx_pre=$php_cxx_pre
54167  b_c_meta=$php_c_meta
54168  b_cxx_meta=$php_cxx_meta
54169  b_c_post=$php_c_post
54170  b_cxx_post=$php_cxx_post
54171  b_lo=$php_lo
54172
54173
54174  old_IFS=$IFS
54175  for ac_src in php_odbc.c; do
54176
54177      IFS=.
54178      set $ac_src
54179      ac_obj=$1
54180      IFS=$old_IFS
54181
54182      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
54183
54184      case $ac_src in
54185        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54186        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54187        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54188        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
54189      esac
54190
54191      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
54192
54193    cat >>Makefile.objects<<EOF
54194-include $ac_bdir$ac_obj.dep
54195$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
54196	$ac_comp
54197EOF
54198  done
54199
54200
54201        EXT_STATIC="$EXT_STATIC odbc;$ext_dir"
54202        ;;
54203      *)
54204
54205
54206  case $ext_dir in
54207  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
54208  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
54209  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
54210  esac
54211
54212
54213
54214  b_c_pre=$php_c_pre
54215  b_cxx_pre=$php_cxx_pre
54216  b_c_meta=$php_c_meta
54217  b_cxx_meta=$php_cxx_meta
54218  b_c_post=$php_c_post
54219  b_cxx_post=$php_cxx_post
54220  b_lo=$php_lo
54221
54222
54223  old_IFS=$IFS
54224  for ac_src in php_odbc.c; do
54225
54226      IFS=.
54227      set $ac_src
54228      ac_obj=$1
54229      IFS=$old_IFS
54230
54231      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
54232
54233      case $ac_src in
54234        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54235        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54236        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
54237        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
54238      esac
54239
54240      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
54241
54242    cat >>Makefile.objects<<EOF
54243-include $ac_bdir$ac_obj.dep
54244$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
54245	$ac_comp
54246EOF
54247  done
54248
54249
54250        ;;
54251    esac
54252    EXT_CLI_STATIC="$EXT_CLI_STATIC odbc;$ext_dir"
54253  fi
54254
54255
54256    BUILD_DIR="$BUILD_DIR $ext_builddir"
54257
54258
54259
54260  if test "$ext_builddir" = "."; then
54261    PHP_PECL_EXTENSION=odbc
54262
54263  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
54264
54265  fi
54266
54267else
54268  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for any ODBC driver support" >&5
54269printf %s "checking for any ODBC driver support... " >&6; }
54270  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54271printf "%s\n" "no" >&6; }
54272fi
54273
54274
54275
54276
54277
54278php_enable_opcache=yes
54279
54280{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable Zend OPcache support" >&5
54281printf %s "checking whether to enable Zend OPcache support... " >&6; }
54282# Check whether --enable-opcache was given.
54283if test ${enable_opcache+y}
54284then :
54285  enableval=$enable_opcache; PHP_OPCACHE=$enableval
54286else $as_nop
54287
54288  PHP_OPCACHE=yes
54289  test "$PHP_ENABLE_ALL" && PHP_OPCACHE=$PHP_ENABLE_ALL
54290
54291fi
54292
54293
54294
54295ext_output="yes, shared"
54296ext_shared=yes
54297case $PHP_OPCACHE in
54298shared,*)
54299  PHP_OPCACHE=`echo "$PHP_OPCACHE"|$SED 's/^shared,//'`
54300  ;;
54301shared)
54302  PHP_OPCACHE=yes
54303  ;;
54304no)
54305  ext_output=no
54306  ext_shared=no
54307  ;;
54308*)
54309  ext_output=yes
54310  ext_shared=no
54311  ;;
54312esac
54313
54314
54315
54316{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
54317printf "%s\n" "$ext_output" >&6; }
54318
54319
54320
54321
54322
54323php_enable_huge_code_pages=yes
54324
54325{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable copying PHP CODE pages into HUGE PAGES" >&5
54326printf %s "checking whether to enable copying PHP CODE pages into HUGE PAGES... " >&6; }
54327# Check whether --enable-huge-code-pages was given.
54328if test ${enable_huge_code_pages+y}
54329then :
54330  enableval=$enable_huge_code_pages; PHP_HUGE_CODE_PAGES=$enableval
54331else $as_nop
54332
54333  PHP_HUGE_CODE_PAGES=yes
54334
54335
54336fi
54337
54338
54339ext_output=$PHP_HUGE_CODE_PAGES
54340{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
54341printf "%s\n" "$ext_output" >&6; }
54342
54343
54344
54345
54346
54347php_enable_opcache_jit=yes
54348
54349{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable JIT" >&5
54350printf %s "checking whether to enable JIT... " >&6; }
54351# Check whether --enable-opcache-jit was given.
54352if test ${enable_opcache_jit+y}
54353then :
54354  enableval=$enable_opcache_jit; PHP_OPCACHE_JIT=$enableval
54355else $as_nop
54356
54357  PHP_OPCACHE_JIT=yes
54358
54359
54360fi
54361
54362
54363ext_output=$PHP_OPCACHE_JIT
54364{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
54365printf "%s\n" "$ext_output" >&6; }
54366
54367
54368
54369
54370if test "$PHP_OPCACHE" != "no"; then
54371
54372    ext_shared=yes
54373
54374  if test "$PHP_HUGE_CODE_PAGES" = "yes"; then
54375
54376printf "%s\n" "#define HAVE_HUGE_CODE_PAGES 1" >>confdefs.h
54377
54378  fi
54379
54380  if test "$PHP_OPCACHE_JIT" = "yes"; then
54381    case $host_cpu in
54382      i[34567]86*|x86*|aarch64)
54383        ;;
54384      *)
54385        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: JIT not supported by host architecture" >&5
54386printf "%s\n" "$as_me: WARNING: JIT not supported by host architecture" >&2;}
54387        PHP_OPCACHE_JIT=no
54388        ;;
54389    esac
54390  fi
54391
54392  if test "$PHP_OPCACHE_JIT" = "yes"; then
54393
54394printf "%s\n" "#define HAVE_JIT 1" >>confdefs.h
54395
54396    ZEND_JIT_SRC="jit/zend_jit.c jit/zend_jit_gdb.c jit/zend_jit_vm_helpers.c"
54397
54398        case $host_alias in
54399      x86_64-*-darwin*)
54400        DASM_FLAGS="-D X64APPLE=1 -D X64=1"
54401        DASM_ARCH="x86"
54402        ;;
54403      x86_64*)
54404        DASM_FLAGS="-D X64=1"
54405        DASM_ARCH="x86"
54406        ;;
54407      i[34567]86*)
54408        DASM_ARCH="x86"
54409        ;;
54410      x86*)
54411        DASM_ARCH="x86"
54412        ;;
54413      aarch64*)
54414        DASM_FLAGS="-D ARM64=1"
54415        DASM_ARCH="arm64"
54416        ;;
54417    esac
54418
54419    if test "$PHP_THREAD_SAFETY" = "yes"; then
54420      DASM_FLAGS="$DASM_FLAGS -D ZTS=1"
54421    fi
54422
54423
54424pkg_failed=no
54425{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for capstone >= 3.0.0" >&5
54426printf %s "checking for capstone >= 3.0.0... " >&6; }
54427
54428if test -n "$CAPSTONE_CFLAGS"; then
54429    pkg_cv_CAPSTONE_CFLAGS="$CAPSTONE_CFLAGS"
54430 elif test -n "$PKG_CONFIG"; then
54431    if test -n "$PKG_CONFIG" && \
54432    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"capstone >= 3.0.0\""; } >&5
54433  ($PKG_CONFIG --exists --print-errors "capstone >= 3.0.0") 2>&5
54434  ac_status=$?
54435  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
54436  test $ac_status = 0; }; then
54437  pkg_cv_CAPSTONE_CFLAGS=`$PKG_CONFIG --cflags "capstone >= 3.0.0" 2>/dev/null`
54438		      test "x$?" != "x0" && pkg_failed=yes
54439else
54440  pkg_failed=yes
54441fi
54442 else
54443    pkg_failed=untried
54444fi
54445if test -n "$CAPSTONE_LIBS"; then
54446    pkg_cv_CAPSTONE_LIBS="$CAPSTONE_LIBS"
54447 elif test -n "$PKG_CONFIG"; then
54448    if test -n "$PKG_CONFIG" && \
54449    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"capstone >= 3.0.0\""; } >&5
54450  ($PKG_CONFIG --exists --print-errors "capstone >= 3.0.0") 2>&5
54451  ac_status=$?
54452  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
54453  test $ac_status = 0; }; then
54454  pkg_cv_CAPSTONE_LIBS=`$PKG_CONFIG --libs "capstone >= 3.0.0" 2>/dev/null`
54455		      test "x$?" != "x0" && pkg_failed=yes
54456else
54457  pkg_failed=yes
54458fi
54459 else
54460    pkg_failed=untried
54461fi
54462
54463
54464
54465if test $pkg_failed = yes; then
54466        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54467printf "%s\n" "no" >&6; }
54468
54469if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
54470        _pkg_short_errors_supported=yes
54471else
54472        _pkg_short_errors_supported=no
54473fi
54474        if test $_pkg_short_errors_supported = yes; then
54475	        CAPSTONE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "capstone >= 3.0.0" 2>&1`
54476        else
54477	        CAPSTONE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "capstone >= 3.0.0" 2>&1`
54478        fi
54479	# Put the nasty error message in config.log where it belongs
54480	echo "$CAPSTONE_PKG_ERRORS" >&5
54481
54482	have_capstone="no"
54483elif test $pkg_failed = untried; then
54484        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54485printf "%s\n" "no" >&6; }
54486	have_capstone="no"
54487else
54488	CAPSTONE_CFLAGS=$pkg_cv_CAPSTONE_CFLAGS
54489	CAPSTONE_LIBS=$pkg_cv_CAPSTONE_LIBS
54490        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
54491printf "%s\n" "yes" >&6; }
54492	have_capstone="yes"
54493fi
54494    if test "$have_capstone" = "yes"; then
54495
54496printf "%s\n" "#define HAVE_CAPSTONE 1" >>confdefs.h
54497
54498
54499  for ac_i in $CAPSTONE_LIBS; do
54500    case $ac_i in
54501    -pthread)
54502      if test "$ext_shared" = "yes"; then
54503        OPCACHE_SHARED_LIBADD="$OPCACHE_SHARED_LIBADD -pthread"
54504      else
54505
54506
54507  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
54508
54509  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
54510  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54511    eval "EXTRA_LDFLAGS$unique=set"
54512    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
54513  fi
54514
54515
54516
54517  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
54518
54519  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
54520  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54521    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
54522    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
54523  fi
54524
54525      fi
54526    ;;
54527    -l*)
54528      ac_ii=`echo $ac_i|cut -c 3-`
54529
54530
54531  case $ac_ii in
54532  c|c_r) ;;
54533  *)
54534    if test "$ext_shared" = "yes"; then
54535        OPCACHE_SHARED_LIBADD="$OPCACHE_SHARED_LIBADD -l$ac_ii"
54536    else
54537
54538
54539  case $ac_ii in
54540  c|c_r) ;;
54541  *)
54542      LIBS="$LIBS -l$ac_ii"
54543   ;;
54544  esac
54545
54546
54547    fi
54548   ;;
54549  esac
54550
54551
54552    ;;
54553    -L*)
54554      ac_ii=`echo $ac_i|cut -c 3-`
54555
54556  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
54557
54558  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
54559    ai_p=$ac_ii
54560  else
54561
54562    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
54563
54564    ep_realdir=`(cd "$ep_dir" && pwd)`
54565    ai_p="$ep_realdir"/`basename "$ac_ii"`
54566  fi
54567
54568
54569      if test "$ext_shared" = "yes"; then
54570        OPCACHE_SHARED_LIBADD="-L$ai_p $OPCACHE_SHARED_LIBADD"
54571        test -n "$ld_runpath_switch" && OPCACHE_SHARED_LIBADD="$ld_runpath_switch$ai_p $OPCACHE_SHARED_LIBADD"
54572      else
54573
54574
54575
54576  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54577
54578  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
54579  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54580    eval "LIBPATH$unique=set"
54581
54582    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
54583    LDFLAGS="$LDFLAGS -L$ai_p"
54584    PHP_RPATHS="$PHP_RPATHS $ai_p"
54585
54586  fi
54587
54588
54589      fi
54590
54591  fi
54592
54593    ;;
54594    esac
54595  done
54596
54597
54598  for ac_i in $CAPSTONE_CFLAGS; do
54599    case $ac_i in
54600    -I*)
54601      ac_ii=`echo $ac_i|cut -c 3-`
54602
54603  if test "$ac_ii" != "/usr/include"; then
54604
54605  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
54606    ai_p=$ac_ii
54607  else
54608
54609    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
54610
54611    ep_realdir=`(cd "$ep_dir" && pwd)`
54612    ai_p="$ep_realdir"/`basename "$ac_ii"`
54613  fi
54614
54615
54616
54617  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54618
54619  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
54620  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54621    eval "INCLUDEPATH$unique=set"
54622
54623      if test ""; then
54624        INCLUDES="-I$ai_p $INCLUDES"
54625      else
54626        INCLUDES="$INCLUDES -I$ai_p"
54627      fi
54628
54629  fi
54630
54631  fi
54632
54633    ;;
54634    esac
54635  done
54636
54637    fi
54638
54639
54640  PHP_VAR_SUBST="$PHP_VAR_SUBST DASM_FLAGS"
54641
54642
54643  PHP_VAR_SUBST="$PHP_VAR_SUBST DASM_ARCH"
54644
54645
54646    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for opagent in default path" >&5
54647printf %s "checking for opagent in default path... " >&6; }
54648    for i in /usr/local /usr; do
54649      if test -r $i/include/opagent.h; then
54650        OPAGENT_DIR=$i
54651        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found in $i" >&5
54652printf "%s\n" "found in $i" >&6; }
54653        break
54654      fi
54655    done
54656    if test -z "$OPAGENT_DIR"; then
54657      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
54658printf "%s\n" "not found" >&6; }
54659    else
54660
54661  save_old_LDFLAGS=$LDFLAGS
54662  ac_stuff="
54663        -L$OPAGENT_DIR/$PHP_LIBDIR/oprofile
54664      "
54665
54666  save_ext_shared=$ext_shared
54667  ext_shared=yes
54668
54669  for ac_i in $ac_stuff; do
54670    case $ac_i in
54671    -pthread)
54672      if test "$ext_shared" = "yes"; then
54673        LDFLAGS="$LDFLAGS -pthread"
54674      else
54675
54676
54677  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
54678
54679  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
54680  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54681    eval "EXTRA_LDFLAGS$unique=set"
54682    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
54683  fi
54684
54685
54686
54687  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
54688
54689  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
54690  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54691    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
54692    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
54693  fi
54694
54695      fi
54696    ;;
54697    -l*)
54698      ac_ii=`echo $ac_i|cut -c 3-`
54699
54700
54701  case $ac_ii in
54702  c|c_r) ;;
54703  *)
54704    if test "$ext_shared" = "yes"; then
54705        LDFLAGS="$LDFLAGS -l$ac_ii"
54706    else
54707
54708
54709  case $ac_ii in
54710  c|c_r) ;;
54711  *)
54712      LIBS="$LIBS -l$ac_ii"
54713   ;;
54714  esac
54715
54716
54717    fi
54718   ;;
54719  esac
54720
54721
54722    ;;
54723    -L*)
54724      ac_ii=`echo $ac_i|cut -c 3-`
54725
54726  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
54727
54728  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
54729    ai_p=$ac_ii
54730  else
54731
54732    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
54733
54734    ep_realdir=`(cd "$ep_dir" && pwd)`
54735    ai_p="$ep_realdir"/`basename "$ac_ii"`
54736  fi
54737
54738
54739      if test "$ext_shared" = "yes"; then
54740        LDFLAGS="-L$ai_p $LDFLAGS"
54741        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
54742      else
54743
54744
54745
54746  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54747
54748  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
54749  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54750    eval "LIBPATH$unique=set"
54751
54752    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
54753    LDFLAGS="$LDFLAGS -L$ai_p"
54754    PHP_RPATHS="$PHP_RPATHS $ai_p"
54755
54756  fi
54757
54758
54759      fi
54760
54761  fi
54762
54763    ;;
54764    esac
54765  done
54766
54767  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for op_write_native_code in -lopagent" >&5
54768printf %s "checking for op_write_native_code in -lopagent... " >&6; }
54769if test ${ac_cv_lib_opagent_op_write_native_code+y}
54770then :
54771  printf %s "(cached) " >&6
54772else $as_nop
54773  ac_check_lib_save_LIBS=$LIBS
54774LIBS="-lopagent  $LIBS"
54775cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54776/* end confdefs.h.  */
54777
54778/* Override any GCC internal prototype to avoid an error.
54779   Use char because int might match the return type of a GCC
54780   builtin and then its argument prototype would still apply.  */
54781char op_write_native_code ();
54782int
54783main (void)
54784{
54785return op_write_native_code ();
54786  ;
54787  return 0;
54788}
54789_ACEOF
54790if ac_fn_c_try_link "$LINENO"
54791then :
54792  ac_cv_lib_opagent_op_write_native_code=yes
54793else $as_nop
54794  ac_cv_lib_opagent_op_write_native_code=no
54795fi
54796rm -f core conftest.err conftest.$ac_objext conftest.beam \
54797    conftest$ac_exeext conftest.$ac_ext
54798LIBS=$ac_check_lib_save_LIBS
54799fi
54800{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_opagent_op_write_native_code" >&5
54801printf "%s\n" "$ac_cv_lib_opagent_op_write_native_code" >&6; }
54802if test "x$ac_cv_lib_opagent_op_write_native_code" = xyes
54803then :
54804
54805    LDFLAGS=$save_old_LDFLAGS
54806    ext_shared=$save_ext_shared
54807
54808
54809printf "%s\n" "#define HAVE_OPROFILE 1" >>confdefs.h
54810
54811
54812  if test "$OPAGENT_DIR/include" != "/usr/include"; then
54813
54814  if test -z "$OPAGENT_DIR/include" || echo "$OPAGENT_DIR/include" | grep '^/' >/dev/null ; then
54815    ai_p=$OPAGENT_DIR/include
54816  else
54817
54818    ep_dir=`echo $OPAGENT_DIR/include|$SED 's%/*[^/][^/]*/*$%%'`
54819
54820    ep_realdir=`(cd "$ep_dir" && pwd)`
54821    ai_p="$ep_realdir"/`basename "$OPAGENT_DIR/include"`
54822  fi
54823
54824
54825
54826  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54827
54828  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
54829  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54830    eval "INCLUDEPATH$unique=set"
54831
54832      if test ""; then
54833        INCLUDES="-I$ai_p $INCLUDES"
54834      else
54835        INCLUDES="$INCLUDES -I$ai_p"
54836      fi
54837
54838  fi
54839
54840  fi
54841
54842
54843
54844  if test "$ext_shared" = "yes"; then
54845    OPCACHE_SHARED_LIBADD="-lopagent $OPCACHE_SHARED_LIBADD"
54846    if test -n "$OPAGENT_DIR/$PHP_LIBDIR/oprofile"; then
54847
54848  if test "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" != "/usr/$PHP_LIBDIR" && test "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" != "/usr/lib"; then
54849
54850  if test -z "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" || echo "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" | grep '^/' >/dev/null ; then
54851    ai_p=$OPAGENT_DIR/$PHP_LIBDIR/oprofile
54852  else
54853
54854    ep_dir=`echo $OPAGENT_DIR/$PHP_LIBDIR/oprofile|$SED 's%/*[^/][^/]*/*$%%'`
54855
54856    ep_realdir=`(cd "$ep_dir" && pwd)`
54857    ai_p="$ep_realdir"/`basename "$OPAGENT_DIR/$PHP_LIBDIR/oprofile"`
54858  fi
54859
54860
54861      if test "$ext_shared" = "yes"; then
54862        OPCACHE_SHARED_LIBADD="-L$ai_p $OPCACHE_SHARED_LIBADD"
54863        test -n "$ld_runpath_switch" && OPCACHE_SHARED_LIBADD="$ld_runpath_switch$ai_p $OPCACHE_SHARED_LIBADD"
54864      else
54865
54866
54867
54868  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54869
54870  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
54871  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54872    eval "LIBPATH$unique=set"
54873
54874    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
54875    LDFLAGS="$LDFLAGS -L$ai_p"
54876    PHP_RPATHS="$PHP_RPATHS $ai_p"
54877
54878  fi
54879
54880
54881      fi
54882
54883  fi
54884
54885    fi
54886  else
54887
54888
54889  if test -n "$OPAGENT_DIR/$PHP_LIBDIR/oprofile"; then
54890
54891  if test "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" != "/usr/$PHP_LIBDIR" && test "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" != "/usr/lib"; then
54892
54893  if test -z "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" || echo "$OPAGENT_DIR/$PHP_LIBDIR/oprofile" | grep '^/' >/dev/null ; then
54894    ai_p=$OPAGENT_DIR/$PHP_LIBDIR/oprofile
54895  else
54896
54897    ep_dir=`echo $OPAGENT_DIR/$PHP_LIBDIR/oprofile|$SED 's%/*[^/][^/]*/*$%%'`
54898
54899    ep_realdir=`(cd "$ep_dir" && pwd)`
54900    ai_p="$ep_realdir"/`basename "$OPAGENT_DIR/$PHP_LIBDIR/oprofile"`
54901  fi
54902
54903
54904
54905
54906
54907  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
54908
54909  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
54910  if test -n "$unique" && test "`eval $cmd`" = "" ; then
54911    eval "LIBPATH$unique=set"
54912
54913    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
54914    LDFLAGS="$LDFLAGS -L$ai_p"
54915    PHP_RPATHS="$PHP_RPATHS $ai_p"
54916
54917  fi
54918
54919
54920
54921  fi
54922
54923  fi
54924
54925
54926  case opagent in
54927  c|c_r) ;;
54928  *)
54929      LIBS="-lopagent $LIBS"
54930   ;;
54931  esac
54932
54933
54934
54935
54936  fi
54937
54938
54939
54940  PHP_VAR_SUBST="$PHP_VAR_SUBST OPCACHE_SHARED_LIBADD"
54941
54942
54943
54944else $as_nop
54945
54946    LDFLAGS=$save_old_LDFLAGS
54947    ext_shared=$save_ext_shared
54948    unset ac_cv_lib_opagent_op_write_native_code
54949
54950        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
54951printf "%s\n" "not found" >&6; }
54952
54953
54954fi
54955
54956    fi
54957
54958  fi
54959
54960  ac_fn_c_check_func "$LINENO" "mprotect" "ac_cv_func_mprotect"
54961if test "x$ac_cv_func_mprotect" = xyes
54962then :
54963  printf "%s\n" "#define HAVE_MPROTECT 1" >>confdefs.h
54964
54965fi
54966
54967
54968  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysvipc shared memory support" >&5
54969printf %s "checking for sysvipc shared memory support... " >&6; }
54970  if test "$cross_compiling" = yes
54971then :
54972  have_shm_ipc=no
54973else $as_nop
54974  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54975/* end confdefs.h.  */
54976
54977#include <sys/types.h>
54978#include <sys/wait.h>
54979#include <sys/ipc.h>
54980#include <sys/shm.h>
54981#include <unistd.h>
54982#include <string.h>
54983
54984int main() {
54985  pid_t pid;
54986  int status;
54987  int ipc_id;
54988  char *shm;
54989  struct shmid_ds shmbuf;
54990
54991  ipc_id = shmget(IPC_PRIVATE, 4096, (IPC_CREAT | SHM_R | SHM_W));
54992  if (ipc_id == -1) {
54993    return 1;
54994  }
54995
54996  shm = shmat(ipc_id, NULL, 0);
54997  if (shm == (void *)-1) {
54998    shmctl(ipc_id, IPC_RMID, NULL);
54999    return 2;
55000  }
55001
55002  if (shmctl(ipc_id, IPC_STAT, &shmbuf) != 0) {
55003    shmdt(shm);
55004    shmctl(ipc_id, IPC_RMID, NULL);
55005    return 3;
55006  }
55007
55008  shmbuf.shm_perm.uid = getuid();
55009  shmbuf.shm_perm.gid = getgid();
55010  shmbuf.shm_perm.mode = 0600;
55011
55012  if (shmctl(ipc_id, IPC_SET, &shmbuf) != 0) {
55013    shmdt(shm);
55014    shmctl(ipc_id, IPC_RMID, NULL);
55015    return 4;
55016  }
55017
55018  shmctl(ipc_id, IPC_RMID, NULL);
55019
55020  strcpy(shm, "hello");
55021
55022  pid = fork();
55023  if (pid < 0) {
55024    return 5;
55025  } else if (pid == 0) {
55026    strcpy(shm, "bye");
55027    return 6;
55028  }
55029  if (wait(&status) != pid) {
55030    return 7;
55031  }
55032  if (!WIFEXITED(status) || WEXITSTATUS(status) != 6) {
55033    return 8;
55034  }
55035  if (strcmp(shm, "bye") != 0) {
55036    return 9;
55037  }
55038  return 0;
55039}
55040
55041_ACEOF
55042if ac_fn_c_try_run "$LINENO"
55043then :
55044  have_shm_ipc=yes
55045else $as_nop
55046  have_shm_ipc=no
55047fi
55048rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
55049  conftest.$ac_objext conftest.beam conftest.$ac_ext
55050fi
55051
55052  if test "$have_shm_ipc" = "yes"; then
55053
55054printf "%s\n" "#define HAVE_SHM_IPC 1" >>confdefs.h
55055
55056  fi
55057  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_shm_ipc" >&5
55058printf "%s\n" "$have_shm_ipc" >&6; }
55059
55060  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mmap() using MAP_ANON shared memory support" >&5
55061printf %s "checking for mmap() using MAP_ANON shared memory support... " >&6; }
55062  if test "$cross_compiling" = yes
55063then :
55064
55065  case $host_alias in
55066    *linux*)
55067      have_shm_mmap_anon=yes
55068      ;;
55069    *)
55070      have_shm_mmap_anon=no
55071      ;;
55072  esac
55073
55074else $as_nop
55075  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55076/* end confdefs.h.  */
55077
55078#include <sys/types.h>
55079#include <sys/wait.h>
55080#include <sys/mman.h>
55081#include <unistd.h>
55082#include <string.h>
55083
55084#ifndef MAP_ANON
55085# ifdef MAP_ANONYMOUS
55086#  define MAP_ANON MAP_ANONYMOUS
55087# endif
55088#endif
55089#ifndef MAP_FAILED
55090# define MAP_FAILED ((void*)-1)
55091#endif
55092
55093int main() {
55094  pid_t pid;
55095  int status;
55096  char *shm;
55097
55098  shm = mmap(NULL, 4096, PROT_READ | PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
55099  if (shm == MAP_FAILED) {
55100    return 1;
55101  }
55102
55103  strcpy(shm, "hello");
55104
55105  pid = fork();
55106  if (pid < 0) {
55107    return 5;
55108  } else if (pid == 0) {
55109    strcpy(shm, "bye");
55110    return 6;
55111  }
55112  if (wait(&status) != pid) {
55113    return 7;
55114  }
55115  if (!WIFEXITED(status) || WEXITSTATUS(status) != 6) {
55116    return 8;
55117  }
55118  if (strcmp(shm, "bye") != 0) {
55119    return 9;
55120  }
55121  return 0;
55122}
55123
55124_ACEOF
55125if ac_fn_c_try_run "$LINENO"
55126then :
55127  have_shm_mmap_anon=yes
55128else $as_nop
55129  have_shm_mmap_anon=no
55130fi
55131rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
55132  conftest.$ac_objext conftest.beam conftest.$ac_ext
55133fi
55134
55135  if test "$have_shm_mmap_anon" = "yes"; then
55136
55137printf "%s\n" "#define HAVE_SHM_MMAP_ANON 1" >>confdefs.h
55138
55139  fi
55140  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_shm_mmap_anon" >&5
55141printf "%s\n" "$have_shm_mmap_anon" >&6; }
55142
55143
55144
55145  unset ac_cv_lib_rt_shm_open
55146  unset ac_cv_lib_rt___shm_open
55147  unset found
55148  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shm_open in -lrt" >&5
55149printf %s "checking for shm_open in -lrt... " >&6; }
55150if test ${ac_cv_lib_rt_shm_open+y}
55151then :
55152  printf %s "(cached) " >&6
55153else $as_nop
55154  ac_check_lib_save_LIBS=$LIBS
55155LIBS="-lrt  $LIBS"
55156cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55157/* end confdefs.h.  */
55158
55159/* Override any GCC internal prototype to avoid an error.
55160   Use char because int might match the return type of a GCC
55161   builtin and then its argument prototype would still apply.  */
55162char shm_open ();
55163int
55164main (void)
55165{
55166return shm_open ();
55167  ;
55168  return 0;
55169}
55170_ACEOF
55171if ac_fn_c_try_link "$LINENO"
55172then :
55173  ac_cv_lib_rt_shm_open=yes
55174else $as_nop
55175  ac_cv_lib_rt_shm_open=no
55176fi
55177rm -f core conftest.err conftest.$ac_objext conftest.beam \
55178    conftest$ac_exeext conftest.$ac_ext
55179LIBS=$ac_check_lib_save_LIBS
55180fi
55181{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_shm_open" >&5
55182printf "%s\n" "$ac_cv_lib_rt_shm_open" >&6; }
55183if test "x$ac_cv_lib_rt_shm_open" = xyes
55184then :
55185  found=yes
55186else $as_nop
55187
55188    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __shm_open in -lrt" >&5
55189printf %s "checking for __shm_open in -lrt... " >&6; }
55190if test ${ac_cv_lib_rt___shm_open+y}
55191then :
55192  printf %s "(cached) " >&6
55193else $as_nop
55194  ac_check_lib_save_LIBS=$LIBS
55195LIBS="-lrt  $LIBS"
55196cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55197/* end confdefs.h.  */
55198
55199/* Override any GCC internal prototype to avoid an error.
55200   Use char because int might match the return type of a GCC
55201   builtin and then its argument prototype would still apply.  */
55202char __shm_open ();
55203int
55204main (void)
55205{
55206return __shm_open ();
55207  ;
55208  return 0;
55209}
55210_ACEOF
55211if ac_fn_c_try_link "$LINENO"
55212then :
55213  ac_cv_lib_rt___shm_open=yes
55214else $as_nop
55215  ac_cv_lib_rt___shm_open=no
55216fi
55217rm -f core conftest.err conftest.$ac_objext conftest.beam \
55218    conftest$ac_exeext conftest.$ac_ext
55219LIBS=$ac_check_lib_save_LIBS
55220fi
55221{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt___shm_open" >&5
55222printf "%s\n" "$ac_cv_lib_rt___shm_open" >&6; }
55223if test "x$ac_cv_lib_rt___shm_open" = xyes
55224then :
55225  found=yes
55226else $as_nop
55227  found=no
55228fi
55229
55230
55231fi
55232
55233
55234  if test "$found" = "yes"; then
55235    ac_libs=$LIBS
55236    LIBS="$LIBS -lrt"
55237    if test "$cross_compiling" = yes
55238then :
55239
55240            found=yes
55241
55242else $as_nop
55243  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55244/* end confdefs.h.  */
55245int main() { return (0); }
55246_ACEOF
55247if ac_fn_c_try_run "$LINENO"
55248then :
55249  found=yes
55250else $as_nop
55251  found=no
55252fi
55253rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
55254  conftest.$ac_objext conftest.beam conftest.$ac_ext
55255fi
55256
55257    LIBS=$ac_libs
55258  fi
55259
55260  if test "$found" = "yes"; then
55261
55262
55263  case rt in
55264  c|c_r) ;;
55265  *)
55266      LIBS="-lrt $LIBS"
55267   ;;
55268  esac
55269
55270
55271
55272printf "%s\n" "#define HAVE_SHM_OPEN 1" >>confdefs.h
55273
55274
55275printf "%s\n" "#define HAVE_LIBRT 1" >>confdefs.h
55276
55277    ac_cv_func_shm_open=yes
55278  else
55279
55280
55281  unset ac_cv_lib_root_shm_open
55282  unset ac_cv_lib_root___shm_open
55283  unset found
55284  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shm_open in -lroot" >&5
55285printf %s "checking for shm_open in -lroot... " >&6; }
55286if test ${ac_cv_lib_root_shm_open+y}
55287then :
55288  printf %s "(cached) " >&6
55289else $as_nop
55290  ac_check_lib_save_LIBS=$LIBS
55291LIBS="-lroot  $LIBS"
55292cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55293/* end confdefs.h.  */
55294
55295/* Override any GCC internal prototype to avoid an error.
55296   Use char because int might match the return type of a GCC
55297   builtin and then its argument prototype would still apply.  */
55298char shm_open ();
55299int
55300main (void)
55301{
55302return shm_open ();
55303  ;
55304  return 0;
55305}
55306_ACEOF
55307if ac_fn_c_try_link "$LINENO"
55308then :
55309  ac_cv_lib_root_shm_open=yes
55310else $as_nop
55311  ac_cv_lib_root_shm_open=no
55312fi
55313rm -f core conftest.err conftest.$ac_objext conftest.beam \
55314    conftest$ac_exeext conftest.$ac_ext
55315LIBS=$ac_check_lib_save_LIBS
55316fi
55317{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root_shm_open" >&5
55318printf "%s\n" "$ac_cv_lib_root_shm_open" >&6; }
55319if test "x$ac_cv_lib_root_shm_open" = xyes
55320then :
55321  found=yes
55322else $as_nop
55323
55324    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __shm_open in -lroot" >&5
55325printf %s "checking for __shm_open in -lroot... " >&6; }
55326if test ${ac_cv_lib_root___shm_open+y}
55327then :
55328  printf %s "(cached) " >&6
55329else $as_nop
55330  ac_check_lib_save_LIBS=$LIBS
55331LIBS="-lroot  $LIBS"
55332cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55333/* end confdefs.h.  */
55334
55335/* Override any GCC internal prototype to avoid an error.
55336   Use char because int might match the return type of a GCC
55337   builtin and then its argument prototype would still apply.  */
55338char __shm_open ();
55339int
55340main (void)
55341{
55342return __shm_open ();
55343  ;
55344  return 0;
55345}
55346_ACEOF
55347if ac_fn_c_try_link "$LINENO"
55348then :
55349  ac_cv_lib_root___shm_open=yes
55350else $as_nop
55351  ac_cv_lib_root___shm_open=no
55352fi
55353rm -f core conftest.err conftest.$ac_objext conftest.beam \
55354    conftest$ac_exeext conftest.$ac_ext
55355LIBS=$ac_check_lib_save_LIBS
55356fi
55357{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_root___shm_open" >&5
55358printf "%s\n" "$ac_cv_lib_root___shm_open" >&6; }
55359if test "x$ac_cv_lib_root___shm_open" = xyes
55360then :
55361  found=yes
55362else $as_nop
55363  found=no
55364fi
55365
55366
55367fi
55368
55369
55370  if test "$found" = "yes"; then
55371    ac_libs=$LIBS
55372    LIBS="$LIBS -lroot"
55373    if test "$cross_compiling" = yes
55374then :
55375
55376            found=yes
55377
55378else $as_nop
55379  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55380/* end confdefs.h.  */
55381int main() { return (0); }
55382_ACEOF
55383if ac_fn_c_try_run "$LINENO"
55384then :
55385  found=yes
55386else $as_nop
55387  found=no
55388fi
55389rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
55390  conftest.$ac_objext conftest.beam conftest.$ac_ext
55391fi
55392
55393    LIBS=$ac_libs
55394  fi
55395
55396  if test "$found" = "yes"; then
55397
55398
55399  case root in
55400  c|c_r) ;;
55401  *)
55402      LIBS="-lroot $LIBS"
55403   ;;
55404  esac
55405
55406
55407
55408printf "%s\n" "#define HAVE_SHM_OPEN 1" >>confdefs.h
55409
55410
55411printf "%s\n" "#define HAVE_LIBROOT 1" >>confdefs.h
55412
55413    ac_cv_func_shm_open=yes
55414  else
55415
55416  :
55417
55418  fi
55419
55420
55421  fi
55422
55423
55424  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mmap() using shm_open() shared memory support" >&5
55425printf %s "checking for mmap() using shm_open() shared memory support... " >&6; }
55426  if test "$cross_compiling" = yes
55427then :
55428  have_shm_mmap_posix=no
55429else $as_nop
55430  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55431/* end confdefs.h.  */
55432
55433#include <sys/types.h>
55434#include <sys/wait.h>
55435#include <sys/mman.h>
55436#include <sys/stat.h>
55437#include <fcntl.h>
55438#include <unistd.h>
55439#include <string.h>
55440#include <stdlib.h>
55441#include <stdio.h>
55442
55443#ifndef MAP_FAILED
55444# define MAP_FAILED ((void*)-1)
55445#endif
55446
55447int main() {
55448  pid_t pid;
55449  int status;
55450  int fd;
55451  char *shm;
55452  char tmpname[4096];
55453
55454  sprintf(tmpname,"/opcache.test.shm.%dXXXXXX", getpid());
55455  if (mktemp(tmpname) == NULL) {
55456    return 1;
55457  }
55458  fd = shm_open(tmpname, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR);
55459  if (fd == -1) {
55460    return 2;
55461  }
55462  if (ftruncate(fd, 4096) < 0) {
55463    close(fd);
55464    shm_unlink(tmpname);
55465    return 3;
55466  }
55467
55468  shm = mmap(NULL, 4096, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);
55469  if (shm == MAP_FAILED) {
55470    return 4;
55471  }
55472  shm_unlink(tmpname);
55473  close(fd);
55474
55475  strcpy(shm, "hello");
55476
55477  pid = fork();
55478  if (pid < 0) {
55479    return 5;
55480  } else if (pid == 0) {
55481    strcpy(shm, "bye");
55482    return 6;
55483  }
55484  if (wait(&status) != pid) {
55485    return 7;
55486  }
55487  if (!WIFEXITED(status) || WEXITSTATUS(status) != 6) {
55488    return 8;
55489  }
55490  if (strcmp(shm, "bye") != 0) {
55491    return 9;
55492  }
55493  return 0;
55494}
55495
55496_ACEOF
55497if ac_fn_c_try_run "$LINENO"
55498then :
55499  have_shm_mmap_posix=yes
55500else $as_nop
55501  have_shm_mmap_posix=no
55502fi
55503rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
55504  conftest.$ac_objext conftest.beam conftest.$ac_ext
55505fi
55506
55507  if test "$have_shm_mmap_posix" = "yes"; then
55508
55509printf "%s\n" "#define HAVE_SHM_MMAP_POSIX 1" >>confdefs.h
55510
55511
55512  save_old_LDFLAGS=$LDFLAGS
55513  ac_stuff=""
55514
55515  save_ext_shared=$ext_shared
55516  ext_shared=yes
55517
55518  for ac_i in $ac_stuff; do
55519    case $ac_i in
55520    -pthread)
55521      if test "$ext_shared" = "yes"; then
55522        LDFLAGS="$LDFLAGS -pthread"
55523      else
55524
55525
55526  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
55527
55528  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
55529  if test -n "$unique" && test "`eval $cmd`" = "" ; then
55530    eval "EXTRA_LDFLAGS$unique=set"
55531    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
55532  fi
55533
55534
55535
55536  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
55537
55538  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
55539  if test -n "$unique" && test "`eval $cmd`" = "" ; then
55540    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
55541    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
55542  fi
55543
55544      fi
55545    ;;
55546    -l*)
55547      ac_ii=`echo $ac_i|cut -c 3-`
55548
55549
55550  case $ac_ii in
55551  c|c_r) ;;
55552  *)
55553    if test "$ext_shared" = "yes"; then
55554        LDFLAGS="$LDFLAGS -l$ac_ii"
55555    else
55556
55557
55558  case $ac_ii in
55559  c|c_r) ;;
55560  *)
55561      LIBS="$LIBS -l$ac_ii"
55562   ;;
55563  esac
55564
55565
55566    fi
55567   ;;
55568  esac
55569
55570
55571    ;;
55572    -L*)
55573      ac_ii=`echo $ac_i|cut -c 3-`
55574
55575  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
55576
55577  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
55578    ai_p=$ac_ii
55579  else
55580
55581    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
55582
55583    ep_realdir=`(cd "$ep_dir" && pwd)`
55584    ai_p="$ep_realdir"/`basename "$ac_ii"`
55585  fi
55586
55587
55588      if test "$ext_shared" = "yes"; then
55589        LDFLAGS="-L$ai_p $LDFLAGS"
55590        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
55591      else
55592
55593
55594
55595  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
55596
55597  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
55598  if test -n "$unique" && test "`eval $cmd`" = "" ; then
55599    eval "LIBPATH$unique=set"
55600
55601    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
55602    LDFLAGS="$LDFLAGS -L$ai_p"
55603    PHP_RPATHS="$PHP_RPATHS $ai_p"
55604
55605  fi
55606
55607
55608      fi
55609
55610  fi
55611
55612    ;;
55613    esac
55614  done
55615
55616  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shm_unlink in -lrt" >&5
55617printf %s "checking for shm_unlink in -lrt... " >&6; }
55618if test ${ac_cv_lib_rt_shm_unlink+y}
55619then :
55620  printf %s "(cached) " >&6
55621else $as_nop
55622  ac_check_lib_save_LIBS=$LIBS
55623LIBS="-lrt  $LIBS"
55624cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55625/* end confdefs.h.  */
55626
55627/* Override any GCC internal prototype to avoid an error.
55628   Use char because int might match the return type of a GCC
55629   builtin and then its argument prototype would still apply.  */
55630char shm_unlink ();
55631int
55632main (void)
55633{
55634return shm_unlink ();
55635  ;
55636  return 0;
55637}
55638_ACEOF
55639if ac_fn_c_try_link "$LINENO"
55640then :
55641  ac_cv_lib_rt_shm_unlink=yes
55642else $as_nop
55643  ac_cv_lib_rt_shm_unlink=no
55644fi
55645rm -f core conftest.err conftest.$ac_objext conftest.beam \
55646    conftest$ac_exeext conftest.$ac_ext
55647LIBS=$ac_check_lib_save_LIBS
55648fi
55649{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_shm_unlink" >&5
55650printf "%s\n" "$ac_cv_lib_rt_shm_unlink" >&6; }
55651if test "x$ac_cv_lib_rt_shm_unlink" = xyes
55652then :
55653
55654    LDFLAGS=$save_old_LDFLAGS
55655    ext_shared=$save_ext_shared
55656
55657
55658  case rt in
55659  c|c_r) ;;
55660  *)
55661    if test "$ext_shared" = "yes"; then
55662        OPCACHE_SHARED_LIBADD="$OPCACHE_SHARED_LIBADD -lrt"
55663    else
55664
55665
55666  case rt in
55667  c|c_r) ;;
55668  *)
55669      LIBS="$LIBS -lrt"
55670   ;;
55671  esac
55672
55673
55674    fi
55675   ;;
55676  esac
55677
55678
55679
55680else $as_nop
55681
55682    LDFLAGS=$save_old_LDFLAGS
55683    ext_shared=$save_ext_shared
55684    unset ac_cv_lib_rt_shm_unlink
55685
55686
55687fi
55688
55689  fi
55690  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $have_shm_mmap_posix" >&5
55691printf "%s\n" "$have_shm_mmap_posix" >&6; }
55692
55693
55694  ext_builddir=ext/opcache
55695  ext_srcdir=$abs_srcdir/ext/opcache
55696  ext_dir=ext/opcache
55697
55698  ac_extra=`echo ""-Wno-implicit-fallthrough -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1""|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
55699
55700  if test "shared" != "shared" && test "shared" != "yes" && test "" != "cli"; then
55701    PHP_OPCACHE_SHARED=no
55702
55703
55704  case $ext_dir in
55705  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
55706  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
55707  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
55708  esac
55709
55710
55711
55712  b_c_pre=$php_c_pre
55713  b_cxx_pre=$php_cxx_pre
55714  b_c_meta=$php_c_meta
55715  b_cxx_meta=$php_cxx_meta
55716  b_c_post=$php_c_post
55717  b_cxx_post=$php_cxx_post
55718  b_lo=$php_lo
55719
55720
55721  old_IFS=$IFS
55722  for ac_src in ZendAccelerator.c \
55723	zend_accelerator_blacklist.c \
55724	zend_accelerator_debug.c \
55725	zend_accelerator_hash.c \
55726	zend_accelerator_module.c \
55727	zend_persist.c \
55728	zend_persist_calc.c \
55729	zend_file_cache.c \
55730	zend_shared_alloc.c \
55731	zend_accelerator_util_funcs.c \
55732	shared_alloc_shm.c \
55733	shared_alloc_mmap.c \
55734	shared_alloc_posix.c \
55735	$ZEND_JIT_SRC; do
55736
55737      IFS=.
55738      set $ac_src
55739      ac_obj=$1
55740      IFS=$old_IFS
55741
55742      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
55743
55744      case $ac_src in
55745        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55746        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55747        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55748        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
55749      esac
55750
55751      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
55752
55753    cat >>Makefile.objects<<EOF
55754-include $ac_bdir$ac_obj.dep
55755$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
55756	$ac_comp
55757EOF
55758  done
55759
55760
55761    EXT_STATIC="$EXT_STATIC opcache;$ext_dir"
55762    if test "shared" != "nocli"; then
55763      EXT_CLI_STATIC="$EXT_CLI_STATIC opcache;$ext_dir"
55764    fi
55765  else
55766    if test "shared" = "shared" || test "shared" = "yes"; then
55767      PHP_OPCACHE_SHARED=yes
55768
55769  case $ext_dir in
55770  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
55771  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
55772  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
55773  esac
55774
55775
55776
55777  b_c_pre=$shared_c_pre
55778  b_cxx_pre=$shared_cxx_pre
55779  b_c_meta=$shared_c_meta
55780  b_cxx_meta=$shared_cxx_meta
55781  b_c_post=$shared_c_post
55782  b_cxx_post=$shared_cxx_post
55783  b_lo=$shared_lo
55784
55785
55786  old_IFS=$IFS
55787  for ac_src in ZendAccelerator.c \
55788	zend_accelerator_blacklist.c \
55789	zend_accelerator_debug.c \
55790	zend_accelerator_hash.c \
55791	zend_accelerator_module.c \
55792	zend_persist.c \
55793	zend_persist_calc.c \
55794	zend_file_cache.c \
55795	zend_shared_alloc.c \
55796	zend_accelerator_util_funcs.c \
55797	shared_alloc_shm.c \
55798	shared_alloc_mmap.c \
55799	shared_alloc_posix.c \
55800	$ZEND_JIT_SRC; do
55801
55802      IFS=.
55803      set $ac_src
55804      ac_obj=$1
55805      IFS=$old_IFS
55806
55807      shared_objects_opcache="$shared_objects_opcache $ac_bdir$ac_obj.lo"
55808
55809      case $ac_src in
55810        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55811        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55812        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55813        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
55814      esac
55815
55816      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
55817
55818    cat >>Makefile.objects<<EOF
55819-include $ac_bdir$ac_obj.dep
55820$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
55821	$ac_comp
55822EOF
55823  done
55824
55825
55826  install_modules="install-modules"
55827  suffix=la
55828
55829  case $host_alias in
55830    *aix*)
55831      additional_flags="-Wl,-G"
55832      ;;
55833  esac
55834
55835  if test "xyes" = "xyes"; then
55836    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/opcache.$suffix"
55837  else
55838    PHP_MODULES="$PHP_MODULES \$(phplibdir)/opcache.$suffix"
55839  fi
55840
55841  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_opcache"
55842
55843  cat >>Makefile.objects<<EOF
55844\$(phplibdir)/opcache.$suffix: $ext_builddir/opcache.$suffix
55845	\$(LIBTOOL) --mode=install cp $ext_builddir/opcache.$suffix \$(phplibdir)
55846
55847$ext_builddir/opcache.$suffix: \$(shared_objects_opcache) \$(OPCACHE_SHARED_DEPENDENCIES)
55848	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_opcache) \$(OPCACHE_SHARED_LIBADD)
55849
55850EOF
55851
55852
55853printf "%s\n" "#define COMPILE_DL_OPCACHE 1" >>confdefs.h
55854
55855    fi
55856  fi
55857
55858  if test "shared" != "shared" && test "shared" != "yes" && test "" = "cli"; then
55859    PHP_OPCACHE_SHARED=no
55860    case "$PHP_SAPI" in
55861      cgi|embed|phpdbg)
55862
55863
55864  case $ext_dir in
55865  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
55866  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
55867  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
55868  esac
55869
55870
55871
55872  b_c_pre=$php_c_pre
55873  b_cxx_pre=$php_cxx_pre
55874  b_c_meta=$php_c_meta
55875  b_cxx_meta=$php_cxx_meta
55876  b_c_post=$php_c_post
55877  b_cxx_post=$php_cxx_post
55878  b_lo=$php_lo
55879
55880
55881  old_IFS=$IFS
55882  for ac_src in ZendAccelerator.c \
55883	zend_accelerator_blacklist.c \
55884	zend_accelerator_debug.c \
55885	zend_accelerator_hash.c \
55886	zend_accelerator_module.c \
55887	zend_persist.c \
55888	zend_persist_calc.c \
55889	zend_file_cache.c \
55890	zend_shared_alloc.c \
55891	zend_accelerator_util_funcs.c \
55892	shared_alloc_shm.c \
55893	shared_alloc_mmap.c \
55894	shared_alloc_posix.c \
55895	$ZEND_JIT_SRC; do
55896
55897      IFS=.
55898      set $ac_src
55899      ac_obj=$1
55900      IFS=$old_IFS
55901
55902      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
55903
55904      case $ac_src in
55905        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55906        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55907        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55908        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
55909      esac
55910
55911      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
55912
55913    cat >>Makefile.objects<<EOF
55914-include $ac_bdir$ac_obj.dep
55915$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
55916	$ac_comp
55917EOF
55918  done
55919
55920
55921        EXT_STATIC="$EXT_STATIC opcache;$ext_dir"
55922        ;;
55923      *)
55924
55925
55926  case $ext_dir in
55927  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
55928  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
55929  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
55930  esac
55931
55932
55933
55934  b_c_pre=$php_c_pre
55935  b_cxx_pre=$php_cxx_pre
55936  b_c_meta=$php_c_meta
55937  b_cxx_meta=$php_cxx_meta
55938  b_c_post=$php_c_post
55939  b_cxx_post=$php_cxx_post
55940  b_lo=$php_lo
55941
55942
55943  old_IFS=$IFS
55944  for ac_src in ZendAccelerator.c \
55945	zend_accelerator_blacklist.c \
55946	zend_accelerator_debug.c \
55947	zend_accelerator_hash.c \
55948	zend_accelerator_module.c \
55949	zend_persist.c \
55950	zend_persist_calc.c \
55951	zend_file_cache.c \
55952	zend_shared_alloc.c \
55953	zend_accelerator_util_funcs.c \
55954	shared_alloc_shm.c \
55955	shared_alloc_mmap.c \
55956	shared_alloc_posix.c \
55957	$ZEND_JIT_SRC; do
55958
55959      IFS=.
55960      set $ac_src
55961      ac_obj=$1
55962      IFS=$old_IFS
55963
55964      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
55965
55966      case $ac_src in
55967        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55968        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55969        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
55970        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
55971      esac
55972
55973      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
55974
55975    cat >>Makefile.objects<<EOF
55976-include $ac_bdir$ac_obj.dep
55977$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
55978	$ac_comp
55979EOF
55980  done
55981
55982
55983        ;;
55984    esac
55985    EXT_CLI_STATIC="$EXT_CLI_STATIC opcache;$ext_dir"
55986  fi
55987
55988
55989    BUILD_DIR="$BUILD_DIR $ext_builddir"
55990
55991
55992
55993  if test "$ext_builddir" = "."; then
55994    PHP_PECL_EXTENSION=opcache
55995
55996  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
55997
55998  fi
55999
56000
56001
56002  am_i_shared=$PHP_OPCACHE_SHARED
56003  is_it_shared=$PHP_PCRE_SHARED
56004  is_it_enabled=$PHP_PCRE
56005  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
56006    as_fn_error $? "
56007You've configured extension opcache to build statically, but it
56008depends on extension pcre, which you've configured to build shared.
56009You either need to build opcache shared or build pcre statically for the
56010build to be successful.
56011" "$LINENO" 5
56012  fi
56013  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
56014    as_fn_error $? "
56015You've configured extension opcache, which depends on extension pcre,
56016but you've either not enabled pcre, or have disabled it.
56017" "$LINENO" 5
56018  fi
56019
56020
56021  if test "$have_shm_ipc" != "yes" && test "$have_shm_mmap_posix" != "yes" && test "$have_shm_mmap_anon" != "yes"; then
56022    as_fn_error $? "No supported shared memory caching support was found when configuring opcache. Check config.log for any errors or missing dependencies." "$LINENO" 5
56023  fi
56024
56025  if test "$PHP_OPCACHE_JIT" = "yes"; then
56026
56027
56028    $php_shtool mkdir -p $ext_builddir/jit
56029
56030
56031
56032  src=$ext_srcdir/jit/Makefile.frag
56033  ac_srcdir=$ext_srcdir
56034  ac_builddir=$ext_builddir
56035  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
56036
56037  fi
56038
56039  PHP_VAR_SUBST="$PHP_VAR_SUBST OPCACHE_SHARED_LIBADD"
56040
56041fi
56042
56043
56044
56045
56046
56047php_enable_pcntl=no
56048
56049{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable pcntl support" >&5
56050printf %s "checking whether to enable pcntl support... " >&6; }
56051# Check whether --enable-pcntl was given.
56052if test ${enable_pcntl+y}
56053then :
56054  enableval=$enable_pcntl; PHP_PCNTL=$enableval
56055else $as_nop
56056
56057  PHP_PCNTL=no
56058  test "$PHP_ENABLE_ALL" && PHP_PCNTL=$PHP_ENABLE_ALL
56059
56060fi
56061
56062
56063
56064ext_output="yes, shared"
56065ext_shared=yes
56066case $PHP_PCNTL in
56067shared,*)
56068  PHP_PCNTL=`echo "$PHP_PCNTL"|$SED 's/^shared,//'`
56069  ;;
56070shared)
56071  PHP_PCNTL=yes
56072  ;;
56073no)
56074  ext_output=no
56075  ext_shared=no
56076  ;;
56077*)
56078  ext_output=yes
56079  ext_shared=no
56080  ;;
56081esac
56082
56083
56084
56085{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
56086printf "%s\n" "$ext_output" >&6; }
56087
56088
56089
56090
56091if test "$PHP_PCNTL" != "no"; then
56092
56093  for ac_func in fork
56094do :
56095  ac_fn_c_check_func "$LINENO" "fork" "ac_cv_func_fork"
56096if test "x$ac_cv_func_fork" = xyes
56097then :
56098  printf "%s\n" "#define HAVE_FORK 1" >>confdefs.h
56099
56100else $as_nop
56101  as_fn_error $? "pcntl: fork() not supported by this platform" "$LINENO" 5
56102fi
56103
56104done
56105
56106  for ac_func in waitpid
56107do :
56108  ac_fn_c_check_func "$LINENO" "waitpid" "ac_cv_func_waitpid"
56109if test "x$ac_cv_func_waitpid" = xyes
56110then :
56111  printf "%s\n" "#define HAVE_WAITPID 1" >>confdefs.h
56112
56113else $as_nop
56114  as_fn_error $? "pcntl: waitpid() not supported by this platform" "$LINENO" 5
56115fi
56116
56117done
56118
56119  for ac_func in sigaction
56120do :
56121  ac_fn_c_check_func "$LINENO" "sigaction" "ac_cv_func_sigaction"
56122if test "x$ac_cv_func_sigaction" = xyes
56123then :
56124  printf "%s\n" "#define HAVE_SIGACTION 1" >>confdefs.h
56125
56126else $as_nop
56127  as_fn_error $? "pcntl: sigaction() not supported by this platform" "$LINENO" 5
56128fi
56129
56130done
56131  ac_fn_c_check_func "$LINENO" "getpriority" "ac_cv_func_getpriority"
56132if test "x$ac_cv_func_getpriority" = xyes
56133then :
56134  printf "%s\n" "#define HAVE_GETPRIORITY 1" >>confdefs.h
56135
56136fi
56137ac_fn_c_check_func "$LINENO" "setpriority" "ac_cv_func_setpriority"
56138if test "x$ac_cv_func_setpriority" = xyes
56139then :
56140  printf "%s\n" "#define HAVE_SETPRIORITY 1" >>confdefs.h
56141
56142fi
56143ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3"
56144if test "x$ac_cv_func_wait3" = xyes
56145then :
56146  printf "%s\n" "#define HAVE_WAIT3 1" >>confdefs.h
56147
56148fi
56149ac_fn_c_check_func "$LINENO" "wait4" "ac_cv_func_wait4"
56150if test "x$ac_cv_func_wait4" = xyes
56151then :
56152  printf "%s\n" "#define HAVE_WAIT4 1" >>confdefs.h
56153
56154fi
56155ac_fn_c_check_func "$LINENO" "sigwaitinfo" "ac_cv_func_sigwaitinfo"
56156if test "x$ac_cv_func_sigwaitinfo" = xyes
56157then :
56158  printf "%s\n" "#define HAVE_SIGWAITINFO 1" >>confdefs.h
56159
56160fi
56161ac_fn_c_check_func "$LINENO" "sigtimedwait" "ac_cv_func_sigtimedwait"
56162if test "x$ac_cv_func_sigtimedwait" = xyes
56163then :
56164  printf "%s\n" "#define HAVE_SIGTIMEDWAIT 1" >>confdefs.h
56165
56166fi
56167ac_fn_c_check_func "$LINENO" "unshare" "ac_cv_func_unshare"
56168if test "x$ac_cv_func_unshare" = xyes
56169then :
56170  printf "%s\n" "#define HAVE_UNSHARE 1" >>confdefs.h
56171
56172fi
56173ac_fn_c_check_func "$LINENO" "rfork" "ac_cv_func_rfork"
56174if test "x$ac_cv_func_rfork" = xyes
56175then :
56176  printf "%s\n" "#define HAVE_RFORK 1" >>confdefs.h
56177
56178fi
56179
56180
56181  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for siginfo_t" >&5
56182printf %s "checking for siginfo_t... " >&6; }
56183  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
56184/* end confdefs.h.  */
56185
56186    #include <signal.h>
56187    #ifdef HAVE_SIGINFO_H
56188      #include <siginfo.h>
56189    #endif
56190
56191int
56192main (void)
56193{
56194
56195    siginfo_t info;
56196
56197  ;
56198  return 0;
56199}
56200_ACEOF
56201if ac_fn_c_try_compile "$LINENO"
56202then :
56203
56204    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56205printf "%s\n" "yes" >&6; }
56206    PCNTL_CFLAGS="-DHAVE_STRUCT_SIGINFO_T"
56207
56208else $as_nop
56209
56210    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
56211printf "%s\n" "no" >&6; }
56212
56213fi
56214rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
56215
56216
56217  ext_builddir=ext/pcntl
56218  ext_srcdir=$abs_srcdir/ext/pcntl
56219  ext_dir=ext/pcntl
56220
56221  ac_extra=`echo "$PCNTL_CFLAGS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
56222
56223  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "cli" != "cli"; then
56224    PHP_PCNTL_SHARED=no
56225
56226
56227  case $ext_dir in
56228  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56229  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56230  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56231  esac
56232
56233
56234
56235  b_c_pre=$php_c_pre
56236  b_cxx_pre=$php_cxx_pre
56237  b_c_meta=$php_c_meta
56238  b_cxx_meta=$php_cxx_meta
56239  b_c_post=$php_c_post
56240  b_cxx_post=$php_cxx_post
56241  b_lo=$php_lo
56242
56243
56244  old_IFS=$IFS
56245  for ac_src in pcntl.c php_signal.c; do
56246
56247      IFS=.
56248      set $ac_src
56249      ac_obj=$1
56250      IFS=$old_IFS
56251
56252      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56253
56254      case $ac_src in
56255        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56256        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56257        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56258        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56259      esac
56260
56261      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56262
56263    cat >>Makefile.objects<<EOF
56264-include $ac_bdir$ac_obj.dep
56265$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56266	$ac_comp
56267EOF
56268  done
56269
56270
56271    EXT_STATIC="$EXT_STATIC pcntl;$ext_dir"
56272    if test "$ext_shared" != "nocli"; then
56273      EXT_CLI_STATIC="$EXT_CLI_STATIC pcntl;$ext_dir"
56274    fi
56275  else
56276    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
56277      PHP_PCNTL_SHARED=yes
56278
56279  case $ext_dir in
56280  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56281  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56282  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56283  esac
56284
56285
56286
56287  b_c_pre=$shared_c_pre
56288  b_cxx_pre=$shared_cxx_pre
56289  b_c_meta=$shared_c_meta
56290  b_cxx_meta=$shared_cxx_meta
56291  b_c_post=$shared_c_post
56292  b_cxx_post=$shared_cxx_post
56293  b_lo=$shared_lo
56294
56295
56296  old_IFS=$IFS
56297  for ac_src in pcntl.c php_signal.c; do
56298
56299      IFS=.
56300      set $ac_src
56301      ac_obj=$1
56302      IFS=$old_IFS
56303
56304      shared_objects_pcntl="$shared_objects_pcntl $ac_bdir$ac_obj.lo"
56305
56306      case $ac_src in
56307        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56308        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56309        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56310        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56311      esac
56312
56313      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56314
56315    cat >>Makefile.objects<<EOF
56316-include $ac_bdir$ac_obj.dep
56317$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56318	$ac_comp
56319EOF
56320  done
56321
56322
56323  install_modules="install-modules"
56324  suffix=la
56325
56326  case $host_alias in
56327    *aix*)
56328      additional_flags="-Wl,-G"
56329      ;;
56330  esac
56331
56332  if test "x" = "xyes"; then
56333    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pcntl.$suffix"
56334  else
56335    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pcntl.$suffix"
56336  fi
56337
56338  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pcntl"
56339
56340  cat >>Makefile.objects<<EOF
56341\$(phplibdir)/pcntl.$suffix: $ext_builddir/pcntl.$suffix
56342	\$(LIBTOOL) --mode=install cp $ext_builddir/pcntl.$suffix \$(phplibdir)
56343
56344$ext_builddir/pcntl.$suffix: \$(shared_objects_pcntl) \$(PCNTL_SHARED_DEPENDENCIES)
56345	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pcntl) \$(PCNTL_SHARED_LIBADD)
56346
56347EOF
56348
56349
56350printf "%s\n" "#define COMPILE_DL_PCNTL 1" >>confdefs.h
56351
56352    fi
56353  fi
56354
56355  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "cli" = "cli"; then
56356    PHP_PCNTL_SHARED=no
56357    case "$PHP_SAPI" in
56358      cgi|embed|phpdbg)
56359
56360
56361  case $ext_dir in
56362  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56363  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56364  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56365  esac
56366
56367
56368
56369  b_c_pre=$php_c_pre
56370  b_cxx_pre=$php_cxx_pre
56371  b_c_meta=$php_c_meta
56372  b_cxx_meta=$php_cxx_meta
56373  b_c_post=$php_c_post
56374  b_cxx_post=$php_cxx_post
56375  b_lo=$php_lo
56376
56377
56378  old_IFS=$IFS
56379  for ac_src in pcntl.c php_signal.c; do
56380
56381      IFS=.
56382      set $ac_src
56383      ac_obj=$1
56384      IFS=$old_IFS
56385
56386      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56387
56388      case $ac_src in
56389        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56390        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56391        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56392        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56393      esac
56394
56395      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56396
56397    cat >>Makefile.objects<<EOF
56398-include $ac_bdir$ac_obj.dep
56399$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56400	$ac_comp
56401EOF
56402  done
56403
56404
56405        EXT_STATIC="$EXT_STATIC pcntl;$ext_dir"
56406        ;;
56407      *)
56408
56409
56410  case $ext_dir in
56411  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56412  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56413  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56414  esac
56415
56416
56417
56418  b_c_pre=$php_c_pre
56419  b_cxx_pre=$php_cxx_pre
56420  b_c_meta=$php_c_meta
56421  b_cxx_meta=$php_cxx_meta
56422  b_c_post=$php_c_post
56423  b_cxx_post=$php_cxx_post
56424  b_lo=$php_lo
56425
56426
56427  old_IFS=$IFS
56428  for ac_src in pcntl.c php_signal.c; do
56429
56430      IFS=.
56431      set $ac_src
56432      ac_obj=$1
56433      IFS=$old_IFS
56434
56435      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56436
56437      case $ac_src in
56438        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56439        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56440        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56441        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56442      esac
56443
56444      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56445
56446    cat >>Makefile.objects<<EOF
56447-include $ac_bdir$ac_obj.dep
56448$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56449	$ac_comp
56450EOF
56451  done
56452
56453
56454        ;;
56455    esac
56456    EXT_CLI_STATIC="$EXT_CLI_STATIC pcntl;$ext_dir"
56457  fi
56458
56459
56460    BUILD_DIR="$BUILD_DIR $ext_builddir"
56461
56462
56463
56464  if test "$ext_builddir" = "."; then
56465    PHP_PECL_EXTENSION=pcntl
56466
56467  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
56468
56469  fi
56470
56471fi
56472
56473
56474
56475
56476
56477php_enable_pdo=yes
56478
56479{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable PDO support" >&5
56480printf %s "checking whether to enable PDO support... " >&6; }
56481# Check whether --enable-pdo was given.
56482if test ${enable_pdo+y}
56483then :
56484  enableval=$enable_pdo; PHP_PDO=$enableval
56485else $as_nop
56486
56487  PHP_PDO=yes
56488  test "$PHP_ENABLE_ALL" && PHP_PDO=$PHP_ENABLE_ALL
56489
56490fi
56491
56492
56493
56494ext_output="yes, shared"
56495ext_shared=yes
56496case $PHP_PDO in
56497shared,*)
56498  PHP_PDO=`echo "$PHP_PDO"|$SED 's/^shared,//'`
56499  ;;
56500shared)
56501  PHP_PDO=yes
56502  ;;
56503no)
56504  ext_output=no
56505  ext_shared=no
56506  ;;
56507*)
56508  ext_output=yes
56509  ext_shared=no
56510  ;;
56511esac
56512
56513
56514
56515{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
56516printf "%s\n" "$ext_output" >&6; }
56517
56518
56519
56520
56521if test "$PHP_PDO" != "no"; then
56522
56523    PHP_PDO=yes
56524
56525
56526  ext_builddir=ext/pdo
56527  ext_srcdir=$abs_srcdir/ext/pdo
56528  ext_dir=ext/pdo
56529
56530  ac_extra=
56531
56532  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
56533    PHP_PDO_SHARED=no
56534
56535
56536  case $ext_dir in
56537  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56538  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56539  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56540  esac
56541
56542
56543
56544  b_c_pre=$php_c_pre
56545  b_cxx_pre=$php_cxx_pre
56546  b_c_meta=$php_c_meta
56547  b_cxx_meta=$php_cxx_meta
56548  b_c_post=$php_c_post
56549  b_cxx_post=$php_cxx_post
56550  b_lo=$php_lo
56551
56552
56553  old_IFS=$IFS
56554  for ac_src in pdo.c pdo_dbh.c pdo_stmt.c pdo_sql_parser.c pdo_sqlstate.c; do
56555
56556      IFS=.
56557      set $ac_src
56558      ac_obj=$1
56559      IFS=$old_IFS
56560
56561      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56562
56563      case $ac_src in
56564        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56565        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56566        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56567        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56568      esac
56569
56570      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56571
56572    cat >>Makefile.objects<<EOF
56573-include $ac_bdir$ac_obj.dep
56574$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56575	$ac_comp
56576EOF
56577  done
56578
56579
56580    EXT_STATIC="$EXT_STATIC pdo;$ext_dir"
56581    if test "$ext_shared" != "nocli"; then
56582      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo;$ext_dir"
56583    fi
56584  else
56585    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
56586      PHP_PDO_SHARED=yes
56587
56588  case $ext_dir in
56589  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56590  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56591  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56592  esac
56593
56594
56595
56596  b_c_pre=$shared_c_pre
56597  b_cxx_pre=$shared_cxx_pre
56598  b_c_meta=$shared_c_meta
56599  b_cxx_meta=$shared_cxx_meta
56600  b_c_post=$shared_c_post
56601  b_cxx_post=$shared_cxx_post
56602  b_lo=$shared_lo
56603
56604
56605  old_IFS=$IFS
56606  for ac_src in pdo.c pdo_dbh.c pdo_stmt.c pdo_sql_parser.c pdo_sqlstate.c; do
56607
56608      IFS=.
56609      set $ac_src
56610      ac_obj=$1
56611      IFS=$old_IFS
56612
56613      shared_objects_pdo="$shared_objects_pdo $ac_bdir$ac_obj.lo"
56614
56615      case $ac_src in
56616        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56617        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56618        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56619        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56620      esac
56621
56622      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56623
56624    cat >>Makefile.objects<<EOF
56625-include $ac_bdir$ac_obj.dep
56626$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56627	$ac_comp
56628EOF
56629  done
56630
56631
56632  install_modules="install-modules"
56633  suffix=la
56634
56635  case $host_alias in
56636    *aix*)
56637      additional_flags="-Wl,-G"
56638      ;;
56639  esac
56640
56641  if test "x" = "xyes"; then
56642    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo.$suffix"
56643  else
56644    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo.$suffix"
56645  fi
56646
56647  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo"
56648
56649  cat >>Makefile.objects<<EOF
56650\$(phplibdir)/pdo.$suffix: $ext_builddir/pdo.$suffix
56651	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo.$suffix \$(phplibdir)
56652
56653$ext_builddir/pdo.$suffix: \$(shared_objects_pdo) \$(PDO_SHARED_DEPENDENCIES)
56654	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo) \$(PDO_SHARED_LIBADD)
56655
56656EOF
56657
56658
56659printf "%s\n" "#define COMPILE_DL_PDO 1" >>confdefs.h
56660
56661    fi
56662  fi
56663
56664  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
56665    PHP_PDO_SHARED=no
56666    case "$PHP_SAPI" in
56667      cgi|embed|phpdbg)
56668
56669
56670  case $ext_dir in
56671  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56672  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56673  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56674  esac
56675
56676
56677
56678  b_c_pre=$php_c_pre
56679  b_cxx_pre=$php_cxx_pre
56680  b_c_meta=$php_c_meta
56681  b_cxx_meta=$php_cxx_meta
56682  b_c_post=$php_c_post
56683  b_cxx_post=$php_cxx_post
56684  b_lo=$php_lo
56685
56686
56687  old_IFS=$IFS
56688  for ac_src in pdo.c pdo_dbh.c pdo_stmt.c pdo_sql_parser.c pdo_sqlstate.c; do
56689
56690      IFS=.
56691      set $ac_src
56692      ac_obj=$1
56693      IFS=$old_IFS
56694
56695      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56696
56697      case $ac_src in
56698        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56699        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56700        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56701        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56702      esac
56703
56704      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56705
56706    cat >>Makefile.objects<<EOF
56707-include $ac_bdir$ac_obj.dep
56708$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56709	$ac_comp
56710EOF
56711  done
56712
56713
56714        EXT_STATIC="$EXT_STATIC pdo;$ext_dir"
56715        ;;
56716      *)
56717
56718
56719  case $ext_dir in
56720  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
56721  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
56722  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
56723  esac
56724
56725
56726
56727  b_c_pre=$php_c_pre
56728  b_cxx_pre=$php_cxx_pre
56729  b_c_meta=$php_c_meta
56730  b_cxx_meta=$php_cxx_meta
56731  b_c_post=$php_c_post
56732  b_cxx_post=$php_cxx_post
56733  b_lo=$php_lo
56734
56735
56736  old_IFS=$IFS
56737  for ac_src in pdo.c pdo_dbh.c pdo_stmt.c pdo_sql_parser.c pdo_sqlstate.c; do
56738
56739      IFS=.
56740      set $ac_src
56741      ac_obj=$1
56742      IFS=$old_IFS
56743
56744      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
56745
56746      case $ac_src in
56747        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56748        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56749        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
56750        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
56751      esac
56752
56753      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
56754
56755    cat >>Makefile.objects<<EOF
56756-include $ac_bdir$ac_obj.dep
56757$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
56758	$ac_comp
56759EOF
56760  done
56761
56762
56763        ;;
56764    esac
56765    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo;$ext_dir"
56766  fi
56767
56768
56769    BUILD_DIR="$BUILD_DIR $ext_builddir"
56770
56771
56772
56773  if test "$ext_builddir" = "."; then
56774    PHP_PECL_EXTENSION=pdo
56775
56776  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
56777
56778  fi
56779
56780
56781  am_i_shared=$PHP_PDO_SHARED
56782  is_it_shared=$PHP_SPL_SHARED
56783  is_it_enabled=$PHP_SPL
56784  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
56785    as_fn_error $? "
56786You've configured extension pdo to build statically, but it
56787depends on extension spl, which you've configured to build shared.
56788You either need to build pdo shared or build spl statically for the
56789build to be successful.
56790" "$LINENO" 5
56791  fi
56792  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
56793    as_fn_error $? "
56794You've configured extension pdo, which depends on extension spl,
56795but you've either not enabled spl, or have disabled it.
56796" "$LINENO" 5
56797  fi
56798
56799
56800
56801    header_path=ext/pdo
56802    for header_file in php_pdo.h php_pdo_driver.h php_pdo_error.h; do
56803      hp_hf="$header_path/$header_file"
56804
56805
56806  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
56807
56808  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
56809  if test -n "$unique" && test "`eval $cmd`" = "" ; then
56810    eval "INSTALLHEADERS$unique=set"
56811
56812        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
56813
56814  fi
56815
56816    done
56817
56818
56819
56820
56821  src=$ext_srcdir/Makefile.frag
56822  ac_srcdir=$ext_srcdir
56823  ac_builddir=$ext_builddir
56824  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
56825
56826fi
56827
56828
56829
56830
56831
56832php_with_pdo_dblib=no
56833
56834{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO_DBLIB support via FreeTDS" >&5
56835printf %s "checking for PDO_DBLIB support via FreeTDS... " >&6; }
56836
56837# Check whether --with-pdo-dblib was given.
56838if test ${with_pdo_dblib+y}
56839then :
56840  withval=$with_pdo_dblib; PHP_PDO_DBLIB=$withval
56841else $as_nop
56842
56843  PHP_PDO_DBLIB=no
56844  test "$PHP_ENABLE_ALL" && PHP_PDO_DBLIB=$PHP_ENABLE_ALL
56845
56846fi
56847
56848
56849
56850ext_output="yes, shared"
56851ext_shared=yes
56852case $PHP_PDO_DBLIB in
56853shared,*)
56854  PHP_PDO_DBLIB=`echo "$PHP_PDO_DBLIB"|$SED 's/^shared,//'`
56855  ;;
56856shared)
56857  PHP_PDO_DBLIB=yes
56858  ;;
56859no)
56860  ext_output=no
56861  ext_shared=no
56862  ;;
56863*)
56864  ext_output=yes
56865  ext_shared=no
56866  ;;
56867esac
56868
56869
56870
56871{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
56872printf "%s\n" "$ext_output" >&6; }
56873
56874
56875
56876
56877if test "$PHP_PDO_DBLIB" != "no"; then
56878
56879  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
56880    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
56881  fi
56882
56883  if test "$PHP_PDO_DBLIB" = "yes"; then
56884
56885  save_old_LDFLAGS=$LDFLAGS
56886  ac_stuff=""
56887
56888  save_ext_shared=$ext_shared
56889  ext_shared=yes
56890
56891  for ac_i in $ac_stuff; do
56892    case $ac_i in
56893    -pthread)
56894      if test "$ext_shared" = "yes"; then
56895        LDFLAGS="$LDFLAGS -pthread"
56896      else
56897
56898
56899  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
56900
56901  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
56902  if test -n "$unique" && test "`eval $cmd`" = "" ; then
56903    eval "EXTRA_LDFLAGS$unique=set"
56904    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
56905  fi
56906
56907
56908
56909  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
56910
56911  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
56912  if test -n "$unique" && test "`eval $cmd`" = "" ; then
56913    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
56914    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
56915  fi
56916
56917      fi
56918    ;;
56919    -l*)
56920      ac_ii=`echo $ac_i|cut -c 3-`
56921
56922
56923  case $ac_ii in
56924  c|c_r) ;;
56925  *)
56926    if test "$ext_shared" = "yes"; then
56927        LDFLAGS="$LDFLAGS -l$ac_ii"
56928    else
56929
56930
56931  case $ac_ii in
56932  c|c_r) ;;
56933  *)
56934      LIBS="$LIBS -l$ac_ii"
56935   ;;
56936  esac
56937
56938
56939    fi
56940   ;;
56941  esac
56942
56943
56944    ;;
56945    -L*)
56946      ac_ii=`echo $ac_i|cut -c 3-`
56947
56948  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
56949
56950  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
56951    ai_p=$ac_ii
56952  else
56953
56954    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
56955
56956    ep_realdir=`(cd "$ep_dir" && pwd)`
56957    ai_p="$ep_realdir"/`basename "$ac_ii"`
56958  fi
56959
56960
56961      if test "$ext_shared" = "yes"; then
56962        LDFLAGS="-L$ai_p $LDFLAGS"
56963        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
56964      else
56965
56966
56967
56968  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
56969
56970  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
56971  if test -n "$unique" && test "`eval $cmd`" = "" ; then
56972    eval "LIBPATH$unique=set"
56973
56974    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
56975    LDFLAGS="$LDFLAGS -L$ai_p"
56976    PHP_RPATHS="$PHP_RPATHS $ai_p"
56977
56978  fi
56979
56980
56981      fi
56982
56983  fi
56984
56985    ;;
56986    esac
56987  done
56988
56989  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dbsqlexec in -lsybdb" >&5
56990printf %s "checking for dbsqlexec in -lsybdb... " >&6; }
56991if test ${ac_cv_lib_sybdb_dbsqlexec+y}
56992then :
56993  printf %s "(cached) " >&6
56994else $as_nop
56995  ac_check_lib_save_LIBS=$LIBS
56996LIBS="-lsybdb  $LIBS"
56997cat confdefs.h - <<_ACEOF >conftest.$ac_ext
56998/* end confdefs.h.  */
56999
57000/* Override any GCC internal prototype to avoid an error.
57001   Use char because int might match the return type of a GCC
57002   builtin and then its argument prototype would still apply.  */
57003char dbsqlexec ();
57004int
57005main (void)
57006{
57007return dbsqlexec ();
57008  ;
57009  return 0;
57010}
57011_ACEOF
57012if ac_fn_c_try_link "$LINENO"
57013then :
57014  ac_cv_lib_sybdb_dbsqlexec=yes
57015else $as_nop
57016  ac_cv_lib_sybdb_dbsqlexec=no
57017fi
57018rm -f core conftest.err conftest.$ac_objext conftest.beam \
57019    conftest$ac_exeext conftest.$ac_ext
57020LIBS=$ac_check_lib_save_LIBS
57021fi
57022{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sybdb_dbsqlexec" >&5
57023printf "%s\n" "$ac_cv_lib_sybdb_dbsqlexec" >&6; }
57024if test "x$ac_cv_lib_sybdb_dbsqlexec" = xyes
57025then :
57026
57027    LDFLAGS=$save_old_LDFLAGS
57028    ext_shared=$save_ext_shared
57029
57030
57031else $as_nop
57032
57033    LDFLAGS=$save_old_LDFLAGS
57034    ext_shared=$save_ext_shared
57035    unset ac_cv_lib_sybdb_dbsqlexec
57036
57037      as_fn_error $? "Cannot find FreeTDS in known installation directories" "$LINENO" 5
57038
57039
57040fi
57041
57042
57043
57044  case sybdb in
57045  c|c_r) ;;
57046  *)
57047    if test "$ext_shared" = "yes"; then
57048        PDO_DBLIB_SHARED_LIBADD="-lsybdb $PDO_DBLIB_SHARED_LIBADD"
57049    else
57050
57051
57052  case sybdb in
57053  c|c_r) ;;
57054  *)
57055      LIBS="-lsybdb $LIBS"
57056   ;;
57057  esac
57058
57059
57060    fi
57061   ;;
57062  esac
57063
57064
57065  elif test "$PHP_PDO_DBLIB" != "no"; then
57066
57067    if test -f $PHP_PDO_DBLIB/include/sybdb.h; then
57068      PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
57069      PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include
57070    elif test -f $PHP_PDO_DBLIB/include/freetds/sybdb.h; then
57071      PDO_FREETDS_INSTALLATION_DIR=$PHP_PDO_DBLIB
57072      PDO_FREETDS_INCLUDE_DIR=$PHP_PDO_DBLIB/include/freetds
57073    else
57074      as_fn_error $? "Directory $PHP_PDO_DBLIB is not a FreeTDS installation directory" "$LINENO" 5
57075    fi
57076
57077    if test "x$PHP_LIBDIR" = "x" ; then
57078      PHP_LIBDIR=lib
57079    fi
57080
57081    if test ! -r "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libsybdb.a" && test ! -r "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libsybdb.so"; then
57082       as_fn_error $? "Could not find $PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR/libsybdb.a|so" "$LINENO" 5
57083    fi
57084
57085
57086  if test "$PDO_FREETDS_INCLUDE_DIR" != "/usr/include"; then
57087
57088  if test -z "$PDO_FREETDS_INCLUDE_DIR" || echo "$PDO_FREETDS_INCLUDE_DIR" | grep '^/' >/dev/null ; then
57089    ai_p=$PDO_FREETDS_INCLUDE_DIR
57090  else
57091
57092    ep_dir=`echo $PDO_FREETDS_INCLUDE_DIR|$SED 's%/*[^/][^/]*/*$%%'`
57093
57094    ep_realdir=`(cd "$ep_dir" && pwd)`
57095    ai_p="$ep_realdir"/`basename "$PDO_FREETDS_INCLUDE_DIR"`
57096  fi
57097
57098
57099
57100  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57101
57102  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
57103  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57104    eval "INCLUDEPATH$unique=set"
57105
57106      if test ""; then
57107        INCLUDES="-I$ai_p $INCLUDES"
57108      else
57109        INCLUDES="$INCLUDES -I$ai_p"
57110      fi
57111
57112  fi
57113
57114  fi
57115
57116
57117
57118  if test "$ext_shared" = "yes"; then
57119    PDO_DBLIB_SHARED_LIBADD="-lsybdb $PDO_DBLIB_SHARED_LIBADD"
57120    if test -n "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR"; then
57121
57122  if test "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" != "/usr/lib"; then
57123
57124  if test -z "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" || echo "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
57125    ai_p=$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR
57126  else
57127
57128    ep_dir=`echo $PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
57129
57130    ep_realdir=`(cd "$ep_dir" && pwd)`
57131    ai_p="$ep_realdir"/`basename "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR"`
57132  fi
57133
57134
57135      if test "$ext_shared" = "yes"; then
57136        PDO_DBLIB_SHARED_LIBADD="-L$ai_p $PDO_DBLIB_SHARED_LIBADD"
57137        test -n "$ld_runpath_switch" && PDO_DBLIB_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_DBLIB_SHARED_LIBADD"
57138      else
57139
57140
57141
57142  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57143
57144  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
57145  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57146    eval "LIBPATH$unique=set"
57147
57148    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
57149    LDFLAGS="$LDFLAGS -L$ai_p"
57150    PHP_RPATHS="$PHP_RPATHS $ai_p"
57151
57152  fi
57153
57154
57155      fi
57156
57157  fi
57158
57159    fi
57160  else
57161
57162
57163  if test -n "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR"; then
57164
57165  if test "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" != "/usr/lib"; then
57166
57167  if test -z "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" || echo "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
57168    ai_p=$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR
57169  else
57170
57171    ep_dir=`echo $PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
57172
57173    ep_realdir=`(cd "$ep_dir" && pwd)`
57174    ai_p="$ep_realdir"/`basename "$PDO_FREETDS_INSTALLATION_DIR/$PHP_LIBDIR"`
57175  fi
57176
57177
57178
57179
57180
57181  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57182
57183  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
57184  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57185    eval "LIBPATH$unique=set"
57186
57187    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
57188    LDFLAGS="$LDFLAGS -L$ai_p"
57189    PHP_RPATHS="$PHP_RPATHS $ai_p"
57190
57191  fi
57192
57193
57194
57195  fi
57196
57197  fi
57198
57199
57200  case sybdb in
57201  c|c_r) ;;
57202  *)
57203      LIBS="-lsybdb $LIBS"
57204   ;;
57205  esac
57206
57207
57208
57209
57210  fi
57211
57212
57213  fi
57214
57215
57216  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
57217printf %s "checking for PDO includes... " >&6; }
57218if test ${pdo_cv_inc_path+y}
57219then :
57220  printf %s "(cached) " >&6
57221else $as_nop
57222
57223    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
57224      pdo_cv_inc_path=$abs_srcdir/ext
57225    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
57226      pdo_cv_inc_path=$abs_srcdir/ext
57227    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
57228      pdo_cv_inc_path=$phpincludedir/ext
57229    fi
57230
57231fi
57232{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
57233printf "%s\n" "$pdo_cv_inc_path" >&6; }
57234  if test -n "$pdo_cv_inc_path"; then
57235:
57236  else
57237as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
57238  fi
57239
57240
57241  PDO_DBLIB_DEFS="-DPDO_DBLIB_FLAVOUR=\\\"freetds\\\""
57242
57243  ext_builddir=ext/pdo_dblib
57244  ext_srcdir=$abs_srcdir/ext/pdo_dblib
57245  ext_dir=ext/pdo_dblib
57246
57247  ac_extra=`echo "-I$pdo_cv_inc_path $PDO_DBLIB_DEFS -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
57248
57249  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
57250    PHP_PDO_DBLIB_SHARED=no
57251
57252
57253  case $ext_dir in
57254  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
57255  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
57256  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
57257  esac
57258
57259
57260
57261  b_c_pre=$php_c_pre
57262  b_cxx_pre=$php_cxx_pre
57263  b_c_meta=$php_c_meta
57264  b_cxx_meta=$php_cxx_meta
57265  b_c_post=$php_c_post
57266  b_cxx_post=$php_cxx_post
57267  b_lo=$php_lo
57268
57269
57270  old_IFS=$IFS
57271  for ac_src in pdo_dblib.c dblib_driver.c dblib_stmt.c; do
57272
57273      IFS=.
57274      set $ac_src
57275      ac_obj=$1
57276      IFS=$old_IFS
57277
57278      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
57279
57280      case $ac_src in
57281        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57282        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57283        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57284        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
57285      esac
57286
57287      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
57288
57289    cat >>Makefile.objects<<EOF
57290-include $ac_bdir$ac_obj.dep
57291$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
57292	$ac_comp
57293EOF
57294  done
57295
57296
57297    EXT_STATIC="$EXT_STATIC pdo_dblib;$ext_dir"
57298    if test "$ext_shared" != "nocli"; then
57299      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_dblib;$ext_dir"
57300    fi
57301  else
57302    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
57303      PHP_PDO_DBLIB_SHARED=yes
57304
57305  case $ext_dir in
57306  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
57307  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
57308  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
57309  esac
57310
57311
57312
57313  b_c_pre=$shared_c_pre
57314  b_cxx_pre=$shared_cxx_pre
57315  b_c_meta=$shared_c_meta
57316  b_cxx_meta=$shared_cxx_meta
57317  b_c_post=$shared_c_post
57318  b_cxx_post=$shared_cxx_post
57319  b_lo=$shared_lo
57320
57321
57322  old_IFS=$IFS
57323  for ac_src in pdo_dblib.c dblib_driver.c dblib_stmt.c; do
57324
57325      IFS=.
57326      set $ac_src
57327      ac_obj=$1
57328      IFS=$old_IFS
57329
57330      shared_objects_pdo_dblib="$shared_objects_pdo_dblib $ac_bdir$ac_obj.lo"
57331
57332      case $ac_src in
57333        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57334        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57335        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57336        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
57337      esac
57338
57339      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
57340
57341    cat >>Makefile.objects<<EOF
57342-include $ac_bdir$ac_obj.dep
57343$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
57344	$ac_comp
57345EOF
57346  done
57347
57348
57349  install_modules="install-modules"
57350  suffix=la
57351
57352  case $host_alias in
57353    *aix*)
57354      additional_flags="-Wl,-G"
57355      ;;
57356  esac
57357
57358  if test "x" = "xyes"; then
57359    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_dblib.$suffix"
57360  else
57361    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_dblib.$suffix"
57362  fi
57363
57364  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_dblib"
57365
57366  cat >>Makefile.objects<<EOF
57367\$(phplibdir)/pdo_dblib.$suffix: $ext_builddir/pdo_dblib.$suffix
57368	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_dblib.$suffix \$(phplibdir)
57369
57370$ext_builddir/pdo_dblib.$suffix: \$(shared_objects_pdo_dblib) \$(PDO_DBLIB_SHARED_DEPENDENCIES)
57371	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_dblib) \$(PDO_DBLIB_SHARED_LIBADD)
57372
57373EOF
57374
57375
57376printf "%s\n" "#define COMPILE_DL_PDO_DBLIB 1" >>confdefs.h
57377
57378    fi
57379  fi
57380
57381  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
57382    PHP_PDO_DBLIB_SHARED=no
57383    case "$PHP_SAPI" in
57384      cgi|embed|phpdbg)
57385
57386
57387  case $ext_dir in
57388  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
57389  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
57390  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
57391  esac
57392
57393
57394
57395  b_c_pre=$php_c_pre
57396  b_cxx_pre=$php_cxx_pre
57397  b_c_meta=$php_c_meta
57398  b_cxx_meta=$php_cxx_meta
57399  b_c_post=$php_c_post
57400  b_cxx_post=$php_cxx_post
57401  b_lo=$php_lo
57402
57403
57404  old_IFS=$IFS
57405  for ac_src in pdo_dblib.c dblib_driver.c dblib_stmt.c; do
57406
57407      IFS=.
57408      set $ac_src
57409      ac_obj=$1
57410      IFS=$old_IFS
57411
57412      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
57413
57414      case $ac_src in
57415        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57416        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57417        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57418        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
57419      esac
57420
57421      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
57422
57423    cat >>Makefile.objects<<EOF
57424-include $ac_bdir$ac_obj.dep
57425$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
57426	$ac_comp
57427EOF
57428  done
57429
57430
57431        EXT_STATIC="$EXT_STATIC pdo_dblib;$ext_dir"
57432        ;;
57433      *)
57434
57435
57436  case $ext_dir in
57437  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
57438  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
57439  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
57440  esac
57441
57442
57443
57444  b_c_pre=$php_c_pre
57445  b_cxx_pre=$php_cxx_pre
57446  b_c_meta=$php_c_meta
57447  b_cxx_meta=$php_cxx_meta
57448  b_c_post=$php_c_post
57449  b_cxx_post=$php_cxx_post
57450  b_lo=$php_lo
57451
57452
57453  old_IFS=$IFS
57454  for ac_src in pdo_dblib.c dblib_driver.c dblib_stmt.c; do
57455
57456      IFS=.
57457      set $ac_src
57458      ac_obj=$1
57459      IFS=$old_IFS
57460
57461      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
57462
57463      case $ac_src in
57464        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57465        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57466        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
57467        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
57468      esac
57469
57470      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
57471
57472    cat >>Makefile.objects<<EOF
57473-include $ac_bdir$ac_obj.dep
57474$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
57475	$ac_comp
57476EOF
57477  done
57478
57479
57480        ;;
57481    esac
57482    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_dblib;$ext_dir"
57483  fi
57484
57485
57486    BUILD_DIR="$BUILD_DIR $ext_builddir"
57487
57488
57489
57490  if test "$ext_builddir" = "."; then
57491    PHP_PECL_EXTENSION=pdo_dblib
57492
57493  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
57494
57495  fi
57496
57497  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dnet_addr in -ldnet_stub" >&5
57498printf %s "checking for dnet_addr in -ldnet_stub... " >&6; }
57499if test ${ac_cv_lib_dnet_stub_dnet_addr+y}
57500then :
57501  printf %s "(cached) " >&6
57502else $as_nop
57503  ac_check_lib_save_LIBS=$LIBS
57504LIBS="-ldnet_stub  $LIBS"
57505cat confdefs.h - <<_ACEOF >conftest.$ac_ext
57506/* end confdefs.h.  */
57507
57508/* Override any GCC internal prototype to avoid an error.
57509   Use char because int might match the return type of a GCC
57510   builtin and then its argument prototype would still apply.  */
57511char dnet_addr ();
57512int
57513main (void)
57514{
57515return dnet_addr ();
57516  ;
57517  return 0;
57518}
57519_ACEOF
57520if ac_fn_c_try_link "$LINENO"
57521then :
57522  ac_cv_lib_dnet_stub_dnet_addr=yes
57523else $as_nop
57524  ac_cv_lib_dnet_stub_dnet_addr=no
57525fi
57526rm -f core conftest.err conftest.$ac_objext conftest.beam \
57527    conftest$ac_exeext conftest.$ac_ext
57528LIBS=$ac_check_lib_save_LIBS
57529fi
57530{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_addr" >&5
57531printf "%s\n" "$ac_cv_lib_dnet_stub_dnet_addr" >&6; }
57532if test "x$ac_cv_lib_dnet_stub_dnet_addr" = xyes
57533then :
57534
57535
57536
57537  if test "$ext_shared" = "yes"; then
57538    PDO_DBLIB_SHARED_LIBADD="-ldnet_stub $PDO_DBLIB_SHARED_LIBADD"
57539    if test -n ""; then
57540
57541  if test "" != "/usr/$PHP_LIBDIR" && test "" != "/usr/lib"; then
57542
57543  if test -z "" || echo "" | grep '^/' >/dev/null ; then
57544    ai_p=
57545  else
57546
57547    ep_dir=`echo |$SED 's%/*[^/][^/]*/*$%%'`
57548
57549    ep_realdir=`(cd "$ep_dir" && pwd)`
57550    ai_p="$ep_realdir"/`basename ""`
57551  fi
57552
57553
57554      if test "$ext_shared" = "yes"; then
57555        PDO_DBLIB_SHARED_LIBADD="-L$ai_p $PDO_DBLIB_SHARED_LIBADD"
57556        test -n "$ld_runpath_switch" && PDO_DBLIB_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_DBLIB_SHARED_LIBADD"
57557      else
57558
57559
57560
57561  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57562
57563  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
57564  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57565    eval "LIBPATH$unique=set"
57566
57567    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
57568    LDFLAGS="$LDFLAGS -L$ai_p"
57569    PHP_RPATHS="$PHP_RPATHS $ai_p"
57570
57571  fi
57572
57573
57574      fi
57575
57576  fi
57577
57578    fi
57579  else
57580
57581
57582  if test -n ""; then
57583
57584  if test "" != "/usr/$PHP_LIBDIR" && test "" != "/usr/lib"; then
57585
57586  if test -z "" || echo "" | grep '^/' >/dev/null ; then
57587    ai_p=
57588  else
57589
57590    ep_dir=`echo |$SED 's%/*[^/][^/]*/*$%%'`
57591
57592    ep_realdir=`(cd "$ep_dir" && pwd)`
57593    ai_p="$ep_realdir"/`basename ""`
57594  fi
57595
57596
57597
57598
57599
57600  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57601
57602  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
57603  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57604    eval "LIBPATH$unique=set"
57605
57606    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
57607    LDFLAGS="$LDFLAGS -L$ai_p"
57608    PHP_RPATHS="$PHP_RPATHS $ai_p"
57609
57610  fi
57611
57612
57613
57614  fi
57615
57616  fi
57617
57618
57619  case dnet_stub in
57620  c|c_r) ;;
57621  *)
57622      LIBS="-ldnet_stub $LIBS"
57623   ;;
57624  esac
57625
57626
57627
57628
57629  fi
57630
57631
57632
57633fi
57634
57635
57636printf "%s\n" "#define HAVE_PDO_DBLIB 1" >>confdefs.h
57637
57638
57639  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_DBLIB_SHARED_LIBADD"
57640
57641
57642
57643  am_i_shared=$PHP_PDO_DBLIB_SHARED
57644  is_it_shared=$PHP_PDO_SHARED
57645  is_it_enabled=$PHP_PDO
57646  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
57647    as_fn_error $? "
57648You've configured extension pdo_dblib to build statically, but it
57649depends on extension pdo, which you've configured to build shared.
57650You either need to build pdo_dblib shared or build pdo statically for the
57651build to be successful.
57652" "$LINENO" 5
57653  fi
57654  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
57655    as_fn_error $? "
57656You've configured extension pdo_dblib, which depends on extension pdo,
57657but you've either not enabled pdo, or have disabled it.
57658" "$LINENO" 5
57659  fi
57660
57661fi
57662
57663
57664
57665
57666
57667php_with_pdo_firebird=no
57668
57669{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Firebird support for PDO" >&5
57670printf %s "checking for Firebird support for PDO... " >&6; }
57671
57672# Check whether --with-pdo-firebird was given.
57673if test ${with_pdo_firebird+y}
57674then :
57675  withval=$with_pdo_firebird; PHP_PDO_FIREBIRD=$withval
57676else $as_nop
57677
57678  PHP_PDO_FIREBIRD=no
57679  test "$PHP_ENABLE_ALL" && PHP_PDO_FIREBIRD=$PHP_ENABLE_ALL
57680
57681fi
57682
57683
57684
57685ext_output="yes, shared"
57686ext_shared=yes
57687case $PHP_PDO_FIREBIRD in
57688shared,*)
57689  PHP_PDO_FIREBIRD=`echo "$PHP_PDO_FIREBIRD"|$SED 's/^shared,//'`
57690  ;;
57691shared)
57692  PHP_PDO_FIREBIRD=yes
57693  ;;
57694no)
57695  ext_output=no
57696  ext_shared=no
57697  ;;
57698*)
57699  ext_output=yes
57700  ext_shared=no
57701  ;;
57702esac
57703
57704
57705
57706{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
57707printf "%s\n" "$ext_output" >&6; }
57708
57709
57710
57711
57712if test "$PHP_PDO_FIREBIRD" != "no"; then
57713
57714  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
57715    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
57716  fi
57717
57718  # Extract the first word of "fb_config", so it can be a program name with args.
57719set dummy fb_config; ac_word=$2
57720{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
57721printf %s "checking for $ac_word... " >&6; }
57722if test ${ac_cv_path_FB_CONFIG+y}
57723then :
57724  printf %s "(cached) " >&6
57725else $as_nop
57726  case $FB_CONFIG in
57727  [\\/]* | ?:[\\/]*)
57728  ac_cv_path_FB_CONFIG="$FB_CONFIG" # Let the user override the test with a path.
57729  ;;
57730  *)
57731  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
57732for as_dir in $PATH
57733do
57734  IFS=$as_save_IFS
57735  case $as_dir in #(((
57736    '') as_dir=./ ;;
57737    */) ;;
57738    *) as_dir=$as_dir/ ;;
57739  esac
57740    for ac_exec_ext in '' $ac_executable_extensions; do
57741  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57742    ac_cv_path_FB_CONFIG="$as_dir$ac_word$ac_exec_ext"
57743    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57744    break 2
57745  fi
57746done
57747  done
57748IFS=$as_save_IFS
57749
57750  test -z "$ac_cv_path_FB_CONFIG" && ac_cv_path_FB_CONFIG="no"
57751  ;;
57752esac
57753fi
57754FB_CONFIG=$ac_cv_path_FB_CONFIG
57755if test -n "$FB_CONFIG"; then
57756  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $FB_CONFIG" >&5
57757printf "%s\n" "$FB_CONFIG" >&6; }
57758else
57759  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
57760printf "%s\n" "no" >&6; }
57761fi
57762
57763
57764
57765  if test -x "$FB_CONFIG" && test "$PHP_PDO_FIREBIRD" = "yes"; then
57766    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libfbconfig" >&5
57767printf %s "checking for libfbconfig... " >&6; }
57768    FB_CFLAGS=`$FB_CONFIG --cflags`
57769    FB_LIBDIR=`$FB_CONFIG --libs`
57770    FB_VERSION=`$FB_CONFIG --version`
57771    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: version $FB_VERSION" >&5
57772printf "%s\n" "version $FB_VERSION" >&6; }
57773
57774  for ac_i in $FB_LIBDIR; do
57775    case $ac_i in
57776    -pthread)
57777      if test "$ext_shared" = "yes"; then
57778        PDO_FIREBIRD_SHARED_LIBADD="$PDO_FIREBIRD_SHARED_LIBADD -pthread"
57779      else
57780
57781
57782  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
57783
57784  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
57785  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57786    eval "EXTRA_LDFLAGS$unique=set"
57787    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
57788  fi
57789
57790
57791
57792  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
57793
57794  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
57795  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57796    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
57797    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
57798  fi
57799
57800      fi
57801    ;;
57802    -l*)
57803      ac_ii=`echo $ac_i|cut -c 3-`
57804
57805
57806  case $ac_ii in
57807  c|c_r) ;;
57808  *)
57809    if test "$ext_shared" = "yes"; then
57810        PDO_FIREBIRD_SHARED_LIBADD="$PDO_FIREBIRD_SHARED_LIBADD -l$ac_ii"
57811    else
57812
57813
57814  case $ac_ii in
57815  c|c_r) ;;
57816  *)
57817      LIBS="$LIBS -l$ac_ii"
57818   ;;
57819  esac
57820
57821
57822    fi
57823   ;;
57824  esac
57825
57826
57827    ;;
57828    -L*)
57829      ac_ii=`echo $ac_i|cut -c 3-`
57830
57831  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
57832
57833  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
57834    ai_p=$ac_ii
57835  else
57836
57837    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
57838
57839    ep_realdir=`(cd "$ep_dir" && pwd)`
57840    ai_p="$ep_realdir"/`basename "$ac_ii"`
57841  fi
57842
57843
57844      if test "$ext_shared" = "yes"; then
57845        PDO_FIREBIRD_SHARED_LIBADD="-L$ai_p $PDO_FIREBIRD_SHARED_LIBADD"
57846        test -n "$ld_runpath_switch" && PDO_FIREBIRD_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_FIREBIRD_SHARED_LIBADD"
57847      else
57848
57849
57850
57851  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57852
57853  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
57854  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57855    eval "LIBPATH$unique=set"
57856
57857    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
57858    LDFLAGS="$LDFLAGS -L$ai_p"
57859    PHP_RPATHS="$PHP_RPATHS $ai_p"
57860
57861  fi
57862
57863
57864      fi
57865
57866  fi
57867
57868    ;;
57869    esac
57870  done
57871
57872
57873  for ac_i in $FB_CFLAGS; do
57874    case $ac_i in
57875    -I*)
57876      ac_ii=`echo $ac_i|cut -c 3-`
57877
57878  if test "$ac_ii" != "/usr/include"; then
57879
57880  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
57881    ai_p=$ac_ii
57882  else
57883
57884    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
57885
57886    ep_realdir=`(cd "$ep_dir" && pwd)`
57887    ai_p="$ep_realdir"/`basename "$ac_ii"`
57888  fi
57889
57890
57891
57892  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
57893
57894  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
57895  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57896    eval "INCLUDEPATH$unique=set"
57897
57898      if test ""; then
57899        INCLUDES="-I$ai_p $INCLUDES"
57900      else
57901        INCLUDES="$INCLUDES -I$ai_p"
57902      fi
57903
57904  fi
57905
57906  fi
57907
57908    ;;
57909    esac
57910  done
57911
57912
57913  else
57914    if test "$PHP_PDO_FIREBIRD" = "yes"; then
57915      FIREBIRD_INCDIR=
57916      FIREBIRD_LIBDIR=
57917      FIREBIRD_LIBDIR_FLAG=
57918    else
57919      FIREBIRD_INCDIR=$PHP_PDO_FIREBIRD/include
57920      FIREBIRD_LIBDIR=$PHP_PDO_FIREBIRD/$PHP_LIBDIR
57921      FIREBIRD_LIBDIR_FLAG=-L$FIREBIRD_LIBDIR
57922    fi
57923
57924
57925  save_old_LDFLAGS=$LDFLAGS
57926  ac_stuff="
57927      $FIREBIRD_LIBDIR_FLAG
57928    "
57929
57930  save_ext_shared=$ext_shared
57931  ext_shared=yes
57932
57933  for ac_i in $ac_stuff; do
57934    case $ac_i in
57935    -pthread)
57936      if test "$ext_shared" = "yes"; then
57937        LDFLAGS="$LDFLAGS -pthread"
57938      else
57939
57940
57941  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
57942
57943  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
57944  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57945    eval "EXTRA_LDFLAGS$unique=set"
57946    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
57947  fi
57948
57949
57950
57951  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
57952
57953  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
57954  if test -n "$unique" && test "`eval $cmd`" = "" ; then
57955    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
57956    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
57957  fi
57958
57959      fi
57960    ;;
57961    -l*)
57962      ac_ii=`echo $ac_i|cut -c 3-`
57963
57964
57965  case $ac_ii in
57966  c|c_r) ;;
57967  *)
57968    if test "$ext_shared" = "yes"; then
57969        LDFLAGS="$LDFLAGS -l$ac_ii"
57970    else
57971
57972
57973  case $ac_ii in
57974  c|c_r) ;;
57975  *)
57976      LIBS="$LIBS -l$ac_ii"
57977   ;;
57978  esac
57979
57980
57981    fi
57982   ;;
57983  esac
57984
57985
57986    ;;
57987    -L*)
57988      ac_ii=`echo $ac_i|cut -c 3-`
57989
57990  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
57991
57992  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
57993    ai_p=$ac_ii
57994  else
57995
57996    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
57997
57998    ep_realdir=`(cd "$ep_dir" && pwd)`
57999    ai_p="$ep_realdir"/`basename "$ac_ii"`
58000  fi
58001
58002
58003      if test "$ext_shared" = "yes"; then
58004        LDFLAGS="-L$ai_p $LDFLAGS"
58005        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
58006      else
58007
58008
58009
58010  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58011
58012  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
58013  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58014    eval "LIBPATH$unique=set"
58015
58016    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
58017    LDFLAGS="$LDFLAGS -L$ai_p"
58018    PHP_RPATHS="$PHP_RPATHS $ai_p"
58019
58020  fi
58021
58022
58023      fi
58024
58025  fi
58026
58027    ;;
58028    esac
58029  done
58030
58031  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for isc_detach_database in -lfbclient" >&5
58032printf %s "checking for isc_detach_database in -lfbclient... " >&6; }
58033if test ${ac_cv_lib_fbclient_isc_detach_database+y}
58034then :
58035  printf %s "(cached) " >&6
58036else $as_nop
58037  ac_check_lib_save_LIBS=$LIBS
58038LIBS="-lfbclient  $LIBS"
58039cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58040/* end confdefs.h.  */
58041
58042/* Override any GCC internal prototype to avoid an error.
58043   Use char because int might match the return type of a GCC
58044   builtin and then its argument prototype would still apply.  */
58045char isc_detach_database ();
58046int
58047main (void)
58048{
58049return isc_detach_database ();
58050  ;
58051  return 0;
58052}
58053_ACEOF
58054if ac_fn_c_try_link "$LINENO"
58055then :
58056  ac_cv_lib_fbclient_isc_detach_database=yes
58057else $as_nop
58058  ac_cv_lib_fbclient_isc_detach_database=no
58059fi
58060rm -f core conftest.err conftest.$ac_objext conftest.beam \
58061    conftest$ac_exeext conftest.$ac_ext
58062LIBS=$ac_check_lib_save_LIBS
58063fi
58064{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fbclient_isc_detach_database" >&5
58065printf "%s\n" "$ac_cv_lib_fbclient_isc_detach_database" >&6; }
58066if test "x$ac_cv_lib_fbclient_isc_detach_database" = xyes
58067then :
58068
58069    LDFLAGS=$save_old_LDFLAGS
58070    ext_shared=$save_ext_shared
58071
58072      FIREBIRD_LIBNAME=fbclient
58073
58074
58075else $as_nop
58076
58077    LDFLAGS=$save_old_LDFLAGS
58078    ext_shared=$save_ext_shared
58079    unset ac_cv_lib_fbclient_isc_detach_database
58080
58081
58082  save_old_LDFLAGS=$LDFLAGS
58083  ac_stuff="
58084        $FIREBIRD_LIBDIR_FLAG
58085      "
58086
58087  save_ext_shared=$ext_shared
58088  ext_shared=yes
58089
58090  for ac_i in $ac_stuff; do
58091    case $ac_i in
58092    -pthread)
58093      if test "$ext_shared" = "yes"; then
58094        LDFLAGS="$LDFLAGS -pthread"
58095      else
58096
58097
58098  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
58099
58100  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
58101  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58102    eval "EXTRA_LDFLAGS$unique=set"
58103    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
58104  fi
58105
58106
58107
58108  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
58109
58110  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
58111  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58112    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
58113    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
58114  fi
58115
58116      fi
58117    ;;
58118    -l*)
58119      ac_ii=`echo $ac_i|cut -c 3-`
58120
58121
58122  case $ac_ii in
58123  c|c_r) ;;
58124  *)
58125    if test "$ext_shared" = "yes"; then
58126        LDFLAGS="$LDFLAGS -l$ac_ii"
58127    else
58128
58129
58130  case $ac_ii in
58131  c|c_r) ;;
58132  *)
58133      LIBS="$LIBS -l$ac_ii"
58134   ;;
58135  esac
58136
58137
58138    fi
58139   ;;
58140  esac
58141
58142
58143    ;;
58144    -L*)
58145      ac_ii=`echo $ac_i|cut -c 3-`
58146
58147  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
58148
58149  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
58150    ai_p=$ac_ii
58151  else
58152
58153    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
58154
58155    ep_realdir=`(cd "$ep_dir" && pwd)`
58156    ai_p="$ep_realdir"/`basename "$ac_ii"`
58157  fi
58158
58159
58160      if test "$ext_shared" = "yes"; then
58161        LDFLAGS="-L$ai_p $LDFLAGS"
58162        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
58163      else
58164
58165
58166
58167  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58168
58169  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
58170  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58171    eval "LIBPATH$unique=set"
58172
58173    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
58174    LDFLAGS="$LDFLAGS -L$ai_p"
58175    PHP_RPATHS="$PHP_RPATHS $ai_p"
58176
58177  fi
58178
58179
58180      fi
58181
58182  fi
58183
58184    ;;
58185    esac
58186  done
58187
58188  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for isc_detach_database in -lgds" >&5
58189printf %s "checking for isc_detach_database in -lgds... " >&6; }
58190if test ${ac_cv_lib_gds_isc_detach_database+y}
58191then :
58192  printf %s "(cached) " >&6
58193else $as_nop
58194  ac_check_lib_save_LIBS=$LIBS
58195LIBS="-lgds  $LIBS"
58196cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58197/* end confdefs.h.  */
58198
58199/* Override any GCC internal prototype to avoid an error.
58200   Use char because int might match the return type of a GCC
58201   builtin and then its argument prototype would still apply.  */
58202char isc_detach_database ();
58203int
58204main (void)
58205{
58206return isc_detach_database ();
58207  ;
58208  return 0;
58209}
58210_ACEOF
58211if ac_fn_c_try_link "$LINENO"
58212then :
58213  ac_cv_lib_gds_isc_detach_database=yes
58214else $as_nop
58215  ac_cv_lib_gds_isc_detach_database=no
58216fi
58217rm -f core conftest.err conftest.$ac_objext conftest.beam \
58218    conftest$ac_exeext conftest.$ac_ext
58219LIBS=$ac_check_lib_save_LIBS
58220fi
58221{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gds_isc_detach_database" >&5
58222printf "%s\n" "$ac_cv_lib_gds_isc_detach_database" >&6; }
58223if test "x$ac_cv_lib_gds_isc_detach_database" = xyes
58224then :
58225
58226    LDFLAGS=$save_old_LDFLAGS
58227    ext_shared=$save_ext_shared
58228
58229        FIREBIRD_LIBNAME=gds
58230
58231
58232else $as_nop
58233
58234    LDFLAGS=$save_old_LDFLAGS
58235    ext_shared=$save_ext_shared
58236    unset ac_cv_lib_gds_isc_detach_database
58237
58238
58239  save_old_LDFLAGS=$LDFLAGS
58240  ac_stuff="
58241          $FIREBIRD_LIBDIR_FLAG
58242        "
58243
58244  save_ext_shared=$ext_shared
58245  ext_shared=yes
58246
58247  for ac_i in $ac_stuff; do
58248    case $ac_i in
58249    -pthread)
58250      if test "$ext_shared" = "yes"; then
58251        LDFLAGS="$LDFLAGS -pthread"
58252      else
58253
58254
58255  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
58256
58257  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
58258  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58259    eval "EXTRA_LDFLAGS$unique=set"
58260    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
58261  fi
58262
58263
58264
58265  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
58266
58267  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
58268  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58269    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
58270    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
58271  fi
58272
58273      fi
58274    ;;
58275    -l*)
58276      ac_ii=`echo $ac_i|cut -c 3-`
58277
58278
58279  case $ac_ii in
58280  c|c_r) ;;
58281  *)
58282    if test "$ext_shared" = "yes"; then
58283        LDFLAGS="$LDFLAGS -l$ac_ii"
58284    else
58285
58286
58287  case $ac_ii in
58288  c|c_r) ;;
58289  *)
58290      LIBS="$LIBS -l$ac_ii"
58291   ;;
58292  esac
58293
58294
58295    fi
58296   ;;
58297  esac
58298
58299
58300    ;;
58301    -L*)
58302      ac_ii=`echo $ac_i|cut -c 3-`
58303
58304  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
58305
58306  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
58307    ai_p=$ac_ii
58308  else
58309
58310    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
58311
58312    ep_realdir=`(cd "$ep_dir" && pwd)`
58313    ai_p="$ep_realdir"/`basename "$ac_ii"`
58314  fi
58315
58316
58317      if test "$ext_shared" = "yes"; then
58318        LDFLAGS="-L$ai_p $LDFLAGS"
58319        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
58320      else
58321
58322
58323
58324  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58325
58326  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
58327  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58328    eval "LIBPATH$unique=set"
58329
58330    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
58331    LDFLAGS="$LDFLAGS -L$ai_p"
58332    PHP_RPATHS="$PHP_RPATHS $ai_p"
58333
58334  fi
58335
58336
58337      fi
58338
58339  fi
58340
58341    ;;
58342    esac
58343  done
58344
58345  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for isc_detach_database in -lib_util" >&5
58346printf %s "checking for isc_detach_database in -lib_util... " >&6; }
58347if test ${ac_cv_lib_ib_util_isc_detach_database+y}
58348then :
58349  printf %s "(cached) " >&6
58350else $as_nop
58351  ac_check_lib_save_LIBS=$LIBS
58352LIBS="-lib_util  $LIBS"
58353cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58354/* end confdefs.h.  */
58355
58356/* Override any GCC internal prototype to avoid an error.
58357   Use char because int might match the return type of a GCC
58358   builtin and then its argument prototype would still apply.  */
58359char isc_detach_database ();
58360int
58361main (void)
58362{
58363return isc_detach_database ();
58364  ;
58365  return 0;
58366}
58367_ACEOF
58368if ac_fn_c_try_link "$LINENO"
58369then :
58370  ac_cv_lib_ib_util_isc_detach_database=yes
58371else $as_nop
58372  ac_cv_lib_ib_util_isc_detach_database=no
58373fi
58374rm -f core conftest.err conftest.$ac_objext conftest.beam \
58375    conftest$ac_exeext conftest.$ac_ext
58376LIBS=$ac_check_lib_save_LIBS
58377fi
58378{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ib_util_isc_detach_database" >&5
58379printf "%s\n" "$ac_cv_lib_ib_util_isc_detach_database" >&6; }
58380if test "x$ac_cv_lib_ib_util_isc_detach_database" = xyes
58381then :
58382
58383    LDFLAGS=$save_old_LDFLAGS
58384    ext_shared=$save_ext_shared
58385
58386          FIREBIRD_LIBNAME=ib_util
58387
58388
58389else $as_nop
58390
58391    LDFLAGS=$save_old_LDFLAGS
58392    ext_shared=$save_ext_shared
58393    unset ac_cv_lib_ib_util_isc_detach_database
58394
58395          as_fn_error $? "libfbclient, libgds or libib_util not found! Check config.log for more information." "$LINENO" 5
58396
58397
58398fi
58399
58400
58401
58402fi
58403
58404
58405
58406fi
58407
58408
58409
58410  if test "$ext_shared" = "yes"; then
58411    PDO_FIREBIRD_SHARED_LIBADD="-l$FIREBIRD_LIBNAME $PDO_FIREBIRD_SHARED_LIBADD"
58412    if test -n "$FIREBIRD_LIBDIR"; then
58413
58414  if test "$FIREBIRD_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$FIREBIRD_LIBDIR" != "/usr/lib"; then
58415
58416  if test -z "$FIREBIRD_LIBDIR" || echo "$FIREBIRD_LIBDIR" | grep '^/' >/dev/null ; then
58417    ai_p=$FIREBIRD_LIBDIR
58418  else
58419
58420    ep_dir=`echo $FIREBIRD_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
58421
58422    ep_realdir=`(cd "$ep_dir" && pwd)`
58423    ai_p="$ep_realdir"/`basename "$FIREBIRD_LIBDIR"`
58424  fi
58425
58426
58427      if test "$ext_shared" = "yes"; then
58428        PDO_FIREBIRD_SHARED_LIBADD="-L$ai_p $PDO_FIREBIRD_SHARED_LIBADD"
58429        test -n "$ld_runpath_switch" && PDO_FIREBIRD_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_FIREBIRD_SHARED_LIBADD"
58430      else
58431
58432
58433
58434  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58435
58436  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
58437  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58438    eval "LIBPATH$unique=set"
58439
58440    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
58441    LDFLAGS="$LDFLAGS -L$ai_p"
58442    PHP_RPATHS="$PHP_RPATHS $ai_p"
58443
58444  fi
58445
58446
58447      fi
58448
58449  fi
58450
58451    fi
58452  else
58453
58454
58455  if test -n "$FIREBIRD_LIBDIR"; then
58456
58457  if test "$FIREBIRD_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$FIREBIRD_LIBDIR" != "/usr/lib"; then
58458
58459  if test -z "$FIREBIRD_LIBDIR" || echo "$FIREBIRD_LIBDIR" | grep '^/' >/dev/null ; then
58460    ai_p=$FIREBIRD_LIBDIR
58461  else
58462
58463    ep_dir=`echo $FIREBIRD_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
58464
58465    ep_realdir=`(cd "$ep_dir" && pwd)`
58466    ai_p="$ep_realdir"/`basename "$FIREBIRD_LIBDIR"`
58467  fi
58468
58469
58470
58471
58472
58473  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58474
58475  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
58476  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58477    eval "LIBPATH$unique=set"
58478
58479    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
58480    LDFLAGS="$LDFLAGS -L$ai_p"
58481    PHP_RPATHS="$PHP_RPATHS $ai_p"
58482
58483  fi
58484
58485
58486
58487  fi
58488
58489  fi
58490
58491
58492  case $FIREBIRD_LIBNAME in
58493  c|c_r) ;;
58494  *)
58495      LIBS="-l$FIREBIRD_LIBNAME $LIBS"
58496   ;;
58497  esac
58498
58499
58500
58501
58502  fi
58503
58504
58505
58506  if test "$FIREBIRD_INCDIR" != "/usr/include"; then
58507
58508  if test -z "$FIREBIRD_INCDIR" || echo "$FIREBIRD_INCDIR" | grep '^/' >/dev/null ; then
58509    ai_p=$FIREBIRD_INCDIR
58510  else
58511
58512    ep_dir=`echo $FIREBIRD_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
58513
58514    ep_realdir=`(cd "$ep_dir" && pwd)`
58515    ai_p="$ep_realdir"/`basename "$FIREBIRD_INCDIR"`
58516  fi
58517
58518
58519
58520  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
58521
58522  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
58523  if test -n "$unique" && test "`eval $cmd`" = "" ; then
58524    eval "INCLUDEPATH$unique=set"
58525
58526      if test ""; then
58527        INCLUDES="-I$ai_p $INCLUDES"
58528      else
58529        INCLUDES="$INCLUDES -I$ai_p"
58530      fi
58531
58532  fi
58533
58534  fi
58535
58536  fi
58537
58538
58539  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
58540printf %s "checking for PDO includes... " >&6; }
58541if test ${pdo_cv_inc_path+y}
58542then :
58543  printf %s "(cached) " >&6
58544else $as_nop
58545
58546    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
58547      pdo_cv_inc_path=$abs_srcdir/ext
58548    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
58549      pdo_cv_inc_path=$abs_srcdir/ext
58550    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
58551      pdo_cv_inc_path=$phpincludedir/ext
58552    fi
58553
58554fi
58555{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
58556printf "%s\n" "$pdo_cv_inc_path" >&6; }
58557  if test -n "$pdo_cv_inc_path"; then
58558:
58559  else
58560as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
58561  fi
58562
58563
58564
58565printf "%s\n" "#define HAVE_PDO_FIREBIRD 1" >>confdefs.h
58566
58567
58568  ext_builddir=ext/pdo_firebird
58569  ext_srcdir=$abs_srcdir/ext/pdo_firebird
58570  ext_dir=ext/pdo_firebird
58571
58572  ac_extra=`echo "-I$pdo_cv_inc_path"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
58573
58574  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
58575    PHP_PDO_FIREBIRD_SHARED=no
58576
58577
58578  case $ext_dir in
58579  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
58580  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
58581  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
58582  esac
58583
58584
58585
58586  b_c_pre=$php_c_pre
58587  b_cxx_pre=$php_cxx_pre
58588  b_c_meta=$php_c_meta
58589  b_cxx_meta=$php_cxx_meta
58590  b_c_post=$php_c_post
58591  b_cxx_post=$php_cxx_post
58592  b_lo=$php_lo
58593
58594
58595  old_IFS=$IFS
58596  for ac_src in pdo_firebird.c firebird_driver.c firebird_statement.c; do
58597
58598      IFS=.
58599      set $ac_src
58600      ac_obj=$1
58601      IFS=$old_IFS
58602
58603      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
58604
58605      case $ac_src in
58606        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58607        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58608        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58609        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
58610      esac
58611
58612      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
58613
58614    cat >>Makefile.objects<<EOF
58615-include $ac_bdir$ac_obj.dep
58616$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
58617	$ac_comp
58618EOF
58619  done
58620
58621
58622    EXT_STATIC="$EXT_STATIC pdo_firebird;$ext_dir"
58623    if test "$ext_shared" != "nocli"; then
58624      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_firebird;$ext_dir"
58625    fi
58626  else
58627    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
58628      PHP_PDO_FIREBIRD_SHARED=yes
58629
58630  case $ext_dir in
58631  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
58632  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
58633  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
58634  esac
58635
58636
58637
58638  b_c_pre=$shared_c_pre
58639  b_cxx_pre=$shared_cxx_pre
58640  b_c_meta=$shared_c_meta
58641  b_cxx_meta=$shared_cxx_meta
58642  b_c_post=$shared_c_post
58643  b_cxx_post=$shared_cxx_post
58644  b_lo=$shared_lo
58645
58646
58647  old_IFS=$IFS
58648  for ac_src in pdo_firebird.c firebird_driver.c firebird_statement.c; do
58649
58650      IFS=.
58651      set $ac_src
58652      ac_obj=$1
58653      IFS=$old_IFS
58654
58655      shared_objects_pdo_firebird="$shared_objects_pdo_firebird $ac_bdir$ac_obj.lo"
58656
58657      case $ac_src in
58658        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58659        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58660        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58661        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
58662      esac
58663
58664      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
58665
58666    cat >>Makefile.objects<<EOF
58667-include $ac_bdir$ac_obj.dep
58668$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
58669	$ac_comp
58670EOF
58671  done
58672
58673
58674  install_modules="install-modules"
58675  suffix=la
58676
58677  case $host_alias in
58678    *aix*)
58679      additional_flags="-Wl,-G"
58680      ;;
58681  esac
58682
58683  if test "x" = "xyes"; then
58684    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_firebird.$suffix"
58685  else
58686    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_firebird.$suffix"
58687  fi
58688
58689  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_firebird"
58690
58691  cat >>Makefile.objects<<EOF
58692\$(phplibdir)/pdo_firebird.$suffix: $ext_builddir/pdo_firebird.$suffix
58693	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_firebird.$suffix \$(phplibdir)
58694
58695$ext_builddir/pdo_firebird.$suffix: \$(shared_objects_pdo_firebird) \$(PDO_FIREBIRD_SHARED_DEPENDENCIES)
58696	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_firebird) \$(PDO_FIREBIRD_SHARED_LIBADD)
58697
58698EOF
58699
58700
58701printf "%s\n" "#define COMPILE_DL_PDO_FIREBIRD 1" >>confdefs.h
58702
58703    fi
58704  fi
58705
58706  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
58707    PHP_PDO_FIREBIRD_SHARED=no
58708    case "$PHP_SAPI" in
58709      cgi|embed|phpdbg)
58710
58711
58712  case $ext_dir in
58713  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
58714  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
58715  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
58716  esac
58717
58718
58719
58720  b_c_pre=$php_c_pre
58721  b_cxx_pre=$php_cxx_pre
58722  b_c_meta=$php_c_meta
58723  b_cxx_meta=$php_cxx_meta
58724  b_c_post=$php_c_post
58725  b_cxx_post=$php_cxx_post
58726  b_lo=$php_lo
58727
58728
58729  old_IFS=$IFS
58730  for ac_src in pdo_firebird.c firebird_driver.c firebird_statement.c; do
58731
58732      IFS=.
58733      set $ac_src
58734      ac_obj=$1
58735      IFS=$old_IFS
58736
58737      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
58738
58739      case $ac_src in
58740        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58741        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58742        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58743        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
58744      esac
58745
58746      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
58747
58748    cat >>Makefile.objects<<EOF
58749-include $ac_bdir$ac_obj.dep
58750$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
58751	$ac_comp
58752EOF
58753  done
58754
58755
58756        EXT_STATIC="$EXT_STATIC pdo_firebird;$ext_dir"
58757        ;;
58758      *)
58759
58760
58761  case $ext_dir in
58762  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
58763  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
58764  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
58765  esac
58766
58767
58768
58769  b_c_pre=$php_c_pre
58770  b_cxx_pre=$php_cxx_pre
58771  b_c_meta=$php_c_meta
58772  b_cxx_meta=$php_cxx_meta
58773  b_c_post=$php_c_post
58774  b_cxx_post=$php_cxx_post
58775  b_lo=$php_lo
58776
58777
58778  old_IFS=$IFS
58779  for ac_src in pdo_firebird.c firebird_driver.c firebird_statement.c; do
58780
58781      IFS=.
58782      set $ac_src
58783      ac_obj=$1
58784      IFS=$old_IFS
58785
58786      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
58787
58788      case $ac_src in
58789        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58790        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58791        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
58792        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
58793      esac
58794
58795      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
58796
58797    cat >>Makefile.objects<<EOF
58798-include $ac_bdir$ac_obj.dep
58799$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
58800	$ac_comp
58801EOF
58802  done
58803
58804
58805        ;;
58806    esac
58807    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_firebird;$ext_dir"
58808  fi
58809
58810
58811    BUILD_DIR="$BUILD_DIR $ext_builddir"
58812
58813
58814
58815  if test "$ext_builddir" = "."; then
58816    PHP_PECL_EXTENSION=pdo_firebird
58817
58818  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
58819
58820  fi
58821
58822
58823  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_FIREBIRD_SHARED_LIBADD"
58824
58825
58826  am_i_shared=$PHP_PDO_FIREBIRD_SHARED
58827  is_it_shared=$PHP_PDO_SHARED
58828  is_it_enabled=$PHP_PDO
58829  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
58830    as_fn_error $? "
58831You've configured extension pdo_firebird to build statically, but it
58832depends on extension pdo, which you've configured to build shared.
58833You either need to build pdo_firebird shared or build pdo statically for the
58834build to be successful.
58835" "$LINENO" 5
58836  fi
58837  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
58838    as_fn_error $? "
58839You've configured extension pdo_firebird, which depends on extension pdo,
58840but you've either not enabled pdo, or have disabled it.
58841" "$LINENO" 5
58842  fi
58843
58844fi
58845
58846
58847
58848
58849
58850php_with_pdo_mysql=no
58851
58852{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MySQL support for PDO" >&5
58853printf %s "checking for MySQL support for PDO... " >&6; }
58854
58855# Check whether --with-pdo-mysql was given.
58856if test ${with_pdo_mysql+y}
58857then :
58858  withval=$with_pdo_mysql; PHP_PDO_MYSQL=$withval
58859else $as_nop
58860
58861  PHP_PDO_MYSQL=no
58862  test "$PHP_ENABLE_ALL" && PHP_PDO_MYSQL=$PHP_ENABLE_ALL
58863
58864fi
58865
58866
58867
58868ext_output="yes, shared"
58869ext_shared=yes
58870case $PHP_PDO_MYSQL in
58871shared,*)
58872  PHP_PDO_MYSQL=`echo "$PHP_PDO_MYSQL"|$SED 's/^shared,//'`
58873  ;;
58874shared)
58875  PHP_PDO_MYSQL=yes
58876  ;;
58877no)
58878  ext_output=no
58879  ext_shared=no
58880  ;;
58881*)
58882  ext_output=yes
58883  ext_shared=no
58884  ;;
58885esac
58886
58887
58888
58889{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
58890printf "%s\n" "$ext_output" >&6; }
58891
58892
58893
58894
58895if test -z "$PHP_ZLIB_DIR"; then
58896
58897php_with_zlib_dir=no
58898
58899{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the location of libz" >&5
58900printf %s "checking for the location of libz... " >&6; }
58901
58902# Check whether --with-zlib-dir was given.
58903if test ${with_zlib_dir+y}
58904then :
58905  withval=$with_zlib_dir; PHP_ZLIB_DIR=$withval
58906else $as_nop
58907
58908  PHP_ZLIB_DIR=no
58909
58910
58911fi
58912
58913
58914ext_output=$PHP_ZLIB_DIR
58915{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
58916printf "%s\n" "$ext_output" >&6; }
58917
58918
58919
58920fi
58921
58922if test "$PHP_PDO_MYSQL" != "no"; then
58923      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MySQL UNIX socket location" >&5
58924printf %s "checking for MySQL UNIX socket location... " >&6; }
58925  if test "$PHP_MYSQL_SOCK" != "no" && test "$PHP_MYSQL_SOCK" != "yes"; then
58926    MYSQL_SOCK=$PHP_MYSQL_SOCK
58927
58928printf "%s\n" "#define PHP_MYSQL_UNIX_SOCK_ADDR \"$MYSQL_SOCK\"" >>confdefs.h
58929
58930    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MYSQL_SOCK" >&5
58931printf "%s\n" "$MYSQL_SOCK" >&6; }
58932  elif test "$PHP_MYSQL_SOCK" = "yes"; then
58933
58934  for i in  \
58935    /var/run/mysqld/mysqld.sock \
58936    /var/tmp/mysql.sock \
58937    /var/run/mysql/mysql.sock \
58938    /var/lib/mysql/mysql.sock \
58939    /var/mysql/mysql.sock \
58940    /usr/local/mysql/var/mysql.sock \
58941    /Private/tmp/mysql.sock \
58942    /private/tmp/mysql.sock \
58943    /tmp/mysql.sock \
58944  ; do
58945    if test -r $i; then
58946      MYSQL_SOCK=$i
58947      break 2
58948    fi
58949  done
58950
58951  if test -n "$MYSQL_SOCK"; then
58952
58953printf "%s\n" "#define PHP_MYSQL_UNIX_SOCK_ADDR \"$MYSQL_SOCK\"" >>confdefs.h
58954
58955    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MYSQL_SOCK" >&5
58956printf "%s\n" "$MYSQL_SOCK" >&6; }
58957  else
58958    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
58959printf "%s\n" "no" >&6; }
58960  fi
58961
58962  else
58963    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
58964printf "%s\n" "no" >&6; }
58965  fi
58966
58967  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
58968    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
58969  fi
58970
58971  if test "$PHP_PDO_MYSQL" != "yes" && test "$PHP_PDO_MYSQL" != "mysqlnd"; then
58972    if test -f $PHP_PDO_MYSQL && test -x $PHP_PDO_MYSQL ; then
58973      PDO_MYSQL_CONFIG=$PHP_PDO_MYSQL
58974    else
58975      if test -d "$PHP_PDO_MYSQL" ; then
58976        if test -x "$PHP_PDO_MYSQL/bin/mysql_config" ; then
58977          PDO_MYSQL_CONFIG="$PHP_PDO_MYSQL/bin/mysql_config"
58978        else
58979          PDO_MYSQL_DIR="$PHP_PDO_MYSQL"
58980        fi
58981      fi
58982    fi
58983  fi
58984
58985  if test "$PHP_PDO_MYSQL" = "yes" || test "$PHP_PDO_MYSQL" = "mysqlnd"; then
58986        PHP_MYSQLND_ENABLED=yes
58987
58988printf "%s\n" "#define PDO_USE_MYSQLND 1" >>confdefs.h
58989
58990  else
58991
58992printf "%s\n" "#define HAVE_MYSQL 1" >>confdefs.h
58993
58994
58995    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mysql_config" >&5
58996printf %s "checking for mysql_config... " >&6; }
58997    if test -n "$PDO_MYSQL_CONFIG"; then
58998      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PDO_MYSQL_CONFIG" >&5
58999printf "%s\n" "$PDO_MYSQL_CONFIG" >&6; }
59000      if test "x$SED" = "x"; then
59001        # Extract the first word of "sed", so it can be a program name with args.
59002set dummy sed; ac_word=$2
59003{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
59004printf %s "checking for $ac_word... " >&6; }
59005if test ${ac_cv_path_SED+y}
59006then :
59007  printf %s "(cached) " >&6
59008else $as_nop
59009  case $SED in
59010  [\\/]* | ?:[\\/]*)
59011  ac_cv_path_SED="$SED" # Let the user override the test with a path.
59012  ;;
59013  *)
59014  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
59015for as_dir in $PATH
59016do
59017  IFS=$as_save_IFS
59018  case $as_dir in #(((
59019    '') as_dir=./ ;;
59020    */) ;;
59021    *) as_dir=$as_dir/ ;;
59022  esac
59023    for ac_exec_ext in '' $ac_executable_extensions; do
59024  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
59025    ac_cv_path_SED="$as_dir$ac_word$ac_exec_ext"
59026    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
59027    break 2
59028  fi
59029done
59030  done
59031IFS=$as_save_IFS
59032
59033  ;;
59034esac
59035fi
59036SED=$ac_cv_path_SED
59037if test -n "$SED"; then
59038  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
59039printf "%s\n" "$SED" >&6; }
59040else
59041  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
59042printf "%s\n" "no" >&6; }
59043fi
59044
59045
59046      fi
59047      PDO_MYSQL_LIBS=`$PDO_MYSQL_CONFIG --libs | $SED -e "s/'//g"`
59048      PDO_MYSQL_INCLUDE=`$PDO_MYSQL_CONFIG --cflags | $SED -e "s/'//g"`
59049    elif test -n "$PDO_MYSQL_DIR"; then
59050      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
59051printf "%s\n" "not found" >&6; }
59052      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mysql install under $PDO_MYSQL_DIR" >&5
59053printf %s "checking for mysql install under $PDO_MYSQL_DIR... " >&6; }
59054      if test -r $PDO_MYSQL_DIR/include/mysql; then
59055        PDO_MYSQL_INC_DIR=$PDO_MYSQL_DIR/include/mysql
59056      else
59057        PDO_MYSQL_INC_DIR=$PDO_MYSQL_DIR/include
59058      fi
59059      if test -r $PDO_MYSQL_DIR/$PHP_LIBDIR/mysql; then
59060        PDO_MYSQL_LIB_DIR=$PDO_MYSQL_DIR/$PHP_LIBDIR/mysql
59061      else
59062        PDO_MYSQL_LIB_DIR=$PDO_MYSQL_DIR/$PHP_LIBDIR
59063      fi
59064
59065      if test -r "$PDO_MYSQL_LIB_DIR"; then
59066        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: libs under $PDO_MYSQL_LIB_DIR; seems promising" >&5
59067printf "%s\n" "libs under $PDO_MYSQL_LIB_DIR; seems promising" >&6; }
59068      else
59069        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: can not find it" >&5
59070printf "%s\n" "can not find it" >&6; }
59071        as_fn_error $? "Unable to find your mysql installation" "$LINENO" 5
59072      fi
59073
59074
59075  if test "$PDO_MYSQL_INC_DIR" != "/usr/include"; then
59076
59077  if test -z "$PDO_MYSQL_INC_DIR" || echo "$PDO_MYSQL_INC_DIR" | grep '^/' >/dev/null ; then
59078    ai_p=$PDO_MYSQL_INC_DIR
59079  else
59080
59081    ep_dir=`echo $PDO_MYSQL_INC_DIR|$SED 's%/*[^/][^/]*/*$%%'`
59082
59083    ep_realdir=`(cd "$ep_dir" && pwd)`
59084    ai_p="$ep_realdir"/`basename "$PDO_MYSQL_INC_DIR"`
59085  fi
59086
59087
59088
59089  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59090
59091  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59092  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59093    eval "INCLUDEPATH$unique=set"
59094
59095      if test ""; then
59096        INCLUDES="-I$ai_p $INCLUDES"
59097      else
59098        INCLUDES="$INCLUDES -I$ai_p"
59099      fi
59100
59101  fi
59102
59103  fi
59104
59105      PDO_MYSQL_INCLUDE=-I$PDO_MYSQL_INC_DIR
59106    else
59107      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
59108printf "%s\n" "not found" >&6; }
59109      as_fn_error $? "Unable to find your mysql installation" "$LINENO" 5
59110    fi
59111
59112
59113  for ac_i in $PDO_MYSQL_INCLUDE; do
59114    case $ac_i in
59115    -I*)
59116      ac_ii=`echo $ac_i|cut -c 3-`
59117
59118  if test "$ac_ii" != "/usr/include"; then
59119
59120  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
59121    ai_p=$ac_ii
59122  else
59123
59124    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
59125
59126    ep_realdir=`(cd "$ep_dir" && pwd)`
59127    ai_p="$ep_realdir"/`basename "$ac_ii"`
59128  fi
59129
59130
59131
59132  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59133
59134  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59135  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59136    eval "INCLUDEPATH$unique=set"
59137
59138      if test ""; then
59139        INCLUDES="-I$ai_p $INCLUDES"
59140      else
59141        INCLUDES="$INCLUDES -I$ai_p"
59142      fi
59143
59144  fi
59145
59146  fi
59147
59148    ;;
59149    esac
59150  done
59151
59152
59153  for ac_i in $PDO_MYSQL_LIBS; do
59154    case $ac_i in
59155    -pthread)
59156      if test "$ext_shared" = "yes"; then
59157        PDO_MYSQL_SHARED_LIBADD="$PDO_MYSQL_SHARED_LIBADD -pthread"
59158      else
59159
59160
59161  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
59162
59163  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
59164  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59165    eval "EXTRA_LDFLAGS$unique=set"
59166    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
59167  fi
59168
59169
59170
59171  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
59172
59173  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
59174  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59175    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
59176    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
59177  fi
59178
59179      fi
59180    ;;
59181    -l*)
59182      ac_ii=`echo $ac_i|cut -c 3-`
59183
59184
59185  case $ac_ii in
59186  c|c_r) ;;
59187  *)
59188    if test "$ext_shared" = "yes"; then
59189        PDO_MYSQL_SHARED_LIBADD="$PDO_MYSQL_SHARED_LIBADD -l$ac_ii"
59190    else
59191
59192
59193  case $ac_ii in
59194  c|c_r) ;;
59195  *)
59196      LIBS="$LIBS -l$ac_ii"
59197   ;;
59198  esac
59199
59200
59201    fi
59202   ;;
59203  esac
59204
59205
59206    ;;
59207    -L*)
59208      ac_ii=`echo $ac_i|cut -c 3-`
59209
59210  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
59211
59212  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
59213    ai_p=$ac_ii
59214  else
59215
59216    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
59217
59218    ep_realdir=`(cd "$ep_dir" && pwd)`
59219    ai_p="$ep_realdir"/`basename "$ac_ii"`
59220  fi
59221
59222
59223      if test "$ext_shared" = "yes"; then
59224        PDO_MYSQL_SHARED_LIBADD="-L$ai_p $PDO_MYSQL_SHARED_LIBADD"
59225        test -n "$ld_runpath_switch" && PDO_MYSQL_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_MYSQL_SHARED_LIBADD"
59226      else
59227
59228
59229
59230  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59231
59232  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
59233  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59234    eval "LIBPATH$unique=set"
59235
59236    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
59237    LDFLAGS="$LDFLAGS -L$ai_p"
59238    PHP_RPATHS="$PHP_RPATHS $ai_p"
59239
59240  fi
59241
59242
59243      fi
59244
59245  fi
59246
59247    ;;
59248    esac
59249  done
59250
59251  fi
59252
59253
59254  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
59255printf %s "checking for PDO includes... " >&6; }
59256if test ${pdo_cv_inc_path+y}
59257then :
59258  printf %s "(cached) " >&6
59259else $as_nop
59260
59261    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
59262      pdo_cv_inc_path=$abs_srcdir/ext
59263    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
59264      pdo_cv_inc_path=$abs_srcdir/ext
59265    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
59266      pdo_cv_inc_path=$phpincludedir/ext
59267    fi
59268
59269fi
59270{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
59271printf "%s\n" "$pdo_cv_inc_path" >&6; }
59272  if test -n "$pdo_cv_inc_path"; then
59273:
59274  else
59275as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
59276  fi
59277
59278
59279  if test -n "$PDO_MYSQL_CONFIG"; then
59280    PDO_MYSQL_SOCKET=`$PDO_MYSQL_CONFIG --socket`
59281
59282printf "%s\n" "#define PDO_MYSQL_UNIX_ADDR \"$PDO_MYSQL_SOCKET\"" >>confdefs.h
59283
59284  fi
59285
59286
59287  ext_builddir=ext/pdo_mysql
59288  ext_srcdir=$abs_srcdir/ext/pdo_mysql
59289  ext_dir=ext/pdo_mysql
59290
59291  ac_extra=`echo "-I$pdo_cv_inc_path -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
59292
59293  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
59294    PHP_PDO_MYSQL_SHARED=no
59295
59296
59297  case $ext_dir in
59298  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
59299  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
59300  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
59301  esac
59302
59303
59304
59305  b_c_pre=$php_c_pre
59306  b_cxx_pre=$php_cxx_pre
59307  b_c_meta=$php_c_meta
59308  b_cxx_meta=$php_cxx_meta
59309  b_c_post=$php_c_post
59310  b_cxx_post=$php_cxx_post
59311  b_lo=$php_lo
59312
59313
59314  old_IFS=$IFS
59315  for ac_src in pdo_mysql.c mysql_driver.c mysql_statement.c; do
59316
59317      IFS=.
59318      set $ac_src
59319      ac_obj=$1
59320      IFS=$old_IFS
59321
59322      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
59323
59324      case $ac_src in
59325        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59326        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59327        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59328        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
59329      esac
59330
59331      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
59332
59333    cat >>Makefile.objects<<EOF
59334-include $ac_bdir$ac_obj.dep
59335$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
59336	$ac_comp
59337EOF
59338  done
59339
59340
59341    EXT_STATIC="$EXT_STATIC pdo_mysql;$ext_dir"
59342    if test "$ext_shared" != "nocli"; then
59343      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_mysql;$ext_dir"
59344    fi
59345  else
59346    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
59347      PHP_PDO_MYSQL_SHARED=yes
59348
59349  case $ext_dir in
59350  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
59351  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
59352  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
59353  esac
59354
59355
59356
59357  b_c_pre=$shared_c_pre
59358  b_cxx_pre=$shared_cxx_pre
59359  b_c_meta=$shared_c_meta
59360  b_cxx_meta=$shared_cxx_meta
59361  b_c_post=$shared_c_post
59362  b_cxx_post=$shared_cxx_post
59363  b_lo=$shared_lo
59364
59365
59366  old_IFS=$IFS
59367  for ac_src in pdo_mysql.c mysql_driver.c mysql_statement.c; do
59368
59369      IFS=.
59370      set $ac_src
59371      ac_obj=$1
59372      IFS=$old_IFS
59373
59374      shared_objects_pdo_mysql="$shared_objects_pdo_mysql $ac_bdir$ac_obj.lo"
59375
59376      case $ac_src in
59377        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59378        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59379        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59380        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
59381      esac
59382
59383      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
59384
59385    cat >>Makefile.objects<<EOF
59386-include $ac_bdir$ac_obj.dep
59387$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
59388	$ac_comp
59389EOF
59390  done
59391
59392
59393  install_modules="install-modules"
59394  suffix=la
59395
59396  case $host_alias in
59397    *aix*)
59398      additional_flags="-Wl,-G"
59399      ;;
59400  esac
59401
59402  if test "x" = "xyes"; then
59403    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_mysql.$suffix"
59404  else
59405    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_mysql.$suffix"
59406  fi
59407
59408  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_mysql"
59409
59410  cat >>Makefile.objects<<EOF
59411\$(phplibdir)/pdo_mysql.$suffix: $ext_builddir/pdo_mysql.$suffix
59412	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_mysql.$suffix \$(phplibdir)
59413
59414$ext_builddir/pdo_mysql.$suffix: \$(shared_objects_pdo_mysql) \$(PDO_MYSQL_SHARED_DEPENDENCIES)
59415	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_mysql) \$(PDO_MYSQL_SHARED_LIBADD)
59416
59417EOF
59418
59419
59420printf "%s\n" "#define COMPILE_DL_PDO_MYSQL 1" >>confdefs.h
59421
59422    fi
59423  fi
59424
59425  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
59426    PHP_PDO_MYSQL_SHARED=no
59427    case "$PHP_SAPI" in
59428      cgi|embed|phpdbg)
59429
59430
59431  case $ext_dir in
59432  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
59433  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
59434  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
59435  esac
59436
59437
59438
59439  b_c_pre=$php_c_pre
59440  b_cxx_pre=$php_cxx_pre
59441  b_c_meta=$php_c_meta
59442  b_cxx_meta=$php_cxx_meta
59443  b_c_post=$php_c_post
59444  b_cxx_post=$php_cxx_post
59445  b_lo=$php_lo
59446
59447
59448  old_IFS=$IFS
59449  for ac_src in pdo_mysql.c mysql_driver.c mysql_statement.c; do
59450
59451      IFS=.
59452      set $ac_src
59453      ac_obj=$1
59454      IFS=$old_IFS
59455
59456      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
59457
59458      case $ac_src in
59459        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59460        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59461        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59462        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
59463      esac
59464
59465      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
59466
59467    cat >>Makefile.objects<<EOF
59468-include $ac_bdir$ac_obj.dep
59469$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
59470	$ac_comp
59471EOF
59472  done
59473
59474
59475        EXT_STATIC="$EXT_STATIC pdo_mysql;$ext_dir"
59476        ;;
59477      *)
59478
59479
59480  case $ext_dir in
59481  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
59482  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
59483  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
59484  esac
59485
59486
59487
59488  b_c_pre=$php_c_pre
59489  b_cxx_pre=$php_cxx_pre
59490  b_c_meta=$php_c_meta
59491  b_cxx_meta=$php_cxx_meta
59492  b_c_post=$php_c_post
59493  b_cxx_post=$php_cxx_post
59494  b_lo=$php_lo
59495
59496
59497  old_IFS=$IFS
59498  for ac_src in pdo_mysql.c mysql_driver.c mysql_statement.c; do
59499
59500      IFS=.
59501      set $ac_src
59502      ac_obj=$1
59503      IFS=$old_IFS
59504
59505      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
59506
59507      case $ac_src in
59508        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59509        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59510        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
59511        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
59512      esac
59513
59514      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
59515
59516    cat >>Makefile.objects<<EOF
59517-include $ac_bdir$ac_obj.dep
59518$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
59519	$ac_comp
59520EOF
59521  done
59522
59523
59524        ;;
59525    esac
59526    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_mysql;$ext_dir"
59527  fi
59528
59529
59530    BUILD_DIR="$BUILD_DIR $ext_builddir"
59531
59532
59533
59534  if test "$ext_builddir" = "."; then
59535    PHP_PECL_EXTENSION=pdo_mysql
59536
59537  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
59538
59539  fi
59540
59541
59542
59543  am_i_shared=$PHP_PDO_MYSQL_SHARED
59544  is_it_shared=$PHP_PDO_SHARED
59545  is_it_enabled=$PHP_PDO
59546  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
59547    as_fn_error $? "
59548You've configured extension pdo_mysql to build statically, but it
59549depends on extension pdo, which you've configured to build shared.
59550You either need to build pdo_mysql shared or build pdo statically for the
59551build to be successful.
59552" "$LINENO" 5
59553  fi
59554  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
59555    as_fn_error $? "
59556You've configured extension pdo_mysql, which depends on extension pdo,
59557but you've either not enabled pdo, or have disabled it.
59558" "$LINENO" 5
59559  fi
59560
59561
59562  if test "$PHP_PDO_MYSQL" = "yes" || test "$PHP_PDO_MYSQL" = "mysqlnd"; then
59563
59564  am_i_shared=$PHP_PDO_MYSQL_SHARED
59565  is_it_shared=$PHP_MYSQLND_SHARED
59566  is_it_enabled=$PHP_MYSQLND
59567  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
59568    as_fn_error $? "
59569You've configured extension pdo_mysql to build statically, but it
59570depends on extension mysqlnd, which you've configured to build shared.
59571You either need to build pdo_mysql shared or build mysqlnd statically for the
59572build to be successful.
59573" "$LINENO" 5
59574  fi
59575  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
59576    as_fn_error $? "
59577You've configured extension pdo_mysql, which depends on extension mysqlnd,
59578but you've either not enabled mysqlnd, or have disabled it.
59579" "$LINENO" 5
59580  fi
59581
59582  fi
59583
59584  PDO_MYSQL_MODULE_TYPE=external
59585
59586
59587  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_MYSQL_SHARED_LIBADD"
59588
59589
59590
59591
59592  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_MYSQL_MODULE_TYPE"
59593
59594
59595fi
59596
59597
59598
59599
59600if test -z "$SED"; then
59601  PHP_PDO_OCI_SED="sed";
59602else
59603  PHP_PDO_OCI_SED="$SED";
59604fi
59605
59606PHP_PDO_OCI_TAIL1=`echo a | tail -n1 2>/dev/null`
59607if test "$PHP_PDO_OCI_TAIL1" = "a"; then
59608    PHP_PDO_OCI_TAIL1="tail -n1"
59609else
59610    PHP_PDO_OCI_TAIL1="tail -1"
59611fi
59612
59613
59614
59615
59616
59617
59618php_with_pdo_oci=no
59619
59620{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle OCI support for PDO" >&5
59621printf %s "checking Oracle OCI support for PDO... " >&6; }
59622
59623# Check whether --with-pdo-oci was given.
59624if test ${with_pdo_oci+y}
59625then :
59626  withval=$with_pdo_oci; PHP_PDO_OCI=$withval
59627else $as_nop
59628
59629  PHP_PDO_OCI=no
59630  test "$PHP_ENABLE_ALL" && PHP_PDO_OCI=$PHP_ENABLE_ALL
59631
59632fi
59633
59634
59635
59636ext_output="yes, shared"
59637ext_shared=yes
59638case $PHP_PDO_OCI in
59639shared,*)
59640  PHP_PDO_OCI=`echo "$PHP_PDO_OCI"|$SED 's/^shared,//'`
59641  ;;
59642shared)
59643  PHP_PDO_OCI=yes
59644  ;;
59645no)
59646  ext_output=no
59647  ext_shared=no
59648  ;;
59649*)
59650  ext_output=yes
59651  ext_shared=no
59652  ;;
59653esac
59654
59655
59656
59657{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
59658printf "%s\n" "$ext_output" >&6; }
59659
59660
59661
59662
59663if test "$PHP_PDO_OCI" != "no"; then
59664
59665  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
59666    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
59667  fi
59668
59669  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle Install-Dir" >&5
59670printf %s "checking Oracle Install-Dir... " >&6; }
59671  if test "$PHP_PDO_OCI" = "yes" || test -z "$PHP_PDO_OCI"; then
59672    PDO_OCI_DIR=$ORACLE_HOME
59673  else
59674    PDO_OCI_DIR=$PHP_PDO_OCI
59675  fi
59676  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PHP_PDO_OCI" >&5
59677printf "%s\n" "$PHP_PDO_OCI" >&6; }
59678
59679  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if that is sane" >&5
59680printf %s "checking if that is sane... " >&6; }
59681  if test -z "$PDO_OCI_DIR"; then
59682    as_fn_error $? "You need to tell me where to find your Oracle Instant Client SDK, or set ORACLE_HOME." "$LINENO" 5
59683  else
59684    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59685printf "%s\n" "yes" >&6; }
59686  fi
59687
59688  if test "instantclient" = "`echo $PDO_OCI_DIR | cut -d, -f1`" ; then
59689    # The cast to long int works around a bug in the HP C Compiler
59690# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
59691# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
59692# This bug is HP SR number 8606223364.
59693{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
59694printf %s "checking size of long... " >&6; }
59695if test ${ac_cv_sizeof_long+y}
59696then :
59697  printf %s "(cached) " >&6
59698else $as_nop
59699  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
59700then :
59701
59702else $as_nop
59703  if test "$ac_cv_type_long" = yes; then
59704     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
59705printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
59706as_fn_error 77 "cannot compute sizeof (long)
59707See \`config.log' for more details" "$LINENO" 5; }
59708   else
59709     ac_cv_sizeof_long=0
59710   fi
59711fi
59712
59713fi
59714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
59715printf "%s\n" "$ac_cv_sizeof_long" >&6; }
59716
59717
59718
59719printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
59720
59721
59722    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
59723printf %s "checking if we're at 64-bit platform... " >&6; }
59724    if test "$ac_cv_sizeof_long" -eq 4
59725then :
59726
59727      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
59728printf "%s\n" "no" >&6; }
59729      PDO_OCI_CLIENT_DIR="client"
59730
59731else $as_nop
59732
59733      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59734printf "%s\n" "yes" >&6; }
59735      PDO_OCI_CLIENT_DIR="client64"
59736
59737fi
59738
59739    PDO_OCI_LIB_DIR="`echo $PDO_OCI_DIR | cut -d, -f2`"
59740
59741  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle version" >&5
59742printf %s "checking Oracle version... " >&6; }
59743  PDO_OCI_LCS_BASE=$PDO_OCI_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME
59744    PDO_OCI_LCS=`ls $PDO_OCI_LCS_BASE.*.1 2> /dev/null | $PHP_PDO_OCI_TAIL1`
59745  if test -f "$PDO_OCI_LCS"; then
59746            PDO_OCI_VERSION=`echo $PDO_OCI_LCS | $PHP_PDO_OCI_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
59747  elif test -f $PDO_OCI_LCS_BASE.9.0; then
59748            PDO_OCI_VERSION=9.0
59749  else
59750    as_fn_error $? "Oracle libclntsh.$SHLIB_SUFFIX_NAME client library not found or its version is lower than 9" "$LINENO" 5
59751  fi
59752  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PDO_OCI_VERSION" >&5
59753printf "%s\n" "$PDO_OCI_VERSION" >&6; }
59754
59755
59756    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for oci.h" >&5
59757printf %s "checking for oci.h... " >&6; }
59758        OCISDKRPMINC=`echo "$PDO_OCI_LIB_DIR" | $PHP_PDO_OCI_SED -e 's!^\(.*\)/lib/oracle/\(.*\)/\('${PDO_OCI_CLIENT_DIR}'\)/lib/*$!\1/include/oracle/\2/\3!'`
59759
59760        OCISDKMANINC=`echo "$PDO_OCI_LIB_DIR" | $PHP_PDO_OCI_SED -e 's!^\(.*\)/lib/*$!\1/include!'`
59761
59762        OCISDKZIPINC=$PDO_OCI_LIB_DIR/sdk/include
59763
59764
59765    if test -f "$OCISDKRPMINC/oci.h" ; then
59766
59767  if test "$OCISDKRPMINC" != "/usr/include"; then
59768
59769  if test -z "$OCISDKRPMINC" || echo "$OCISDKRPMINC" | grep '^/' >/dev/null ; then
59770    ai_p=$OCISDKRPMINC
59771  else
59772
59773    ep_dir=`echo $OCISDKRPMINC|$SED 's%/*[^/][^/]*/*$%%'`
59774
59775    ep_realdir=`(cd "$ep_dir" && pwd)`
59776    ai_p="$ep_realdir"/`basename "$OCISDKRPMINC"`
59777  fi
59778
59779
59780
59781  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59782
59783  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59784  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59785    eval "INCLUDEPATH$unique=set"
59786
59787      if test ""; then
59788        INCLUDES="-I$ai_p $INCLUDES"
59789      else
59790        INCLUDES="$INCLUDES -I$ai_p"
59791      fi
59792
59793  fi
59794
59795  fi
59796
59797      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKRPMINC" >&5
59798printf "%s\n" "$OCISDKRPMINC" >&6; }
59799    elif test -f "$OCISDKMANINC/oci.h" ; then
59800
59801  if test "$OCISDKMANINC" != "/usr/include"; then
59802
59803  if test -z "$OCISDKMANINC" || echo "$OCISDKMANINC" | grep '^/' >/dev/null ; then
59804    ai_p=$OCISDKMANINC
59805  else
59806
59807    ep_dir=`echo $OCISDKMANINC|$SED 's%/*[^/][^/]*/*$%%'`
59808
59809    ep_realdir=`(cd "$ep_dir" && pwd)`
59810    ai_p="$ep_realdir"/`basename "$OCISDKMANINC"`
59811  fi
59812
59813
59814
59815  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59816
59817  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59818  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59819    eval "INCLUDEPATH$unique=set"
59820
59821      if test ""; then
59822        INCLUDES="-I$ai_p $INCLUDES"
59823      else
59824        INCLUDES="$INCLUDES -I$ai_p"
59825      fi
59826
59827  fi
59828
59829  fi
59830
59831      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKMANINC" >&5
59832printf "%s\n" "$OCISDKMANINC" >&6; }
59833    elif test -f "$OCISDKZIPINC/oci.h" ; then
59834
59835  if test "$OCISDKZIPINC" != "/usr/include"; then
59836
59837  if test -z "$OCISDKZIPINC" || echo "$OCISDKZIPINC" | grep '^/' >/dev/null ; then
59838    ai_p=$OCISDKZIPINC
59839  else
59840
59841    ep_dir=`echo $OCISDKZIPINC|$SED 's%/*[^/][^/]*/*$%%'`
59842
59843    ep_realdir=`(cd "$ep_dir" && pwd)`
59844    ai_p="$ep_realdir"/`basename "$OCISDKZIPINC"`
59845  fi
59846
59847
59848
59849  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59850
59851  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59852  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59853    eval "INCLUDEPATH$unique=set"
59854
59855      if test ""; then
59856        INCLUDES="-I$ai_p $INCLUDES"
59857      else
59858        INCLUDES="$INCLUDES -I$ai_p"
59859      fi
59860
59861  fi
59862
59863  fi
59864
59865      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OCISDKZIPINC" >&5
59866printf "%s\n" "$OCISDKZIPINC" >&6; }
59867    else
59868      as_fn_error $? "I'm too dumb to figure out where the include dir is in your Instant Client install" "$LINENO" 5
59869    fi
59870  else
59871
59872  # The cast to long int works around a bug in the HP C Compiler
59873# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
59874# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
59875# This bug is HP SR number 8606223364.
59876{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
59877printf %s "checking size of long... " >&6; }
59878if test ${ac_cv_sizeof_long+y}
59879then :
59880  printf %s "(cached) " >&6
59881else $as_nop
59882  if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"
59883then :
59884
59885else $as_nop
59886  if test "$ac_cv_type_long" = yes; then
59887     { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
59888printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
59889as_fn_error 77 "cannot compute sizeof (long)
59890See \`config.log' for more details" "$LINENO" 5; }
59891   else
59892     ac_cv_sizeof_long=0
59893   fi
59894fi
59895
59896fi
59897{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
59898printf "%s\n" "$ac_cv_sizeof_long" >&6; }
59899
59900
59901
59902printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
59903
59904
59905  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we're at 64-bit platform" >&5
59906printf %s "checking if we're at 64-bit platform... " >&6; }
59907  if test "$ac_cv_sizeof_long" -eq 4
59908then :
59909
59910    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
59911printf "%s\n" "no" >&6; }
59912    TMP_PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib32"
59913
59914else $as_nop
59915
59916    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59917printf "%s\n" "yes" >&6; }
59918    TMP_PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib"
59919
59920fi
59921
59922  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking OCI8 libraries dir" >&5
59923printf %s "checking OCI8 libraries dir... " >&6; }
59924  if test -d "$PDO_OCI_DIR/lib" && test ! -d "$PDO_OCI_DIR/lib32"; then
59925    PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib"
59926  elif test ! -d "$PDO_OCI_DIR/lib" && test -d "$PDO_OCI_DIR/lib32"; then
59927    PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib32"
59928  elif test -d "$PDO_OCI_DIR/lib" && test -d "$PDO_OCI_DIR/lib32"; then
59929    PDO_OCI_LIB_DIR=$TMP_PDO_OCI_LIB_DIR
59930  else
59931    as_fn_error $? "Oracle required OCI8 libraries not found" "$LINENO" 5
59932  fi
59933  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PDO_OCI_LIB_DIR" >&5
59934printf "%s\n" "$PDO_OCI_LIB_DIR" >&6; }
59935
59936
59937    if test -d "$PDO_OCI_DIR/rdbms/public"; then
59938
59939  if test "$PDO_OCI_DIR/rdbms/public" != "/usr/include"; then
59940
59941  if test -z "$PDO_OCI_DIR/rdbms/public" || echo "$PDO_OCI_DIR/rdbms/public" | grep '^/' >/dev/null ; then
59942    ai_p=$PDO_OCI_DIR/rdbms/public
59943  else
59944
59945    ep_dir=`echo $PDO_OCI_DIR/rdbms/public|$SED 's%/*[^/][^/]*/*$%%'`
59946
59947    ep_realdir=`(cd "$ep_dir" && pwd)`
59948    ai_p="$ep_realdir"/`basename "$PDO_OCI_DIR/rdbms/public"`
59949  fi
59950
59951
59952
59953  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59954
59955  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59956  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59957    eval "INCLUDEPATH$unique=set"
59958
59959      if test ""; then
59960        INCLUDES="-I$ai_p $INCLUDES"
59961      else
59962        INCLUDES="$INCLUDES -I$ai_p"
59963      fi
59964
59965  fi
59966
59967  fi
59968
59969      PDO_OCI_INCLUDES="$PDO_OCI_INCLUDES -I$PDO_OCI_DIR/rdbms/public"
59970    fi
59971    if test -d "$PDO_OCI_DIR/rdbms/demo"; then
59972
59973  if test "$PDO_OCI_DIR/rdbms/demo" != "/usr/include"; then
59974
59975  if test -z "$PDO_OCI_DIR/rdbms/demo" || echo "$PDO_OCI_DIR/rdbms/demo" | grep '^/' >/dev/null ; then
59976    ai_p=$PDO_OCI_DIR/rdbms/demo
59977  else
59978
59979    ep_dir=`echo $PDO_OCI_DIR/rdbms/demo|$SED 's%/*[^/][^/]*/*$%%'`
59980
59981    ep_realdir=`(cd "$ep_dir" && pwd)`
59982    ai_p="$ep_realdir"/`basename "$PDO_OCI_DIR/rdbms/demo"`
59983  fi
59984
59985
59986
59987  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
59988
59989  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
59990  if test -n "$unique" && test "`eval $cmd`" = "" ; then
59991    eval "INCLUDEPATH$unique=set"
59992
59993      if test ""; then
59994        INCLUDES="-I$ai_p $INCLUDES"
59995      else
59996        INCLUDES="$INCLUDES -I$ai_p"
59997      fi
59998
59999  fi
60000
60001  fi
60002
60003      PDO_OCI_INCLUDES="$PDO_OCI_INCLUDES -I$PDO_OCI_DIR/rdbms/demo"
60004    fi
60005    if test -d "$PDO_OCI_DIR/network/public"; then
60006
60007  if test "$PDO_OCI_DIR/network/public" != "/usr/include"; then
60008
60009  if test -z "$PDO_OCI_DIR/network/public" || echo "$PDO_OCI_DIR/network/public" | grep '^/' >/dev/null ; then
60010    ai_p=$PDO_OCI_DIR/network/public
60011  else
60012
60013    ep_dir=`echo $PDO_OCI_DIR/network/public|$SED 's%/*[^/][^/]*/*$%%'`
60014
60015    ep_realdir=`(cd "$ep_dir" && pwd)`
60016    ai_p="$ep_realdir"/`basename "$PDO_OCI_DIR/network/public"`
60017  fi
60018
60019
60020
60021  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60022
60023  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
60024  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60025    eval "INCLUDEPATH$unique=set"
60026
60027      if test ""; then
60028        INCLUDES="-I$ai_p $INCLUDES"
60029      else
60030        INCLUDES="$INCLUDES -I$ai_p"
60031      fi
60032
60033  fi
60034
60035  fi
60036
60037      PDO_OCI_INCLUDES="$PDO_OCI_INCLUDES -I$PDO_OCI_DIR/network/public"
60038    fi
60039    if test -d "$PDO_OCI_DIR/plsql/public"; then
60040
60041  if test "$PDO_OCI_DIR/plsql/public" != "/usr/include"; then
60042
60043  if test -z "$PDO_OCI_DIR/plsql/public" || echo "$PDO_OCI_DIR/plsql/public" | grep '^/' >/dev/null ; then
60044    ai_p=$PDO_OCI_DIR/plsql/public
60045  else
60046
60047    ep_dir=`echo $PDO_OCI_DIR/plsql/public|$SED 's%/*[^/][^/]*/*$%%'`
60048
60049    ep_realdir=`(cd "$ep_dir" && pwd)`
60050    ai_p="$ep_realdir"/`basename "$PDO_OCI_DIR/plsql/public"`
60051  fi
60052
60053
60054
60055  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60056
60057  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
60058  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60059    eval "INCLUDEPATH$unique=set"
60060
60061      if test ""; then
60062        INCLUDES="-I$ai_p $INCLUDES"
60063      else
60064        INCLUDES="$INCLUDES -I$ai_p"
60065      fi
60066
60067  fi
60068
60069  fi
60070
60071      PDO_OCI_INCLUDES="$PDO_OCI_INCLUDES -I$PDO_OCI_DIR/plsql/public"
60072    fi
60073    if test -d "$PDO_OCI_DIR/include"; then
60074
60075  if test "$PDO_OCI_DIR/include" != "/usr/include"; then
60076
60077  if test -z "$PDO_OCI_DIR/include" || echo "$PDO_OCI_DIR/include" | grep '^/' >/dev/null ; then
60078    ai_p=$PDO_OCI_DIR/include
60079  else
60080
60081    ep_dir=`echo $PDO_OCI_DIR/include|$SED 's%/*[^/][^/]*/*$%%'`
60082
60083    ep_realdir=`(cd "$ep_dir" && pwd)`
60084    ai_p="$ep_realdir"/`basename "$PDO_OCI_DIR/include"`
60085  fi
60086
60087
60088
60089  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60090
60091  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
60092  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60093    eval "INCLUDEPATH$unique=set"
60094
60095      if test ""; then
60096        INCLUDES="-I$ai_p $INCLUDES"
60097      else
60098        INCLUDES="$INCLUDES -I$ai_p"
60099      fi
60100
60101  fi
60102
60103  fi
60104
60105      PDO_OCI_INCLUDES="$PDO_OCI_INCLUDES -I$PDO_OCI_DIR/include"
60106    fi
60107
60108    if test -f "$PDO_OCI_LIB_DIR/sysliblist"; then
60109
60110  for ac_i in `cat $PDO_OCI_LIB_DIR/sysliblist`; do
60111    case $ac_i in
60112    -pthread)
60113      if test "$ext_shared" = "yes"; then
60114        PDO_OCI_SYSLIB="$PDO_OCI_SYSLIB -pthread"
60115      else
60116
60117
60118  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60119
60120  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
60121  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60122    eval "EXTRA_LDFLAGS$unique=set"
60123    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
60124  fi
60125
60126
60127
60128  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60129
60130  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
60131  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60132    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
60133    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
60134  fi
60135
60136      fi
60137    ;;
60138    -l*)
60139      ac_ii=`echo $ac_i|cut -c 3-`
60140
60141
60142  case $ac_ii in
60143  c|c_r) ;;
60144  *)
60145    if test "$ext_shared" = "yes"; then
60146        PDO_OCI_SYSLIB="$PDO_OCI_SYSLIB -l$ac_ii"
60147    else
60148
60149
60150  case $ac_ii in
60151  c|c_r) ;;
60152  *)
60153      LIBS="$LIBS -l$ac_ii"
60154   ;;
60155  esac
60156
60157
60158    fi
60159   ;;
60160  esac
60161
60162
60163    ;;
60164    -L*)
60165      ac_ii=`echo $ac_i|cut -c 3-`
60166
60167  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
60168
60169  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
60170    ai_p=$ac_ii
60171  else
60172
60173    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
60174
60175    ep_realdir=`(cd "$ep_dir" && pwd)`
60176    ai_p="$ep_realdir"/`basename "$ac_ii"`
60177  fi
60178
60179
60180      if test "$ext_shared" = "yes"; then
60181        PDO_OCI_SYSLIB="-L$ai_p $PDO_OCI_SYSLIB"
60182        test -n "$ld_runpath_switch" && PDO_OCI_SYSLIB="$ld_runpath_switch$ai_p $PDO_OCI_SYSLIB"
60183      else
60184
60185
60186
60187  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60188
60189  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60190  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60191    eval "LIBPATH$unique=set"
60192
60193    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60194    LDFLAGS="$LDFLAGS -L$ai_p"
60195    PHP_RPATHS="$PHP_RPATHS $ai_p"
60196
60197  fi
60198
60199
60200      fi
60201
60202  fi
60203
60204    ;;
60205    esac
60206  done
60207
60208    elif test -f "$PDO_OCI_DIR/rdbms/lib/sysliblist"; then
60209
60210  for ac_i in `cat $PDO_OCI_DIR/rdbms/lib/sysliblist`; do
60211    case $ac_i in
60212    -pthread)
60213      if test "$ext_shared" = "yes"; then
60214        PDO_OCI_SYSLIB="$PDO_OCI_SYSLIB -pthread"
60215      else
60216
60217
60218  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60219
60220  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
60221  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60222    eval "EXTRA_LDFLAGS$unique=set"
60223    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
60224  fi
60225
60226
60227
60228  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60229
60230  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
60231  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60232    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
60233    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
60234  fi
60235
60236      fi
60237    ;;
60238    -l*)
60239      ac_ii=`echo $ac_i|cut -c 3-`
60240
60241
60242  case $ac_ii in
60243  c|c_r) ;;
60244  *)
60245    if test "$ext_shared" = "yes"; then
60246        PDO_OCI_SYSLIB="$PDO_OCI_SYSLIB -l$ac_ii"
60247    else
60248
60249
60250  case $ac_ii in
60251  c|c_r) ;;
60252  *)
60253      LIBS="$LIBS -l$ac_ii"
60254   ;;
60255  esac
60256
60257
60258    fi
60259   ;;
60260  esac
60261
60262
60263    ;;
60264    -L*)
60265      ac_ii=`echo $ac_i|cut -c 3-`
60266
60267  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
60268
60269  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
60270    ai_p=$ac_ii
60271  else
60272
60273    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
60274
60275    ep_realdir=`(cd "$ep_dir" && pwd)`
60276    ai_p="$ep_realdir"/`basename "$ac_ii"`
60277  fi
60278
60279
60280      if test "$ext_shared" = "yes"; then
60281        PDO_OCI_SYSLIB="-L$ai_p $PDO_OCI_SYSLIB"
60282        test -n "$ld_runpath_switch" && PDO_OCI_SYSLIB="$ld_runpath_switch$ai_p $PDO_OCI_SYSLIB"
60283      else
60284
60285
60286
60287  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60288
60289  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60290  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60291    eval "LIBPATH$unique=set"
60292
60293    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60294    LDFLAGS="$LDFLAGS -L$ai_p"
60295    PHP_RPATHS="$PHP_RPATHS $ai_p"
60296
60297  fi
60298
60299
60300      fi
60301
60302  fi
60303
60304    ;;
60305    esac
60306  done
60307
60308    fi
60309
60310  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Oracle version" >&5
60311printf %s "checking Oracle version... " >&6; }
60312  PDO_OCI_LCS_BASE=$PDO_OCI_LIB_DIR/libclntsh.$SHLIB_SUFFIX_NAME
60313    PDO_OCI_LCS=`ls $PDO_OCI_LCS_BASE.*.1 2> /dev/null | $PHP_PDO_OCI_TAIL1`
60314  if test -f "$PDO_OCI_LCS"; then
60315            PDO_OCI_VERSION=`echo $PDO_OCI_LCS | $PHP_PDO_OCI_SED -e 's/.*\.\(.*\)\.1$/\1.1/'`
60316  elif test -f $PDO_OCI_LCS_BASE.9.0; then
60317            PDO_OCI_VERSION=9.0
60318  else
60319    as_fn_error $? "Oracle libclntsh.$SHLIB_SUFFIX_NAME client library not found or its version is lower than 9" "$LINENO" 5
60320  fi
60321  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PDO_OCI_VERSION" >&5
60322printf "%s\n" "$PDO_OCI_VERSION" >&6; }
60323
60324  fi
60325
60326  case $PDO_OCI_VERSION in
60327    7.3|8.0|8.1)
60328      as_fn_error $? "Oracle client libraries < 9 are not supported" "$LINENO" 5
60329      ;;
60330  esac
60331
60332
60333
60334  case clntsh in
60335  c|c_r) ;;
60336  *)
60337    if test "$ext_shared" = "yes"; then
60338        PDO_OCI_SHARED_LIBADD="$PDO_OCI_SHARED_LIBADD -lclntsh"
60339    else
60340
60341
60342  case clntsh in
60343  c|c_r) ;;
60344  *)
60345      LIBS="$LIBS -lclntsh"
60346   ;;
60347  esac
60348
60349
60350    fi
60351   ;;
60352  esac
60353
60354
60355
60356  if test "$PDO_OCI_LIB_DIR" != "/usr/$PHP_LIBDIR" && test "$PDO_OCI_LIB_DIR" != "/usr/lib"; then
60357
60358  if test -z "$PDO_OCI_LIB_DIR" || echo "$PDO_OCI_LIB_DIR" | grep '^/' >/dev/null ; then
60359    ai_p=$PDO_OCI_LIB_DIR
60360  else
60361
60362    ep_dir=`echo $PDO_OCI_LIB_DIR|$SED 's%/*[^/][^/]*/*$%%'`
60363
60364    ep_realdir=`(cd "$ep_dir" && pwd)`
60365    ai_p="$ep_realdir"/`basename "$PDO_OCI_LIB_DIR"`
60366  fi
60367
60368
60369      if test "$ext_shared" = "yes"; then
60370        PDO_OCI_SHARED_LIBADD="-L$ai_p $PDO_OCI_SHARED_LIBADD"
60371        test -n "$ld_runpath_switch" && PDO_OCI_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_OCI_SHARED_LIBADD"
60372      else
60373
60374
60375
60376  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60377
60378  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60379  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60380    eval "LIBPATH$unique=set"
60381
60382    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60383    LDFLAGS="$LDFLAGS -L$ai_p"
60384    PHP_RPATHS="$PHP_RPATHS $ai_p"
60385
60386  fi
60387
60388
60389      fi
60390
60391  fi
60392
60393
60394
60395  save_old_LDFLAGS=$LDFLAGS
60396  ac_stuff="
60397    -L$PDO_OCI_LIB_DIR $PDO_OCI_SHARED_LIBADD
60398  "
60399
60400  save_ext_shared=$ext_shared
60401  ext_shared=yes
60402
60403  for ac_i in $ac_stuff; do
60404    case $ac_i in
60405    -pthread)
60406      if test "$ext_shared" = "yes"; then
60407        LDFLAGS="$LDFLAGS -pthread"
60408      else
60409
60410
60411  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60412
60413  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
60414  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60415    eval "EXTRA_LDFLAGS$unique=set"
60416    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
60417  fi
60418
60419
60420
60421  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60422
60423  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
60424  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60425    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
60426    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
60427  fi
60428
60429      fi
60430    ;;
60431    -l*)
60432      ac_ii=`echo $ac_i|cut -c 3-`
60433
60434
60435  case $ac_ii in
60436  c|c_r) ;;
60437  *)
60438    if test "$ext_shared" = "yes"; then
60439        LDFLAGS="$LDFLAGS -l$ac_ii"
60440    else
60441
60442
60443  case $ac_ii in
60444  c|c_r) ;;
60445  *)
60446      LIBS="$LIBS -l$ac_ii"
60447   ;;
60448  esac
60449
60450
60451    fi
60452   ;;
60453  esac
60454
60455
60456    ;;
60457    -L*)
60458      ac_ii=`echo $ac_i|cut -c 3-`
60459
60460  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
60461
60462  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
60463    ai_p=$ac_ii
60464  else
60465
60466    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
60467
60468    ep_realdir=`(cd "$ep_dir" && pwd)`
60469    ai_p="$ep_realdir"/`basename "$ac_ii"`
60470  fi
60471
60472
60473      if test "$ext_shared" = "yes"; then
60474        LDFLAGS="-L$ai_p $LDFLAGS"
60475        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
60476      else
60477
60478
60479
60480  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60481
60482  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60483  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60484    eval "LIBPATH$unique=set"
60485
60486    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60487    LDFLAGS="$LDFLAGS -L$ai_p"
60488    PHP_RPATHS="$PHP_RPATHS $ai_p"
60489
60490  fi
60491
60492
60493      fi
60494
60495  fi
60496
60497    ;;
60498    esac
60499  done
60500
60501  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OCIEnvCreate in -lclntsh" >&5
60502printf %s "checking for OCIEnvCreate in -lclntsh... " >&6; }
60503if test ${ac_cv_lib_clntsh_OCIEnvCreate+y}
60504then :
60505  printf %s "(cached) " >&6
60506else $as_nop
60507  ac_check_lib_save_LIBS=$LIBS
60508LIBS="-lclntsh  $LIBS"
60509cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60510/* end confdefs.h.  */
60511
60512/* Override any GCC internal prototype to avoid an error.
60513   Use char because int might match the return type of a GCC
60514   builtin and then its argument prototype would still apply.  */
60515char OCIEnvCreate ();
60516int
60517main (void)
60518{
60519return OCIEnvCreate ();
60520  ;
60521  return 0;
60522}
60523_ACEOF
60524if ac_fn_c_try_link "$LINENO"
60525then :
60526  ac_cv_lib_clntsh_OCIEnvCreate=yes
60527else $as_nop
60528  ac_cv_lib_clntsh_OCIEnvCreate=no
60529fi
60530rm -f core conftest.err conftest.$ac_objext conftest.beam \
60531    conftest$ac_exeext conftest.$ac_ext
60532LIBS=$ac_check_lib_save_LIBS
60533fi
60534{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_clntsh_OCIEnvCreate" >&5
60535printf "%s\n" "$ac_cv_lib_clntsh_OCIEnvCreate" >&6; }
60536if test "x$ac_cv_lib_clntsh_OCIEnvCreate" = xyes
60537then :
60538
60539    LDFLAGS=$save_old_LDFLAGS
60540    ext_shared=$save_ext_shared
60541
60542
60543printf "%s\n" "#define HAVE_OCIENVCREATE 1" >>confdefs.h
60544
60545
60546
60547else $as_nop
60548
60549    LDFLAGS=$save_old_LDFLAGS
60550    ext_shared=$save_ext_shared
60551    unset ac_cv_lib_clntsh_OCIEnvCreate
60552
60553
60554fi
60555
60556
60557
60558  save_old_LDFLAGS=$LDFLAGS
60559  ac_stuff="
60560    -L$PDO_OCI_LIB_DIR $PDO_OCI_SHARED_LIBADD
60561  "
60562
60563  save_ext_shared=$ext_shared
60564  ext_shared=yes
60565
60566  for ac_i in $ac_stuff; do
60567    case $ac_i in
60568    -pthread)
60569      if test "$ext_shared" = "yes"; then
60570        LDFLAGS="$LDFLAGS -pthread"
60571      else
60572
60573
60574  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60575
60576  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
60577  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60578    eval "EXTRA_LDFLAGS$unique=set"
60579    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
60580  fi
60581
60582
60583
60584  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60585
60586  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
60587  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60588    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
60589    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
60590  fi
60591
60592      fi
60593    ;;
60594    -l*)
60595      ac_ii=`echo $ac_i|cut -c 3-`
60596
60597
60598  case $ac_ii in
60599  c|c_r) ;;
60600  *)
60601    if test "$ext_shared" = "yes"; then
60602        LDFLAGS="$LDFLAGS -l$ac_ii"
60603    else
60604
60605
60606  case $ac_ii in
60607  c|c_r) ;;
60608  *)
60609      LIBS="$LIBS -l$ac_ii"
60610   ;;
60611  esac
60612
60613
60614    fi
60615   ;;
60616  esac
60617
60618
60619    ;;
60620    -L*)
60621      ac_ii=`echo $ac_i|cut -c 3-`
60622
60623  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
60624
60625  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
60626    ai_p=$ac_ii
60627  else
60628
60629    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
60630
60631    ep_realdir=`(cd "$ep_dir" && pwd)`
60632    ai_p="$ep_realdir"/`basename "$ac_ii"`
60633  fi
60634
60635
60636      if test "$ext_shared" = "yes"; then
60637        LDFLAGS="-L$ai_p $LDFLAGS"
60638        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
60639      else
60640
60641
60642
60643  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60644
60645  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60646  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60647    eval "LIBPATH$unique=set"
60648
60649    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60650    LDFLAGS="$LDFLAGS -L$ai_p"
60651    PHP_RPATHS="$PHP_RPATHS $ai_p"
60652
60653  fi
60654
60655
60656      fi
60657
60658  fi
60659
60660    ;;
60661    esac
60662  done
60663
60664  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OCIEnvNlsCreate in -lclntsh" >&5
60665printf %s "checking for OCIEnvNlsCreate in -lclntsh... " >&6; }
60666if test ${ac_cv_lib_clntsh_OCIEnvNlsCreate+y}
60667then :
60668  printf %s "(cached) " >&6
60669else $as_nop
60670  ac_check_lib_save_LIBS=$LIBS
60671LIBS="-lclntsh  $LIBS"
60672cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60673/* end confdefs.h.  */
60674
60675/* Override any GCC internal prototype to avoid an error.
60676   Use char because int might match the return type of a GCC
60677   builtin and then its argument prototype would still apply.  */
60678char OCIEnvNlsCreate ();
60679int
60680main (void)
60681{
60682return OCIEnvNlsCreate ();
60683  ;
60684  return 0;
60685}
60686_ACEOF
60687if ac_fn_c_try_link "$LINENO"
60688then :
60689  ac_cv_lib_clntsh_OCIEnvNlsCreate=yes
60690else $as_nop
60691  ac_cv_lib_clntsh_OCIEnvNlsCreate=no
60692fi
60693rm -f core conftest.err conftest.$ac_objext conftest.beam \
60694    conftest$ac_exeext conftest.$ac_ext
60695LIBS=$ac_check_lib_save_LIBS
60696fi
60697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_clntsh_OCIEnvNlsCreate" >&5
60698printf "%s\n" "$ac_cv_lib_clntsh_OCIEnvNlsCreate" >&6; }
60699if test "x$ac_cv_lib_clntsh_OCIEnvNlsCreate" = xyes
60700then :
60701
60702    LDFLAGS=$save_old_LDFLAGS
60703    ext_shared=$save_ext_shared
60704
60705
60706printf "%s\n" "#define HAVE_OCIENVNLSCREATE 1" >>confdefs.h
60707
60708
60709
60710else $as_nop
60711
60712    LDFLAGS=$save_old_LDFLAGS
60713    ext_shared=$save_ext_shared
60714    unset ac_cv_lib_clntsh_OCIEnvNlsCreate
60715
60716
60717fi
60718
60719
60720
60721  save_old_LDFLAGS=$LDFLAGS
60722  ac_stuff="
60723    -L$PDO_OCI_LIB_DIR $PDO_OCI_SHARED_LIBADD
60724  "
60725
60726  save_ext_shared=$ext_shared
60727  ext_shared=yes
60728
60729  for ac_i in $ac_stuff; do
60730    case $ac_i in
60731    -pthread)
60732      if test "$ext_shared" = "yes"; then
60733        LDFLAGS="$LDFLAGS -pthread"
60734      else
60735
60736
60737  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60738
60739  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
60740  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60741    eval "EXTRA_LDFLAGS$unique=set"
60742    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
60743  fi
60744
60745
60746
60747  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
60748
60749  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
60750  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60751    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
60752    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
60753  fi
60754
60755      fi
60756    ;;
60757    -l*)
60758      ac_ii=`echo $ac_i|cut -c 3-`
60759
60760
60761  case $ac_ii in
60762  c|c_r) ;;
60763  *)
60764    if test "$ext_shared" = "yes"; then
60765        LDFLAGS="$LDFLAGS -l$ac_ii"
60766    else
60767
60768
60769  case $ac_ii in
60770  c|c_r) ;;
60771  *)
60772      LIBS="$LIBS -l$ac_ii"
60773   ;;
60774  esac
60775
60776
60777    fi
60778   ;;
60779  esac
60780
60781
60782    ;;
60783    -L*)
60784      ac_ii=`echo $ac_i|cut -c 3-`
60785
60786  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
60787
60788  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
60789    ai_p=$ac_ii
60790  else
60791
60792    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
60793
60794    ep_realdir=`(cd "$ep_dir" && pwd)`
60795    ai_p="$ep_realdir"/`basename "$ac_ii"`
60796  fi
60797
60798
60799      if test "$ext_shared" = "yes"; then
60800        LDFLAGS="-L$ai_p $LDFLAGS"
60801        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
60802      else
60803
60804
60805
60806  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
60807
60808  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
60809  if test -n "$unique" && test "`eval $cmd`" = "" ; then
60810    eval "LIBPATH$unique=set"
60811
60812    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
60813    LDFLAGS="$LDFLAGS -L$ai_p"
60814    PHP_RPATHS="$PHP_RPATHS $ai_p"
60815
60816  fi
60817
60818
60819      fi
60820
60821  fi
60822
60823    ;;
60824    esac
60825  done
60826
60827  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OCIStmtFetch2 in -lclntsh" >&5
60828printf %s "checking for OCIStmtFetch2 in -lclntsh... " >&6; }
60829if test ${ac_cv_lib_clntsh_OCIStmtFetch2+y}
60830then :
60831  printf %s "(cached) " >&6
60832else $as_nop
60833  ac_check_lib_save_LIBS=$LIBS
60834LIBS="-lclntsh  $LIBS"
60835cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60836/* end confdefs.h.  */
60837
60838/* Override any GCC internal prototype to avoid an error.
60839   Use char because int might match the return type of a GCC
60840   builtin and then its argument prototype would still apply.  */
60841char OCIStmtFetch2 ();
60842int
60843main (void)
60844{
60845return OCIStmtFetch2 ();
60846  ;
60847  return 0;
60848}
60849_ACEOF
60850if ac_fn_c_try_link "$LINENO"
60851then :
60852  ac_cv_lib_clntsh_OCIStmtFetch2=yes
60853else $as_nop
60854  ac_cv_lib_clntsh_OCIStmtFetch2=no
60855fi
60856rm -f core conftest.err conftest.$ac_objext conftest.beam \
60857    conftest$ac_exeext conftest.$ac_ext
60858LIBS=$ac_check_lib_save_LIBS
60859fi
60860{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_clntsh_OCIStmtFetch2" >&5
60861printf "%s\n" "$ac_cv_lib_clntsh_OCIStmtFetch2" >&6; }
60862if test "x$ac_cv_lib_clntsh_OCIStmtFetch2" = xyes
60863then :
60864
60865    LDFLAGS=$save_old_LDFLAGS
60866    ext_shared=$save_ext_shared
60867
60868
60869printf "%s\n" "#define HAVE_OCISTMTFETCH2 1" >>confdefs.h
60870
60871
60872
60873else $as_nop
60874
60875    LDFLAGS=$save_old_LDFLAGS
60876    ext_shared=$save_ext_shared
60877    unset ac_cv_lib_clntsh_OCIStmtFetch2
60878
60879
60880fi
60881
60882
60883
60884  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
60885printf %s "checking for PDO includes... " >&6; }
60886if test ${pdo_cv_inc_path+y}
60887then :
60888  printf %s "(cached) " >&6
60889else $as_nop
60890
60891    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
60892      pdo_cv_inc_path=$abs_srcdir/ext
60893    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
60894      pdo_cv_inc_path=$abs_srcdir/ext
60895    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
60896      pdo_cv_inc_path=$phpincludedir/ext
60897    fi
60898
60899fi
60900{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
60901printf "%s\n" "$pdo_cv_inc_path" >&6; }
60902  if test -n "$pdo_cv_inc_path"; then
60903:
60904  else
60905as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
60906  fi
60907
60908
60909
60910  ext_builddir=ext/pdo_oci
60911  ext_srcdir=$abs_srcdir/ext/pdo_oci
60912  ext_dir=ext/pdo_oci
60913
60914  ac_extra=`echo "-I$pdo_cv_inc_path"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
60915
60916  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
60917    PHP_PDO_OCI_SHARED=no
60918
60919
60920  case $ext_dir in
60921  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
60922  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
60923  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
60924  esac
60925
60926
60927
60928  b_c_pre=$php_c_pre
60929  b_cxx_pre=$php_cxx_pre
60930  b_c_meta=$php_c_meta
60931  b_cxx_meta=$php_cxx_meta
60932  b_c_post=$php_c_post
60933  b_cxx_post=$php_cxx_post
60934  b_lo=$php_lo
60935
60936
60937  old_IFS=$IFS
60938  for ac_src in pdo_oci.c oci_driver.c oci_statement.c; do
60939
60940      IFS=.
60941      set $ac_src
60942      ac_obj=$1
60943      IFS=$old_IFS
60944
60945      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
60946
60947      case $ac_src in
60948        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
60949        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
60950        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
60951        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
60952      esac
60953
60954      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
60955
60956    cat >>Makefile.objects<<EOF
60957-include $ac_bdir$ac_obj.dep
60958$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
60959	$ac_comp
60960EOF
60961  done
60962
60963
60964    EXT_STATIC="$EXT_STATIC pdo_oci;$ext_dir"
60965    if test "$ext_shared" != "nocli"; then
60966      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_oci;$ext_dir"
60967    fi
60968  else
60969    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
60970      PHP_PDO_OCI_SHARED=yes
60971
60972  case $ext_dir in
60973  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
60974  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
60975  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
60976  esac
60977
60978
60979
60980  b_c_pre=$shared_c_pre
60981  b_cxx_pre=$shared_cxx_pre
60982  b_c_meta=$shared_c_meta
60983  b_cxx_meta=$shared_cxx_meta
60984  b_c_post=$shared_c_post
60985  b_cxx_post=$shared_cxx_post
60986  b_lo=$shared_lo
60987
60988
60989  old_IFS=$IFS
60990  for ac_src in pdo_oci.c oci_driver.c oci_statement.c; do
60991
60992      IFS=.
60993      set $ac_src
60994      ac_obj=$1
60995      IFS=$old_IFS
60996
60997      shared_objects_pdo_oci="$shared_objects_pdo_oci $ac_bdir$ac_obj.lo"
60998
60999      case $ac_src in
61000        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61001        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61002        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61003        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
61004      esac
61005
61006      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
61007
61008    cat >>Makefile.objects<<EOF
61009-include $ac_bdir$ac_obj.dep
61010$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
61011	$ac_comp
61012EOF
61013  done
61014
61015
61016  install_modules="install-modules"
61017  suffix=la
61018
61019  case $host_alias in
61020    *aix*)
61021      additional_flags="-Wl,-G"
61022      ;;
61023  esac
61024
61025  if test "x" = "xyes"; then
61026    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_oci.$suffix"
61027  else
61028    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_oci.$suffix"
61029  fi
61030
61031  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_oci"
61032
61033  cat >>Makefile.objects<<EOF
61034\$(phplibdir)/pdo_oci.$suffix: $ext_builddir/pdo_oci.$suffix
61035	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_oci.$suffix \$(phplibdir)
61036
61037$ext_builddir/pdo_oci.$suffix: \$(shared_objects_pdo_oci) \$(PDO_OCI_SHARED_DEPENDENCIES)
61038	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_oci) \$(PDO_OCI_SHARED_LIBADD)
61039
61040EOF
61041
61042
61043printf "%s\n" "#define COMPILE_DL_PDO_OCI 1" >>confdefs.h
61044
61045    fi
61046  fi
61047
61048  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
61049    PHP_PDO_OCI_SHARED=no
61050    case "$PHP_SAPI" in
61051      cgi|embed|phpdbg)
61052
61053
61054  case $ext_dir in
61055  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
61056  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
61057  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
61058  esac
61059
61060
61061
61062  b_c_pre=$php_c_pre
61063  b_cxx_pre=$php_cxx_pre
61064  b_c_meta=$php_c_meta
61065  b_cxx_meta=$php_cxx_meta
61066  b_c_post=$php_c_post
61067  b_cxx_post=$php_cxx_post
61068  b_lo=$php_lo
61069
61070
61071  old_IFS=$IFS
61072  for ac_src in pdo_oci.c oci_driver.c oci_statement.c; do
61073
61074      IFS=.
61075      set $ac_src
61076      ac_obj=$1
61077      IFS=$old_IFS
61078
61079      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
61080
61081      case $ac_src in
61082        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61083        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61084        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61085        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
61086      esac
61087
61088      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
61089
61090    cat >>Makefile.objects<<EOF
61091-include $ac_bdir$ac_obj.dep
61092$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
61093	$ac_comp
61094EOF
61095  done
61096
61097
61098        EXT_STATIC="$EXT_STATIC pdo_oci;$ext_dir"
61099        ;;
61100      *)
61101
61102
61103  case $ext_dir in
61104  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
61105  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
61106  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
61107  esac
61108
61109
61110
61111  b_c_pre=$php_c_pre
61112  b_cxx_pre=$php_cxx_pre
61113  b_c_meta=$php_c_meta
61114  b_cxx_meta=$php_cxx_meta
61115  b_c_post=$php_c_post
61116  b_cxx_post=$php_cxx_post
61117  b_lo=$php_lo
61118
61119
61120  old_IFS=$IFS
61121  for ac_src in pdo_oci.c oci_driver.c oci_statement.c; do
61122
61123      IFS=.
61124      set $ac_src
61125      ac_obj=$1
61126      IFS=$old_IFS
61127
61128      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
61129
61130      case $ac_src in
61131        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61132        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61133        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
61134        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
61135      esac
61136
61137      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
61138
61139    cat >>Makefile.objects<<EOF
61140-include $ac_bdir$ac_obj.dep
61141$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
61142	$ac_comp
61143EOF
61144  done
61145
61146
61147        ;;
61148    esac
61149    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_oci;$ext_dir"
61150  fi
61151
61152
61153    BUILD_DIR="$BUILD_DIR $ext_builddir"
61154
61155
61156
61157  if test "$ext_builddir" = "."; then
61158    PHP_PECL_EXTENSION=pdo_oci
61159
61160  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
61161
61162  fi
61163
61164
61165
61166
61167
61168  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_OCI_SHARED_LIBADD"
61169
61170
61171
61172
61173
61174  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_OCI_DIR"
61175
61176
61177
61178
61179
61180  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_OCI_VERSION"
61181
61182
61183
61184
61185  am_i_shared=$PHP_PDO_OCI_SHARED
61186  is_it_shared=$PHP_PDO_SHARED
61187  is_it_enabled=$PHP_PDO
61188  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
61189    as_fn_error $? "
61190You've configured extension pdo_oci to build statically, but it
61191depends on extension pdo, which you've configured to build shared.
61192You either need to build pdo_oci shared or build pdo statically for the
61193build to be successful.
61194" "$LINENO" 5
61195  fi
61196  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
61197    as_fn_error $? "
61198You've configured extension pdo_oci, which depends on extension pdo,
61199but you've either not enabled pdo, or have disabled it.
61200" "$LINENO" 5
61201  fi
61202
61203
61204
61205printf "%s\n" "#define PHP_PDO_OCI_CLIENT_VERSION \"$PDO_OCI_VERSION\"" >>confdefs.h
61206
61207fi
61208
61209
61210
61211
61212
61213
61214
61215php_with_pdo_odbc=no
61216
61217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ODBC v3 support for PDO" >&5
61218printf %s "checking for ODBC v3 support for PDO... " >&6; }
61219
61220# Check whether --with-pdo-odbc was given.
61221if test ${with_pdo_odbc+y}
61222then :
61223  withval=$with_pdo_odbc; PHP_PDO_ODBC=$withval
61224else $as_nop
61225
61226  PHP_PDO_ODBC=no
61227  test "$PHP_ENABLE_ALL" && PHP_PDO_ODBC=$PHP_ENABLE_ALL
61228
61229fi
61230
61231
61232
61233ext_output="yes, shared"
61234ext_shared=yes
61235case $PHP_PDO_ODBC in
61236shared,*)
61237  PHP_PDO_ODBC=`echo "$PHP_PDO_ODBC"|$SED 's/^shared,//'`
61238  ;;
61239shared)
61240  PHP_PDO_ODBC=yes
61241  ;;
61242no)
61243  ext_output=no
61244  ext_shared=no
61245  ;;
61246*)
61247  ext_output=yes
61248  ext_shared=no
61249  ;;
61250esac
61251
61252
61253
61254{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
61255printf "%s\n" "$ext_output" >&6; }
61256
61257
61258
61259
61260
61261
61262if test "$PHP_PDO_ODBC" != "no"; then
61263
61264  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
61265    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
61266  fi
61267
61268
61269  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
61270printf %s "checking for PDO includes... " >&6; }
61271if test ${pdo_cv_inc_path+y}
61272then :
61273  printf %s "(cached) " >&6
61274else $as_nop
61275
61276    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
61277      pdo_cv_inc_path=$abs_srcdir/ext
61278    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
61279      pdo_cv_inc_path=$abs_srcdir/ext
61280    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
61281      pdo_cv_inc_path=$phpincludedir/ext
61282    fi
61283
61284fi
61285{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
61286printf "%s\n" "$pdo_cv_inc_path" >&6; }
61287  if test -n "$pdo_cv_inc_path"; then
61288:
61289  else
61290as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
61291  fi
61292
61293
61294  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for selected PDO ODBC flavour" >&5
61295printf %s "checking for selected PDO ODBC flavour... " >&6; }
61296
61297  pdo_odbc_flavour="`echo $PHP_PDO_ODBC | cut -d, -f1`"
61298  pdo_odbc_dir="`echo $PHP_PDO_ODBC | cut -d, -f2`"
61299
61300  if test "$pdo_odbc_dir" = "$PHP_PDO_ODBC" ; then
61301    pdo_odbc_dir=
61302  fi
61303
61304  case $pdo_odbc_flavour in
61305    ibm-db2)
61306        pdo_odbc_def_libdir=/home/db2inst1/sqllib/lib
61307        pdo_odbc_def_incdir=/home/db2inst1/sqllib/include
61308        pdo_odbc_def_lib=db2
61309        ;;
61310
61311    iODBC|iodbc)
61312        pdo_odbc_def_libdir=/usr/local/$PHP_LIBDIR
61313        pdo_odbc_def_incdir=/usr/local/include
61314        pdo_odbc_def_lib=iodbc
61315        ;;
61316
61317    unixODBC|unixodbc)
61318        pdo_odbc_def_libdir=/usr/local/$PHP_LIBDIR
61319        pdo_odbc_def_incdir=/usr/local/include
61320        pdo_odbc_def_lib=odbc
61321        ;;
61322
61323    ODBCRouter|odbcrouter)
61324        pdo_odbc_def_libdir=/usr/$PHP_LIBDIR
61325        pdo_odbc_def_incdir=/usr/include
61326        pdo_odbc_def_lib=odbcsdk
61327        ;;
61328
61329    generic)
61330        pdo_odbc_def_lib="`echo $PHP_PDO_ODBC | cut -d, -f3`"
61331        pdo_odbc_def_ldflags="`echo $PHP_PDO_ODBC | cut -d, -f4`"
61332        pdo_odbc_def_cflags="`echo $PHP_PDO_ODBC | cut -d, -f5`"
61333        pdo_odbc_flavour="generic-$pdo_odbc_def_lib"
61334        ;;
61335
61336      *)
61337        as_fn_error $? "Unknown ODBC flavour $pdo_odbc_flavour
61338  The include and lib dirs are looked for under 'dir'. The 'flavour' can be one
61339  of: ibm-db2, iODBC, unixODBC, generic. If ',dir' part is omitted, default for
61340  the flavour you have selected will be used. e.g.: --with-pdo-odbc=unixODBC
61341  will check for unixODBC under /usr/local. You may attempt to use an otherwise
61342  unsupported driver using the 'generic' flavour. The syntax for generic ODBC
61343  support is: --with-pdo-odbc=generic,dir,libname,ldflags,cflags. When built as
61344  'shared' the extension filename is always pdo_odbc.so" "$LINENO" 5
61345        ;;
61346  esac
61347
61348  if test -n "$pdo_odbc_dir"; then
61349    PDO_ODBC_INCDIR="$pdo_odbc_dir/include"
61350    PDO_ODBC_LIBDIR="$pdo_odbc_dir/$PHP_LIBDIR"
61351  else
61352    PDO_ODBC_INCDIR="$pdo_odbc_def_incdir"
61353    PDO_ODBC_LIBDIR="$pdo_odbc_def_libdir"
61354  fi
61355
61356  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_odbc_flavour
61357          libs       $PDO_ODBC_LIBDIR,
61358          headers    $PDO_ODBC_INCDIR" >&5
61359printf "%s\n" "$pdo_odbc_flavour
61360          libs       $PDO_ODBC_LIBDIR,
61361          headers    $PDO_ODBC_INCDIR" >&6; }
61362
61363  if test ! -d "$PDO_ODBC_LIBDIR" ; then
61364    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: library dir $PDO_ODBC_LIBDIR does not exist" >&5
61365printf "%s\n" "$as_me: WARNING: library dir $PDO_ODBC_LIBDIR does not exist" >&2;}
61366  fi
61367
61368
61369  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for odbc.h in $PDO_ODBC_INCDIR" >&5
61370printf %s "checking for odbc.h in $PDO_ODBC_INCDIR... " >&6; }
61371  if test -f "$PDO_ODBC_INCDIR/odbc.h"; then
61372    php_pdo_have_header=yes
61373
61374printf "%s\n" "#define HAVE_ODBC_H 1" >>confdefs.h
61375
61376    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61377printf "%s\n" "yes" >&6; }
61378  else
61379    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61380printf "%s\n" "no" >&6; }
61381  fi
61382
61383
61384  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for odbcsdk.h in $PDO_ODBC_INCDIR" >&5
61385printf %s "checking for odbcsdk.h in $PDO_ODBC_INCDIR... " >&6; }
61386  if test -f "$PDO_ODBC_INCDIR/odbcsdk.h"; then
61387    php_pdo_have_header=yes
61388
61389printf "%s\n" "#define HAVE_ODBCSDK_H 1" >>confdefs.h
61390
61391    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61392printf "%s\n" "yes" >&6; }
61393  else
61394    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61395printf "%s\n" "no" >&6; }
61396  fi
61397
61398
61399  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iodbc.h in $PDO_ODBC_INCDIR" >&5
61400printf %s "checking for iodbc.h in $PDO_ODBC_INCDIR... " >&6; }
61401  if test -f "$PDO_ODBC_INCDIR/iodbc.h"; then
61402    php_pdo_have_header=yes
61403
61404printf "%s\n" "#define HAVE_IODBC_H 1" >>confdefs.h
61405
61406    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61407printf "%s\n" "yes" >&6; }
61408  else
61409    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61410printf "%s\n" "no" >&6; }
61411  fi
61412
61413
61414  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlunix.h in $PDO_ODBC_INCDIR" >&5
61415printf %s "checking for sqlunix.h in $PDO_ODBC_INCDIR... " >&6; }
61416  if test -f "$PDO_ODBC_INCDIR/sqlunix.h"; then
61417    php_pdo_have_header=yes
61418
61419printf "%s\n" "#define HAVE_SQLUNIX_H 1" >>confdefs.h
61420
61421    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61422printf "%s\n" "yes" >&6; }
61423  else
61424    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61425printf "%s\n" "no" >&6; }
61426  fi
61427
61428
61429  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqltypes.h in $PDO_ODBC_INCDIR" >&5
61430printf %s "checking for sqltypes.h in $PDO_ODBC_INCDIR... " >&6; }
61431  if test -f "$PDO_ODBC_INCDIR/sqltypes.h"; then
61432    php_pdo_have_header=yes
61433
61434printf "%s\n" "#define HAVE_SQLTYPES_H 1" >>confdefs.h
61435
61436    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61437printf "%s\n" "yes" >&6; }
61438  else
61439    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61440printf "%s\n" "no" >&6; }
61441  fi
61442
61443
61444  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlucode.h in $PDO_ODBC_INCDIR" >&5
61445printf %s "checking for sqlucode.h in $PDO_ODBC_INCDIR... " >&6; }
61446  if test -f "$PDO_ODBC_INCDIR/sqlucode.h"; then
61447    php_pdo_have_header=yes
61448
61449printf "%s\n" "#define HAVE_SQLUCODE_H 1" >>confdefs.h
61450
61451    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61452printf "%s\n" "yes" >&6; }
61453  else
61454    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61455printf "%s\n" "no" >&6; }
61456  fi
61457
61458
61459  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sql.h in $PDO_ODBC_INCDIR" >&5
61460printf %s "checking for sql.h in $PDO_ODBC_INCDIR... " >&6; }
61461  if test -f "$PDO_ODBC_INCDIR/sql.h"; then
61462    php_pdo_have_header=yes
61463
61464printf "%s\n" "#define HAVE_SQL_H 1" >>confdefs.h
61465
61466    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61467printf "%s\n" "yes" >&6; }
61468  else
61469    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61470printf "%s\n" "no" >&6; }
61471  fi
61472
61473
61474  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for isql.h in $PDO_ODBC_INCDIR" >&5
61475printf %s "checking for isql.h in $PDO_ODBC_INCDIR... " >&6; }
61476  if test -f "$PDO_ODBC_INCDIR/isql.h"; then
61477    php_pdo_have_header=yes
61478
61479printf "%s\n" "#define HAVE_ISQL_H 1" >>confdefs.h
61480
61481    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61482printf "%s\n" "yes" >&6; }
61483  else
61484    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61485printf "%s\n" "no" >&6; }
61486  fi
61487
61488
61489  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlext.h in $PDO_ODBC_INCDIR" >&5
61490printf %s "checking for sqlext.h in $PDO_ODBC_INCDIR... " >&6; }
61491  if test -f "$PDO_ODBC_INCDIR/sqlext.h"; then
61492    php_pdo_have_header=yes
61493
61494printf "%s\n" "#define HAVE_SQLEXT_H 1" >>confdefs.h
61495
61496    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61497printf "%s\n" "yes" >&6; }
61498  else
61499    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61500printf "%s\n" "no" >&6; }
61501  fi
61502
61503
61504  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for isqlext.h in $PDO_ODBC_INCDIR" >&5
61505printf %s "checking for isqlext.h in $PDO_ODBC_INCDIR... " >&6; }
61506  if test -f "$PDO_ODBC_INCDIR/isqlext.h"; then
61507    php_pdo_have_header=yes
61508
61509printf "%s\n" "#define HAVE_ISQLEXT_H 1" >>confdefs.h
61510
61511    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61512printf "%s\n" "yes" >&6; }
61513  else
61514    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61515printf "%s\n" "no" >&6; }
61516  fi
61517
61518
61519  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for udbcext.h in $PDO_ODBC_INCDIR" >&5
61520printf %s "checking for udbcext.h in $PDO_ODBC_INCDIR... " >&6; }
61521  if test -f "$PDO_ODBC_INCDIR/udbcext.h"; then
61522    php_pdo_have_header=yes
61523
61524printf "%s\n" "#define HAVE_UDBCEXT_H 1" >>confdefs.h
61525
61526    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61527printf "%s\n" "yes" >&6; }
61528  else
61529    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61530printf "%s\n" "no" >&6; }
61531  fi
61532
61533
61534  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlcli1.h in $PDO_ODBC_INCDIR" >&5
61535printf %s "checking for sqlcli1.h in $PDO_ODBC_INCDIR... " >&6; }
61536  if test -f "$PDO_ODBC_INCDIR/sqlcli1.h"; then
61537    php_pdo_have_header=yes
61538
61539printf "%s\n" "#define HAVE_SQLCLI1_H 1" >>confdefs.h
61540
61541    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61542printf "%s\n" "yes" >&6; }
61543  else
61544    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61545printf "%s\n" "no" >&6; }
61546  fi
61547
61548
61549  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LibraryManager.h in $PDO_ODBC_INCDIR" >&5
61550printf %s "checking for LibraryManager.h in $PDO_ODBC_INCDIR... " >&6; }
61551  if test -f "$PDO_ODBC_INCDIR/LibraryManager.h"; then
61552    php_pdo_have_header=yes
61553
61554printf "%s\n" "#define HAVE_LIBRARYMANAGER_H 1" >>confdefs.h
61555
61556    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61557printf "%s\n" "yes" >&6; }
61558  else
61559    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61560printf "%s\n" "no" >&6; }
61561  fi
61562
61563
61564  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cli0core.h in $PDO_ODBC_INCDIR" >&5
61565printf %s "checking for cli0core.h in $PDO_ODBC_INCDIR... " >&6; }
61566  if test -f "$PDO_ODBC_INCDIR/cli0core.h"; then
61567    php_pdo_have_header=yes
61568
61569printf "%s\n" "#define HAVE_CLI0CORE_H 1" >>confdefs.h
61570
61571    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61572printf "%s\n" "yes" >&6; }
61573  else
61574    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61575printf "%s\n" "no" >&6; }
61576  fi
61577
61578
61579  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cli0ext.h in $PDO_ODBC_INCDIR" >&5
61580printf %s "checking for cli0ext.h in $PDO_ODBC_INCDIR... " >&6; }
61581  if test -f "$PDO_ODBC_INCDIR/cli0ext.h"; then
61582    php_pdo_have_header=yes
61583
61584printf "%s\n" "#define HAVE_CLI0EXT_H 1" >>confdefs.h
61585
61586    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61587printf "%s\n" "yes" >&6; }
61588  else
61589    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61590printf "%s\n" "no" >&6; }
61591  fi
61592
61593
61594  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cli0cli.h in $PDO_ODBC_INCDIR" >&5
61595printf %s "checking for cli0cli.h in $PDO_ODBC_INCDIR... " >&6; }
61596  if test -f "$PDO_ODBC_INCDIR/cli0cli.h"; then
61597    php_pdo_have_header=yes
61598
61599printf "%s\n" "#define HAVE_CLI0CLI_H 1" >>confdefs.h
61600
61601    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61602printf "%s\n" "yes" >&6; }
61603  else
61604    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61605printf "%s\n" "no" >&6; }
61606  fi
61607
61608
61609  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cli0defs.h in $PDO_ODBC_INCDIR" >&5
61610printf %s "checking for cli0defs.h in $PDO_ODBC_INCDIR... " >&6; }
61611  if test -f "$PDO_ODBC_INCDIR/cli0defs.h"; then
61612    php_pdo_have_header=yes
61613
61614printf "%s\n" "#define HAVE_CLI0DEFS_H 1" >>confdefs.h
61615
61616    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61617printf "%s\n" "yes" >&6; }
61618  else
61619    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61620printf "%s\n" "no" >&6; }
61621  fi
61622
61623
61624  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cli0env.h in $PDO_ODBC_INCDIR" >&5
61625printf %s "checking for cli0env.h in $PDO_ODBC_INCDIR... " >&6; }
61626  if test -f "$PDO_ODBC_INCDIR/cli0env.h"; then
61627    php_pdo_have_header=yes
61628
61629printf "%s\n" "#define HAVE_CLI0ENV_H 1" >>confdefs.h
61630
61631    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
61632printf "%s\n" "yes" >&6; }
61633  else
61634    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
61635printf "%s\n" "no" >&6; }
61636  fi
61637
61638
61639  if test "$php_pdo_have_header" != "yes"; then
61640    as_fn_error $? "Cannot find header file(s) for pdo_odbc" "$LINENO" 5
61641  fi
61642
61643  PDO_ODBC_INCLUDE="$pdo_odbc_def_cflags -I$PDO_ODBC_INCDIR -DPDO_ODBC_TYPE=\\\"$pdo_odbc_flavour\\\""
61644  PDO_ODBC_LDFLAGS="$pdo_odbc_def_ldflags -L$PDO_ODBC_LIBDIR -l$pdo_odbc_def_lib"
61645
61646
61647  for ac_i in $PDO_ODBC_LDFLAGS; do
61648    case $ac_i in
61649    -pthread)
61650      if test "$ext_shared" = "yes"; then
61651        PDO_ODBC_SHARED_LIBADD="$PDO_ODBC_SHARED_LIBADD -pthread"
61652      else
61653
61654
61655  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61656
61657  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
61658  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61659    eval "EXTRA_LDFLAGS$unique=set"
61660    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
61661  fi
61662
61663
61664
61665  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61666
61667  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
61668  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61669    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
61670    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
61671  fi
61672
61673      fi
61674    ;;
61675    -l*)
61676      ac_ii=`echo $ac_i|cut -c 3-`
61677
61678
61679  case $ac_ii in
61680  c|c_r) ;;
61681  *)
61682    if test "$ext_shared" = "yes"; then
61683        PDO_ODBC_SHARED_LIBADD="$PDO_ODBC_SHARED_LIBADD -l$ac_ii"
61684    else
61685
61686
61687  case $ac_ii in
61688  c|c_r) ;;
61689  *)
61690      LIBS="$LIBS -l$ac_ii"
61691   ;;
61692  esac
61693
61694
61695    fi
61696   ;;
61697  esac
61698
61699
61700    ;;
61701    -L*)
61702      ac_ii=`echo $ac_i|cut -c 3-`
61703
61704  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
61705
61706  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
61707    ai_p=$ac_ii
61708  else
61709
61710    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
61711
61712    ep_realdir=`(cd "$ep_dir" && pwd)`
61713    ai_p="$ep_realdir"/`basename "$ac_ii"`
61714  fi
61715
61716
61717      if test "$ext_shared" = "yes"; then
61718        PDO_ODBC_SHARED_LIBADD="-L$ai_p $PDO_ODBC_SHARED_LIBADD"
61719        test -n "$ld_runpath_switch" && PDO_ODBC_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_ODBC_SHARED_LIBADD"
61720      else
61721
61722
61723
61724  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
61725
61726  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
61727  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61728    eval "LIBPATH$unique=set"
61729
61730    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
61731    LDFLAGS="$LDFLAGS -L$ai_p"
61732    PHP_RPATHS="$PHP_RPATHS $ai_p"
61733
61734  fi
61735
61736
61737      fi
61738
61739  fi
61740
61741    ;;
61742    esac
61743  done
61744
61745
61746
61747  save_old_LDFLAGS=$LDFLAGS
61748  ac_stuff="$PDO_ODBC_LDFLAGS"
61749
61750  save_ext_shared=$ext_shared
61751  ext_shared=yes
61752
61753  for ac_i in $ac_stuff; do
61754    case $ac_i in
61755    -pthread)
61756      if test "$ext_shared" = "yes"; then
61757        LDFLAGS="$LDFLAGS -pthread"
61758      else
61759
61760
61761  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61762
61763  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
61764  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61765    eval "EXTRA_LDFLAGS$unique=set"
61766    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
61767  fi
61768
61769
61770
61771  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61772
61773  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
61774  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61775    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
61776    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
61777  fi
61778
61779      fi
61780    ;;
61781    -l*)
61782      ac_ii=`echo $ac_i|cut -c 3-`
61783
61784
61785  case $ac_ii in
61786  c|c_r) ;;
61787  *)
61788    if test "$ext_shared" = "yes"; then
61789        LDFLAGS="$LDFLAGS -l$ac_ii"
61790    else
61791
61792
61793  case $ac_ii in
61794  c|c_r) ;;
61795  *)
61796      LIBS="$LIBS -l$ac_ii"
61797   ;;
61798  esac
61799
61800
61801    fi
61802   ;;
61803  esac
61804
61805
61806    ;;
61807    -L*)
61808      ac_ii=`echo $ac_i|cut -c 3-`
61809
61810  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
61811
61812  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
61813    ai_p=$ac_ii
61814  else
61815
61816    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
61817
61818    ep_realdir=`(cd "$ep_dir" && pwd)`
61819    ai_p="$ep_realdir"/`basename "$ac_ii"`
61820  fi
61821
61822
61823      if test "$ext_shared" = "yes"; then
61824        LDFLAGS="-L$ai_p $LDFLAGS"
61825        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
61826      else
61827
61828
61829
61830  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
61831
61832  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
61833  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61834    eval "LIBPATH$unique=set"
61835
61836    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
61837    LDFLAGS="$LDFLAGS -L$ai_p"
61838    PHP_RPATHS="$PHP_RPATHS $ai_p"
61839
61840  fi
61841
61842
61843      fi
61844
61845  fi
61846
61847    ;;
61848    esac
61849  done
61850
61851  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$pdo_odbc_def_lib""_SQLBindCol" | $as_tr_sh`
61852{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SQLBindCol in -l$pdo_odbc_def_lib" >&5
61853printf %s "checking for SQLBindCol in -l$pdo_odbc_def_lib... " >&6; }
61854if eval test \${$as_ac_Lib+y}
61855then :
61856  printf %s "(cached) " >&6
61857else $as_nop
61858  ac_check_lib_save_LIBS=$LIBS
61859LIBS="-l$pdo_odbc_def_lib  $LIBS"
61860cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61861/* end confdefs.h.  */
61862
61863/* Override any GCC internal prototype to avoid an error.
61864   Use char because int might match the return type of a GCC
61865   builtin and then its argument prototype would still apply.  */
61866char SQLBindCol ();
61867int
61868main (void)
61869{
61870return SQLBindCol ();
61871  ;
61872  return 0;
61873}
61874_ACEOF
61875if ac_fn_c_try_link "$LINENO"
61876then :
61877  eval "$as_ac_Lib=yes"
61878else $as_nop
61879  eval "$as_ac_Lib=no"
61880fi
61881rm -f core conftest.err conftest.$ac_objext conftest.beam \
61882    conftest$ac_exeext conftest.$ac_ext
61883LIBS=$ac_check_lib_save_LIBS
61884fi
61885eval ac_res=\$$as_ac_Lib
61886	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
61887printf "%s\n" "$ac_res" >&6; }
61888if eval test \"x\$"$as_ac_Lib"\" = x"yes"
61889then :
61890
61891    LDFLAGS=$save_old_LDFLAGS
61892    ext_shared=$save_ext_shared
61893
61894
61895  save_old_LDFLAGS=$LDFLAGS
61896  ac_stuff="$PDO_ODBC_LDFLAGS"
61897
61898  save_ext_shared=$ext_shared
61899  ext_shared=yes
61900
61901  for ac_i in $ac_stuff; do
61902    case $ac_i in
61903    -pthread)
61904      if test "$ext_shared" = "yes"; then
61905        LDFLAGS="$LDFLAGS -pthread"
61906      else
61907
61908
61909  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61910
61911  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
61912  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61913    eval "EXTRA_LDFLAGS$unique=set"
61914    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
61915  fi
61916
61917
61918
61919  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
61920
61921  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
61922  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61923    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
61924    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
61925  fi
61926
61927      fi
61928    ;;
61929    -l*)
61930      ac_ii=`echo $ac_i|cut -c 3-`
61931
61932
61933  case $ac_ii in
61934  c|c_r) ;;
61935  *)
61936    if test "$ext_shared" = "yes"; then
61937        LDFLAGS="$LDFLAGS -l$ac_ii"
61938    else
61939
61940
61941  case $ac_ii in
61942  c|c_r) ;;
61943  *)
61944      LIBS="$LIBS -l$ac_ii"
61945   ;;
61946  esac
61947
61948
61949    fi
61950   ;;
61951  esac
61952
61953
61954    ;;
61955    -L*)
61956      ac_ii=`echo $ac_i|cut -c 3-`
61957
61958  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
61959
61960  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
61961    ai_p=$ac_ii
61962  else
61963
61964    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
61965
61966    ep_realdir=`(cd "$ep_dir" && pwd)`
61967    ai_p="$ep_realdir"/`basename "$ac_ii"`
61968  fi
61969
61970
61971      if test "$ext_shared" = "yes"; then
61972        LDFLAGS="-L$ai_p $LDFLAGS"
61973        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
61974      else
61975
61976
61977
61978  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
61979
61980  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
61981  if test -n "$unique" && test "`eval $cmd`" = "" ; then
61982    eval "LIBPATH$unique=set"
61983
61984    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
61985    LDFLAGS="$LDFLAGS -L$ai_p"
61986    PHP_RPATHS="$PHP_RPATHS $ai_p"
61987
61988  fi
61989
61990
61991      fi
61992
61993  fi
61994
61995    ;;
61996    esac
61997  done
61998
61999  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$pdo_odbc_def_lib""_SQLAllocHandle" | $as_tr_sh`
62000{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SQLAllocHandle in -l$pdo_odbc_def_lib" >&5
62001printf %s "checking for SQLAllocHandle in -l$pdo_odbc_def_lib... " >&6; }
62002if eval test \${$as_ac_Lib+y}
62003then :
62004  printf %s "(cached) " >&6
62005else $as_nop
62006  ac_check_lib_save_LIBS=$LIBS
62007LIBS="-l$pdo_odbc_def_lib  $LIBS"
62008cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62009/* end confdefs.h.  */
62010
62011/* Override any GCC internal prototype to avoid an error.
62012   Use char because int might match the return type of a GCC
62013   builtin and then its argument prototype would still apply.  */
62014char SQLAllocHandle ();
62015int
62016main (void)
62017{
62018return SQLAllocHandle ();
62019  ;
62020  return 0;
62021}
62022_ACEOF
62023if ac_fn_c_try_link "$LINENO"
62024then :
62025  eval "$as_ac_Lib=yes"
62026else $as_nop
62027  eval "$as_ac_Lib=no"
62028fi
62029rm -f core conftest.err conftest.$ac_objext conftest.beam \
62030    conftest$ac_exeext conftest.$ac_ext
62031LIBS=$ac_check_lib_save_LIBS
62032fi
62033eval ac_res=\$$as_ac_Lib
62034	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
62035printf "%s\n" "$ac_res" >&6; }
62036if eval test \"x\$"$as_ac_Lib"\" = x"yes"
62037then :
62038
62039    LDFLAGS=$save_old_LDFLAGS
62040    ext_shared=$save_ext_shared
62041
62042
62043else $as_nop
62044
62045    LDFLAGS=$save_old_LDFLAGS
62046    ext_shared=$save_ext_shared
62047    unset ac_cv_lib_$pdo_odbc_def_lib_SQLAllocHandle
62048
62049      as_fn_error $? "
62050Your ODBC library does not appear to be ODBC 3 compatible.
62051You should consider using iODBC or unixODBC instead, and loading your
62052libraries as a driver in that environment; it will emulate the
62053functions required for PDO support.
62054" "$LINENO" 5
62055
62056fi
62057
62058
62059
62060else $as_nop
62061
62062    LDFLAGS=$save_old_LDFLAGS
62063    ext_shared=$save_ext_shared
62064    unset ac_cv_lib_$pdo_odbc_def_lib_SQLBindCol
62065
62066    as_fn_error $? "Your ODBC library does not exist or there was an error. Check config.log for more information" "$LINENO" 5
62067
62068
62069fi
62070
62071
62072
62073  ext_builddir=ext/pdo_odbc
62074  ext_srcdir=$abs_srcdir/ext/pdo_odbc
62075  ext_dir=ext/pdo_odbc
62076
62077  ac_extra=`echo "-I$pdo_cv_inc_path $PDO_ODBC_INCLUDE"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
62078
62079  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
62080    PHP_PDO_ODBC_SHARED=no
62081
62082
62083  case $ext_dir in
62084  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62085  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62086  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62087  esac
62088
62089
62090
62091  b_c_pre=$php_c_pre
62092  b_cxx_pre=$php_cxx_pre
62093  b_c_meta=$php_c_meta
62094  b_cxx_meta=$php_cxx_meta
62095  b_c_post=$php_c_post
62096  b_cxx_post=$php_cxx_post
62097  b_lo=$php_lo
62098
62099
62100  old_IFS=$IFS
62101  for ac_src in pdo_odbc.c odbc_driver.c odbc_stmt.c; do
62102
62103      IFS=.
62104      set $ac_src
62105      ac_obj=$1
62106      IFS=$old_IFS
62107
62108      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62109
62110      case $ac_src in
62111        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62112        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62113        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62114        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62115      esac
62116
62117      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62118
62119    cat >>Makefile.objects<<EOF
62120-include $ac_bdir$ac_obj.dep
62121$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62122	$ac_comp
62123EOF
62124  done
62125
62126
62127    EXT_STATIC="$EXT_STATIC pdo_odbc;$ext_dir"
62128    if test "$ext_shared" != "nocli"; then
62129      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_odbc;$ext_dir"
62130    fi
62131  else
62132    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
62133      PHP_PDO_ODBC_SHARED=yes
62134
62135  case $ext_dir in
62136  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62137  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62138  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62139  esac
62140
62141
62142
62143  b_c_pre=$shared_c_pre
62144  b_cxx_pre=$shared_cxx_pre
62145  b_c_meta=$shared_c_meta
62146  b_cxx_meta=$shared_cxx_meta
62147  b_c_post=$shared_c_post
62148  b_cxx_post=$shared_cxx_post
62149  b_lo=$shared_lo
62150
62151
62152  old_IFS=$IFS
62153  for ac_src in pdo_odbc.c odbc_driver.c odbc_stmt.c; do
62154
62155      IFS=.
62156      set $ac_src
62157      ac_obj=$1
62158      IFS=$old_IFS
62159
62160      shared_objects_pdo_odbc="$shared_objects_pdo_odbc $ac_bdir$ac_obj.lo"
62161
62162      case $ac_src in
62163        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62164        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62165        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62166        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62167      esac
62168
62169      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62170
62171    cat >>Makefile.objects<<EOF
62172-include $ac_bdir$ac_obj.dep
62173$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62174	$ac_comp
62175EOF
62176  done
62177
62178
62179  install_modules="install-modules"
62180  suffix=la
62181
62182  case $host_alias in
62183    *aix*)
62184      additional_flags="-Wl,-G"
62185      ;;
62186  esac
62187
62188  if test "x" = "xyes"; then
62189    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_odbc.$suffix"
62190  else
62191    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_odbc.$suffix"
62192  fi
62193
62194  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_odbc"
62195
62196  cat >>Makefile.objects<<EOF
62197\$(phplibdir)/pdo_odbc.$suffix: $ext_builddir/pdo_odbc.$suffix
62198	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_odbc.$suffix \$(phplibdir)
62199
62200$ext_builddir/pdo_odbc.$suffix: \$(shared_objects_pdo_odbc) \$(PDO_ODBC_SHARED_DEPENDENCIES)
62201	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_odbc) \$(PDO_ODBC_SHARED_LIBADD)
62202
62203EOF
62204
62205
62206printf "%s\n" "#define COMPILE_DL_PDO_ODBC 1" >>confdefs.h
62207
62208    fi
62209  fi
62210
62211  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
62212    PHP_PDO_ODBC_SHARED=no
62213    case "$PHP_SAPI" in
62214      cgi|embed|phpdbg)
62215
62216
62217  case $ext_dir in
62218  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62219  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62220  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62221  esac
62222
62223
62224
62225  b_c_pre=$php_c_pre
62226  b_cxx_pre=$php_cxx_pre
62227  b_c_meta=$php_c_meta
62228  b_cxx_meta=$php_cxx_meta
62229  b_c_post=$php_c_post
62230  b_cxx_post=$php_cxx_post
62231  b_lo=$php_lo
62232
62233
62234  old_IFS=$IFS
62235  for ac_src in pdo_odbc.c odbc_driver.c odbc_stmt.c; do
62236
62237      IFS=.
62238      set $ac_src
62239      ac_obj=$1
62240      IFS=$old_IFS
62241
62242      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62243
62244      case $ac_src in
62245        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62246        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62247        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62248        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62249      esac
62250
62251      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62252
62253    cat >>Makefile.objects<<EOF
62254-include $ac_bdir$ac_obj.dep
62255$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62256	$ac_comp
62257EOF
62258  done
62259
62260
62261        EXT_STATIC="$EXT_STATIC pdo_odbc;$ext_dir"
62262        ;;
62263      *)
62264
62265
62266  case $ext_dir in
62267  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62268  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62269  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62270  esac
62271
62272
62273
62274  b_c_pre=$php_c_pre
62275  b_cxx_pre=$php_cxx_pre
62276  b_c_meta=$php_c_meta
62277  b_cxx_meta=$php_cxx_meta
62278  b_c_post=$php_c_post
62279  b_cxx_post=$php_cxx_post
62280  b_lo=$php_lo
62281
62282
62283  old_IFS=$IFS
62284  for ac_src in pdo_odbc.c odbc_driver.c odbc_stmt.c; do
62285
62286      IFS=.
62287      set $ac_src
62288      ac_obj=$1
62289      IFS=$old_IFS
62290
62291      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62292
62293      case $ac_src in
62294        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62295        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62296        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62297        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62298      esac
62299
62300      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62301
62302    cat >>Makefile.objects<<EOF
62303-include $ac_bdir$ac_obj.dep
62304$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62305	$ac_comp
62306EOF
62307  done
62308
62309
62310        ;;
62311    esac
62312    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_odbc;$ext_dir"
62313  fi
62314
62315
62316    BUILD_DIR="$BUILD_DIR $ext_builddir"
62317
62318
62319
62320  if test "$ext_builddir" = "."; then
62321    PHP_PECL_EXTENSION=pdo_odbc
62322
62323  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
62324
62325  fi
62326
62327
62328  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_ODBC_SHARED_LIBADD"
62329
62330
62331  am_i_shared=$PHP_PDO_ODBC_SHARED
62332  is_it_shared=$PHP_PDO_SHARED
62333  is_it_enabled=$PHP_PDO
62334  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
62335    as_fn_error $? "
62336You've configured extension pdo_odbc to build statically, but it
62337depends on extension pdo, which you've configured to build shared.
62338You either need to build pdo_odbc shared or build pdo statically for the
62339build to be successful.
62340" "$LINENO" 5
62341  fi
62342  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
62343    as_fn_error $? "
62344You've configured extension pdo_odbc, which depends on extension pdo,
62345but you've either not enabled pdo, or have disabled it.
62346" "$LINENO" 5
62347  fi
62348
62349fi
62350
62351
62352
62353
62354
62355php_with_pdo_pgsql=no
62356
62357{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PostgreSQL support for PDO" >&5
62358printf %s "checking for PostgreSQL support for PDO... " >&6; }
62359
62360# Check whether --with-pdo-pgsql was given.
62361if test ${with_pdo_pgsql+y}
62362then :
62363  withval=$with_pdo_pgsql; PHP_PDO_PGSQL=$withval
62364else $as_nop
62365
62366  PHP_PDO_PGSQL=no
62367  test "$PHP_ENABLE_ALL" && PHP_PDO_PGSQL=$PHP_ENABLE_ALL
62368
62369fi
62370
62371
62372
62373ext_output="yes, shared"
62374ext_shared=yes
62375case $PHP_PDO_PGSQL in
62376shared,*)
62377  PHP_PDO_PGSQL=`echo "$PHP_PDO_PGSQL"|$SED 's/^shared,//'`
62378  ;;
62379shared)
62380  PHP_PDO_PGSQL=yes
62381  ;;
62382no)
62383  ext_output=no
62384  ext_shared=no
62385  ;;
62386*)
62387  ext_output=yes
62388  ext_shared=no
62389  ;;
62390esac
62391
62392
62393
62394{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
62395printf "%s\n" "$ext_output" >&6; }
62396
62397
62398
62399
62400if test "$PHP_PDO_PGSQL" != "no"; then
62401
62402  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
62403    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
62404  fi
62405
62406
62407  if test -z "$PGSQL_INCLUDE" || echo "$PGSQL_INCLUDE" | grep '^/' >/dev/null ; then
62408    PGSQL_INCLUDE=$PGSQL_INCLUDE
62409  else
62410
62411    ep_dir=`echo $PGSQL_INCLUDE|$SED 's%/*[^/][^/]*/*$%%'`
62412
62413    ep_realdir=`(cd "$ep_dir" && pwd)`
62414    PGSQL_INCLUDE="$ep_realdir"/`basename "$PGSQL_INCLUDE"`
62415  fi
62416
62417
62418  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pg_config" >&5
62419printf %s "checking for pg_config... " >&6; }
62420  for i in $PHP_PDO_PGSQL $PHP_PDO_PGSQL/bin /usr/local/pgsql/bin /usr/local/bin /usr/bin ""; do
62421    if test -x $i/pg_config; then
62422      PG_CONFIG="$i/pg_config"
62423      break;
62424    fi
62425  done
62426
62427  if test -n "$PG_CONFIG"; then
62428    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
62429printf "%s\n" "$PG_CONFIG" >&6; }
62430    PGSQL_INCLUDE=`$PG_CONFIG --includedir`
62431    PGSQL_LIBDIR=`$PG_CONFIG --libdir`
62432  else
62433    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
62434printf "%s\n" "not found" >&6; }
62435    if test "$PHP_PDO_PGSQL" = "yes"; then
62436      PGSQL_SEARCH_PATHS="/usr /usr/local /usr/local/pgsql"
62437    else
62438      PGSQL_SEARCH_PATHS=$PHP_PDO_PGSQL
62439    fi
62440
62441    for i in $PGSQL_SEARCH_PATHS; do
62442      for j in include include/pgsql include/postgres include/postgresql ""; do
62443        if test -r "$i/$j/libpq-fe.h"; then
62444          PGSQL_INC_BASE=$i
62445          PGSQL_INCLUDE=$i/$j
62446        fi
62447      done
62448
62449      for j in $PHP_LIBDIR $PHP_LIBDIR/pgsql $PHP_LIBDIR/postgres $PHP_LIBDIR/postgresql ""; do
62450        if test -f "$i/$j/libpq.so" || test -f "$i/$j/libpq.a"; then
62451          PGSQL_LIBDIR=$i/$j
62452        fi
62453      done
62454    done
62455  fi
62456
62457  if test -z "$PGSQL_INCLUDE"; then
62458    as_fn_error $? "Cannot find libpq-fe.h. Please specify correct PostgreSQL installation path" "$LINENO" 5
62459  fi
62460
62461  if test -z "$PGSQL_LIBDIR"; then
62462    as_fn_error $? "Cannot find libpq.so. Please specify correct PostgreSQL installation path" "$LINENO" 5
62463  fi
62464
62465  if test -z "$PGSQL_INCLUDE" -a -z "$PGSQL_LIBDIR" ; then
62466    as_fn_error $? "Unable to find libpq anywhere under $PGSQL_SEARCH_PATHS" "$LINENO" 5
62467  fi
62468
62469
62470printf "%s\n" "#define HAVE_PDO_PGSQL 1" >>confdefs.h
62471
62472
62473  old_LIBS=$LIBS
62474  old_LDFLAGS=$LDFLAGS
62475  LDFLAGS="-L$PGSQL_LIBDIR $LDFLAGS"
62476
62477  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PQlibVersion in -lpq" >&5
62478printf %s "checking for PQlibVersion in -lpq... " >&6; }
62479if test ${ac_cv_lib_pq_PQlibVersion+y}
62480then :
62481  printf %s "(cached) " >&6
62482else $as_nop
62483  ac_check_lib_save_LIBS=$LIBS
62484LIBS="-lpq  $LIBS"
62485cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62486/* end confdefs.h.  */
62487
62488/* Override any GCC internal prototype to avoid an error.
62489   Use char because int might match the return type of a GCC
62490   builtin and then its argument prototype would still apply.  */
62491char PQlibVersion ();
62492int
62493main (void)
62494{
62495return PQlibVersion ();
62496  ;
62497  return 0;
62498}
62499_ACEOF
62500if ac_fn_c_try_link "$LINENO"
62501then :
62502  ac_cv_lib_pq_PQlibVersion=yes
62503else $as_nop
62504  ac_cv_lib_pq_PQlibVersion=no
62505fi
62506rm -f core conftest.err conftest.$ac_objext conftest.beam \
62507    conftest$ac_exeext conftest.$ac_ext
62508LIBS=$ac_check_lib_save_LIBS
62509fi
62510{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_PQlibVersion" >&5
62511printf "%s\n" "$ac_cv_lib_pq_PQlibVersion" >&6; }
62512if test "x$ac_cv_lib_pq_PQlibVersion" = xyes
62513then :
62514  printf "%s\n" "#define HAVE_LIBPQ 1" >>confdefs.h
62515
62516  LIBS="-lpq $LIBS"
62517
62518else $as_nop
62519  as_fn_error $? "Unable to build the PDO PostgreSQL driver: at least libpq 9.1 is required" "$LINENO" 5
62520fi
62521
62522
62523  LIBS=$old_LIBS
62524  LDFLAGS=$old_LDFLAGS
62525
62526
62527
62528  if test "$ext_shared" = "yes"; then
62529    PDO_PGSQL_SHARED_LIBADD="-lpq $PDO_PGSQL_SHARED_LIBADD"
62530    if test -n "$PGSQL_LIBDIR"; then
62531
62532  if test "$PGSQL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PGSQL_LIBDIR" != "/usr/lib"; then
62533
62534  if test -z "$PGSQL_LIBDIR" || echo "$PGSQL_LIBDIR" | grep '^/' >/dev/null ; then
62535    ai_p=$PGSQL_LIBDIR
62536  else
62537
62538    ep_dir=`echo $PGSQL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
62539
62540    ep_realdir=`(cd "$ep_dir" && pwd)`
62541    ai_p="$ep_realdir"/`basename "$PGSQL_LIBDIR"`
62542  fi
62543
62544
62545      if test "$ext_shared" = "yes"; then
62546        PDO_PGSQL_SHARED_LIBADD="-L$ai_p $PDO_PGSQL_SHARED_LIBADD"
62547        test -n "$ld_runpath_switch" && PDO_PGSQL_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_PGSQL_SHARED_LIBADD"
62548      else
62549
62550
62551
62552  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
62553
62554  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
62555  if test -n "$unique" && test "`eval $cmd`" = "" ; then
62556    eval "LIBPATH$unique=set"
62557
62558    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
62559    LDFLAGS="$LDFLAGS -L$ai_p"
62560    PHP_RPATHS="$PHP_RPATHS $ai_p"
62561
62562  fi
62563
62564
62565      fi
62566
62567  fi
62568
62569    fi
62570  else
62571
62572
62573  if test -n "$PGSQL_LIBDIR"; then
62574
62575  if test "$PGSQL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PGSQL_LIBDIR" != "/usr/lib"; then
62576
62577  if test -z "$PGSQL_LIBDIR" || echo "$PGSQL_LIBDIR" | grep '^/' >/dev/null ; then
62578    ai_p=$PGSQL_LIBDIR
62579  else
62580
62581    ep_dir=`echo $PGSQL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
62582
62583    ep_realdir=`(cd "$ep_dir" && pwd)`
62584    ai_p="$ep_realdir"/`basename "$PGSQL_LIBDIR"`
62585  fi
62586
62587
62588
62589
62590
62591  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
62592
62593  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
62594  if test -n "$unique" && test "`eval $cmd`" = "" ; then
62595    eval "LIBPATH$unique=set"
62596
62597    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
62598    LDFLAGS="$LDFLAGS -L$ai_p"
62599    PHP_RPATHS="$PHP_RPATHS $ai_p"
62600
62601  fi
62602
62603
62604
62605  fi
62606
62607  fi
62608
62609
62610  case pq in
62611  c|c_r) ;;
62612  *)
62613      LIBS="-lpq $LIBS"
62614   ;;
62615  esac
62616
62617
62618
62619
62620  fi
62621
62622
62623
62624  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_PGSQL_SHARED_LIBADD"
62625
62626
62627
62628  if test "$PGSQL_INCLUDE" != "/usr/include"; then
62629
62630  if test -z "$PGSQL_INCLUDE" || echo "$PGSQL_INCLUDE" | grep '^/' >/dev/null ; then
62631    ai_p=$PGSQL_INCLUDE
62632  else
62633
62634    ep_dir=`echo $PGSQL_INCLUDE|$SED 's%/*[^/][^/]*/*$%%'`
62635
62636    ep_realdir=`(cd "$ep_dir" && pwd)`
62637    ai_p="$ep_realdir"/`basename "$PGSQL_INCLUDE"`
62638  fi
62639
62640
62641
62642  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
62643
62644  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
62645  if test -n "$unique" && test "`eval $cmd`" = "" ; then
62646    eval "INCLUDEPATH$unique=set"
62647
62648      if test ""; then
62649        INCLUDES="-I$ai_p $INCLUDES"
62650      else
62651        INCLUDES="$INCLUDES -I$ai_p"
62652      fi
62653
62654  fi
62655
62656  fi
62657
62658
62659
62660  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
62661printf %s "checking for PDO includes... " >&6; }
62662if test ${pdo_cv_inc_path+y}
62663then :
62664  printf %s "(cached) " >&6
62665else $as_nop
62666
62667    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
62668      pdo_cv_inc_path=$abs_srcdir/ext
62669    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
62670      pdo_cv_inc_path=$abs_srcdir/ext
62671    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
62672      pdo_cv_inc_path=$phpincludedir/ext
62673    fi
62674
62675fi
62676{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
62677printf "%s\n" "$pdo_cv_inc_path" >&6; }
62678  if test -n "$pdo_cv_inc_path"; then
62679:
62680  else
62681as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
62682  fi
62683
62684
62685
62686  ext_builddir=ext/pdo_pgsql
62687  ext_srcdir=$abs_srcdir/ext/pdo_pgsql
62688  ext_dir=ext/pdo_pgsql
62689
62690  ac_extra=`echo "-I$pdo_cv_inc_path"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
62691
62692  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
62693    PHP_PDO_PGSQL_SHARED=no
62694
62695
62696  case $ext_dir in
62697  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62698  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62699  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62700  esac
62701
62702
62703
62704  b_c_pre=$php_c_pre
62705  b_cxx_pre=$php_cxx_pre
62706  b_c_meta=$php_c_meta
62707  b_cxx_meta=$php_cxx_meta
62708  b_c_post=$php_c_post
62709  b_cxx_post=$php_cxx_post
62710  b_lo=$php_lo
62711
62712
62713  old_IFS=$IFS
62714  for ac_src in pdo_pgsql.c pgsql_driver.c pgsql_statement.c; do
62715
62716      IFS=.
62717      set $ac_src
62718      ac_obj=$1
62719      IFS=$old_IFS
62720
62721      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62722
62723      case $ac_src in
62724        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62725        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62726        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62727        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62728      esac
62729
62730      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62731
62732    cat >>Makefile.objects<<EOF
62733-include $ac_bdir$ac_obj.dep
62734$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62735	$ac_comp
62736EOF
62737  done
62738
62739
62740    EXT_STATIC="$EXT_STATIC pdo_pgsql;$ext_dir"
62741    if test "$ext_shared" != "nocli"; then
62742      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_pgsql;$ext_dir"
62743    fi
62744  else
62745    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
62746      PHP_PDO_PGSQL_SHARED=yes
62747
62748  case $ext_dir in
62749  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62750  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62751  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62752  esac
62753
62754
62755
62756  b_c_pre=$shared_c_pre
62757  b_cxx_pre=$shared_cxx_pre
62758  b_c_meta=$shared_c_meta
62759  b_cxx_meta=$shared_cxx_meta
62760  b_c_post=$shared_c_post
62761  b_cxx_post=$shared_cxx_post
62762  b_lo=$shared_lo
62763
62764
62765  old_IFS=$IFS
62766  for ac_src in pdo_pgsql.c pgsql_driver.c pgsql_statement.c; do
62767
62768      IFS=.
62769      set $ac_src
62770      ac_obj=$1
62771      IFS=$old_IFS
62772
62773      shared_objects_pdo_pgsql="$shared_objects_pdo_pgsql $ac_bdir$ac_obj.lo"
62774
62775      case $ac_src in
62776        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62777        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62778        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62779        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62780      esac
62781
62782      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62783
62784    cat >>Makefile.objects<<EOF
62785-include $ac_bdir$ac_obj.dep
62786$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62787	$ac_comp
62788EOF
62789  done
62790
62791
62792  install_modules="install-modules"
62793  suffix=la
62794
62795  case $host_alias in
62796    *aix*)
62797      additional_flags="-Wl,-G"
62798      ;;
62799  esac
62800
62801  if test "x" = "xyes"; then
62802    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_pgsql.$suffix"
62803  else
62804    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_pgsql.$suffix"
62805  fi
62806
62807  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_pgsql"
62808
62809  cat >>Makefile.objects<<EOF
62810\$(phplibdir)/pdo_pgsql.$suffix: $ext_builddir/pdo_pgsql.$suffix
62811	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_pgsql.$suffix \$(phplibdir)
62812
62813$ext_builddir/pdo_pgsql.$suffix: \$(shared_objects_pdo_pgsql) \$(PDO_PGSQL_SHARED_DEPENDENCIES)
62814	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_pgsql) \$(PDO_PGSQL_SHARED_LIBADD)
62815
62816EOF
62817
62818
62819printf "%s\n" "#define COMPILE_DL_PDO_PGSQL 1" >>confdefs.h
62820
62821    fi
62822  fi
62823
62824  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
62825    PHP_PDO_PGSQL_SHARED=no
62826    case "$PHP_SAPI" in
62827      cgi|embed|phpdbg)
62828
62829
62830  case $ext_dir in
62831  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62832  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62833  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62834  esac
62835
62836
62837
62838  b_c_pre=$php_c_pre
62839  b_cxx_pre=$php_cxx_pre
62840  b_c_meta=$php_c_meta
62841  b_cxx_meta=$php_cxx_meta
62842  b_c_post=$php_c_post
62843  b_cxx_post=$php_cxx_post
62844  b_lo=$php_lo
62845
62846
62847  old_IFS=$IFS
62848  for ac_src in pdo_pgsql.c pgsql_driver.c pgsql_statement.c; do
62849
62850      IFS=.
62851      set $ac_src
62852      ac_obj=$1
62853      IFS=$old_IFS
62854
62855      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62856
62857      case $ac_src in
62858        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62859        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62860        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62861        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62862      esac
62863
62864      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62865
62866    cat >>Makefile.objects<<EOF
62867-include $ac_bdir$ac_obj.dep
62868$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62869	$ac_comp
62870EOF
62871  done
62872
62873
62874        EXT_STATIC="$EXT_STATIC pdo_pgsql;$ext_dir"
62875        ;;
62876      *)
62877
62878
62879  case $ext_dir in
62880  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
62881  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
62882  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
62883  esac
62884
62885
62886
62887  b_c_pre=$php_c_pre
62888  b_cxx_pre=$php_cxx_pre
62889  b_c_meta=$php_c_meta
62890  b_cxx_meta=$php_cxx_meta
62891  b_c_post=$php_c_post
62892  b_cxx_post=$php_cxx_post
62893  b_lo=$php_lo
62894
62895
62896  old_IFS=$IFS
62897  for ac_src in pdo_pgsql.c pgsql_driver.c pgsql_statement.c; do
62898
62899      IFS=.
62900      set $ac_src
62901      ac_obj=$1
62902      IFS=$old_IFS
62903
62904      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
62905
62906      case $ac_src in
62907        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62908        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62909        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
62910        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
62911      esac
62912
62913      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
62914
62915    cat >>Makefile.objects<<EOF
62916-include $ac_bdir$ac_obj.dep
62917$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
62918	$ac_comp
62919EOF
62920  done
62921
62922
62923        ;;
62924    esac
62925    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_pgsql;$ext_dir"
62926  fi
62927
62928
62929    BUILD_DIR="$BUILD_DIR $ext_builddir"
62930
62931
62932
62933  if test "$ext_builddir" = "."; then
62934    PHP_PECL_EXTENSION=pdo_pgsql
62935
62936  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
62937
62938  fi
62939
62940
62941  am_i_shared=$PHP_PDO_PGSQL_SHARED
62942  is_it_shared=$PHP_PDO_SHARED
62943  is_it_enabled=$PHP_PDO
62944  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
62945    as_fn_error $? "
62946You've configured extension pdo_pgsql to build statically, but it
62947depends on extension pdo, which you've configured to build shared.
62948You either need to build pdo_pgsql shared or build pdo statically for the
62949build to be successful.
62950" "$LINENO" 5
62951  fi
62952  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
62953    as_fn_error $? "
62954You've configured extension pdo_pgsql, which depends on extension pdo,
62955but you've either not enabled pdo, or have disabled it.
62956" "$LINENO" 5
62957  fi
62958
62959fi
62960
62961
62962
62963
62964
62965php_with_pdo_sqlite=$PHP_PDO
62966
62967{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite 3 support for PDO" >&5
62968printf %s "checking for sqlite 3 support for PDO... " >&6; }
62969
62970# Check whether --with-pdo-sqlite was given.
62971if test ${with_pdo_sqlite+y}
62972then :
62973  withval=$with_pdo_sqlite; PHP_PDO_SQLITE=$withval
62974else $as_nop
62975
62976  PHP_PDO_SQLITE=$PHP_PDO
62977  test "$PHP_ENABLE_ALL" && PHP_PDO_SQLITE=$PHP_ENABLE_ALL
62978
62979fi
62980
62981
62982
62983ext_output="yes, shared"
62984ext_shared=yes
62985case $PHP_PDO_SQLITE in
62986shared,*)
62987  PHP_PDO_SQLITE=`echo "$PHP_PDO_SQLITE"|$SED 's/^shared,//'`
62988  ;;
62989shared)
62990  PHP_PDO_SQLITE=yes
62991  ;;
62992no)
62993  ext_output=no
62994  ext_shared=no
62995  ;;
62996*)
62997  ext_output=yes
62998  ext_shared=no
62999  ;;
63000esac
63001
63002
63003
63004{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
63005printf "%s\n" "$ext_output" >&6; }
63006
63007
63008
63009
63010if test "$PHP_PDO_SQLITE" != "no"; then
63011
63012  if test "$PHP_PDO" = "no" && test "$ext_shared" = "no"; then
63013    as_fn_error $? "PDO is not enabled! Add --enable-pdo to your configure line." "$LINENO" 5
63014  fi
63015
63016
63017  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PDO includes" >&5
63018printf %s "checking for PDO includes... " >&6; }
63019if test ${pdo_cv_inc_path+y}
63020then :
63021  printf %s "(cached) " >&6
63022else $as_nop
63023
63024    if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
63025      pdo_cv_inc_path=$abs_srcdir/ext
63026    elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
63027      pdo_cv_inc_path=$abs_srcdir/ext
63028    elif test -f $phpincludedir/ext/pdo/php_pdo_driver.h; then
63029      pdo_cv_inc_path=$phpincludedir/ext
63030    fi
63031
63032fi
63033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $pdo_cv_inc_path" >&5
63034printf "%s\n" "$pdo_cv_inc_path" >&6; }
63035  if test -n "$pdo_cv_inc_path"; then
63036:
63037  else
63038as_fn_error $? "Cannot find php_pdo_driver.h." "$LINENO" 5
63039  fi
63040
63041
63042
63043pkg_failed=no
63044{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3 >= 3.7.7" >&5
63045printf %s "checking for sqlite3 >= 3.7.7... " >&6; }
63046
63047if test -n "$SQLITE_CFLAGS"; then
63048    pkg_cv_SQLITE_CFLAGS="$SQLITE_CFLAGS"
63049 elif test -n "$PKG_CONFIG"; then
63050    if test -n "$PKG_CONFIG" && \
63051    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3 >= 3.7.7\""; } >&5
63052  ($PKG_CONFIG --exists --print-errors "sqlite3 >= 3.7.7") 2>&5
63053  ac_status=$?
63054  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
63055  test $ac_status = 0; }; then
63056  pkg_cv_SQLITE_CFLAGS=`$PKG_CONFIG --cflags "sqlite3 >= 3.7.7" 2>/dev/null`
63057		      test "x$?" != "x0" && pkg_failed=yes
63058else
63059  pkg_failed=yes
63060fi
63061 else
63062    pkg_failed=untried
63063fi
63064if test -n "$SQLITE_LIBS"; then
63065    pkg_cv_SQLITE_LIBS="$SQLITE_LIBS"
63066 elif test -n "$PKG_CONFIG"; then
63067    if test -n "$PKG_CONFIG" && \
63068    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3 >= 3.7.7\""; } >&5
63069  ($PKG_CONFIG --exists --print-errors "sqlite3 >= 3.7.7") 2>&5
63070  ac_status=$?
63071  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
63072  test $ac_status = 0; }; then
63073  pkg_cv_SQLITE_LIBS=`$PKG_CONFIG --libs "sqlite3 >= 3.7.7" 2>/dev/null`
63074		      test "x$?" != "x0" && pkg_failed=yes
63075else
63076  pkg_failed=yes
63077fi
63078 else
63079    pkg_failed=untried
63080fi
63081
63082
63083
63084if test $pkg_failed = yes; then
63085        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
63086printf "%s\n" "no" >&6; }
63087
63088if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
63089        _pkg_short_errors_supported=yes
63090else
63091        _pkg_short_errors_supported=no
63092fi
63093        if test $_pkg_short_errors_supported = yes; then
63094	        SQLITE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "sqlite3 >= 3.7.7" 2>&1`
63095        else
63096	        SQLITE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "sqlite3 >= 3.7.7" 2>&1`
63097        fi
63098	# Put the nasty error message in config.log where it belongs
63099	echo "$SQLITE_PKG_ERRORS" >&5
63100
63101	as_fn_error $? "Package requirements (sqlite3 >= 3.7.7) were not met:
63102
63103$SQLITE_PKG_ERRORS
63104
63105Consider adjusting the PKG_CONFIG_PATH environment variable if you
63106installed software in a non-standard prefix.
63107
63108Alternatively, you may set the environment variables SQLITE_CFLAGS
63109and SQLITE_LIBS to avoid the need to call pkg-config.
63110See the pkg-config man page for more details." "$LINENO" 5
63111elif test $pkg_failed = untried; then
63112        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
63113printf "%s\n" "no" >&6; }
63114	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
63115printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
63116as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
63117is in your PATH or set the PKG_CONFIG environment variable to the full
63118path to pkg-config.
63119
63120Alternatively, you may set the environment variables SQLITE_CFLAGS
63121and SQLITE_LIBS to avoid the need to call pkg-config.
63122See the pkg-config man page for more details.
63123
63124To get pkg-config, see <http://pkg-config.freedesktop.org/>.
63125See \`config.log' for more details" "$LINENO" 5; }
63126else
63127	SQLITE_CFLAGS=$pkg_cv_SQLITE_CFLAGS
63128	SQLITE_LIBS=$pkg_cv_SQLITE_LIBS
63129        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
63130printf "%s\n" "yes" >&6; }
63131
63132fi
63133
63134
63135  for ac_i in $SQLITE_CFLAGS; do
63136    case $ac_i in
63137    -I*)
63138      ac_ii=`echo $ac_i|cut -c 3-`
63139
63140  if test "$ac_ii" != "/usr/include"; then
63141
63142  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
63143    ai_p=$ac_ii
63144  else
63145
63146    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
63147
63148    ep_realdir=`(cd "$ep_dir" && pwd)`
63149    ai_p="$ep_realdir"/`basename "$ac_ii"`
63150  fi
63151
63152
63153
63154  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
63155
63156  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
63157  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63158    eval "INCLUDEPATH$unique=set"
63159
63160      if test ""; then
63161        INCLUDES="-I$ai_p $INCLUDES"
63162      else
63163        INCLUDES="$INCLUDES -I$ai_p"
63164      fi
63165
63166  fi
63167
63168  fi
63169
63170    ;;
63171    esac
63172  done
63173
63174
63175  for ac_i in $SQLITE_LIBS; do
63176    case $ac_i in
63177    -pthread)
63178      if test "$ext_shared" = "yes"; then
63179        PDO_SQLITE_SHARED_LIBADD="$PDO_SQLITE_SHARED_LIBADD -pthread"
63180      else
63181
63182
63183  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63184
63185  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
63186  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63187    eval "EXTRA_LDFLAGS$unique=set"
63188    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
63189  fi
63190
63191
63192
63193  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63194
63195  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
63196  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63197    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
63198    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
63199  fi
63200
63201      fi
63202    ;;
63203    -l*)
63204      ac_ii=`echo $ac_i|cut -c 3-`
63205
63206
63207  case $ac_ii in
63208  c|c_r) ;;
63209  *)
63210    if test "$ext_shared" = "yes"; then
63211        PDO_SQLITE_SHARED_LIBADD="$PDO_SQLITE_SHARED_LIBADD -l$ac_ii"
63212    else
63213
63214
63215  case $ac_ii in
63216  c|c_r) ;;
63217  *)
63218      LIBS="$LIBS -l$ac_ii"
63219   ;;
63220  esac
63221
63222
63223    fi
63224   ;;
63225  esac
63226
63227
63228    ;;
63229    -L*)
63230      ac_ii=`echo $ac_i|cut -c 3-`
63231
63232  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
63233
63234  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
63235    ai_p=$ac_ii
63236  else
63237
63238    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
63239
63240    ep_realdir=`(cd "$ep_dir" && pwd)`
63241    ai_p="$ep_realdir"/`basename "$ac_ii"`
63242  fi
63243
63244
63245      if test "$ext_shared" = "yes"; then
63246        PDO_SQLITE_SHARED_LIBADD="-L$ai_p $PDO_SQLITE_SHARED_LIBADD"
63247        test -n "$ld_runpath_switch" && PDO_SQLITE_SHARED_LIBADD="$ld_runpath_switch$ai_p $PDO_SQLITE_SHARED_LIBADD"
63248      else
63249
63250
63251
63252  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
63253
63254  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
63255  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63256    eval "LIBPATH$unique=set"
63257
63258    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
63259    LDFLAGS="$LDFLAGS -L$ai_p"
63260    PHP_RPATHS="$PHP_RPATHS $ai_p"
63261
63262  fi
63263
63264
63265      fi
63266
63267  fi
63268
63269    ;;
63270    esac
63271  done
63272
63273
63274printf "%s\n" "#define HAVE_PDO_SQLITELIB 1" >>confdefs.h
63275
63276
63277
63278  save_old_LDFLAGS=$LDFLAGS
63279  ac_stuff="$PDO_SQLITE_SHARED_LIBADD"
63280
63281  save_ext_shared=$ext_shared
63282  ext_shared=yes
63283
63284  for ac_i in $ac_stuff; do
63285    case $ac_i in
63286    -pthread)
63287      if test "$ext_shared" = "yes"; then
63288        LDFLAGS="$LDFLAGS -pthread"
63289      else
63290
63291
63292  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63293
63294  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
63295  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63296    eval "EXTRA_LDFLAGS$unique=set"
63297    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
63298  fi
63299
63300
63301
63302  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63303
63304  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
63305  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63306    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
63307    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
63308  fi
63309
63310      fi
63311    ;;
63312    -l*)
63313      ac_ii=`echo $ac_i|cut -c 3-`
63314
63315
63316  case $ac_ii in
63317  c|c_r) ;;
63318  *)
63319    if test "$ext_shared" = "yes"; then
63320        LDFLAGS="$LDFLAGS -l$ac_ii"
63321    else
63322
63323
63324  case $ac_ii in
63325  c|c_r) ;;
63326  *)
63327      LIBS="$LIBS -l$ac_ii"
63328   ;;
63329  esac
63330
63331
63332    fi
63333   ;;
63334  esac
63335
63336
63337    ;;
63338    -L*)
63339      ac_ii=`echo $ac_i|cut -c 3-`
63340
63341  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
63342
63343  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
63344    ai_p=$ac_ii
63345  else
63346
63347    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
63348
63349    ep_realdir=`(cd "$ep_dir" && pwd)`
63350    ai_p="$ep_realdir"/`basename "$ac_ii"`
63351  fi
63352
63353
63354      if test "$ext_shared" = "yes"; then
63355        LDFLAGS="-L$ai_p $LDFLAGS"
63356        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
63357      else
63358
63359
63360
63361  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
63362
63363  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
63364  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63365    eval "LIBPATH$unique=set"
63366
63367    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
63368    LDFLAGS="$LDFLAGS -L$ai_p"
63369    PHP_RPATHS="$PHP_RPATHS $ai_p"
63370
63371  fi
63372
63373
63374      fi
63375
63376  fi
63377
63378    ;;
63379    esac
63380  done
63381
63382  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3_close_v2 in -lsqlite3" >&5
63383printf %s "checking for sqlite3_close_v2 in -lsqlite3... " >&6; }
63384if test ${ac_cv_lib_sqlite3_sqlite3_close_v2+y}
63385then :
63386  printf %s "(cached) " >&6
63387else $as_nop
63388  ac_check_lib_save_LIBS=$LIBS
63389LIBS="-lsqlite3  $LIBS"
63390cat confdefs.h - <<_ACEOF >conftest.$ac_ext
63391/* end confdefs.h.  */
63392
63393/* Override any GCC internal prototype to avoid an error.
63394   Use char because int might match the return type of a GCC
63395   builtin and then its argument prototype would still apply.  */
63396char sqlite3_close_v2 ();
63397int
63398main (void)
63399{
63400return sqlite3_close_v2 ();
63401  ;
63402  return 0;
63403}
63404_ACEOF
63405if ac_fn_c_try_link "$LINENO"
63406then :
63407  ac_cv_lib_sqlite3_sqlite3_close_v2=yes
63408else $as_nop
63409  ac_cv_lib_sqlite3_sqlite3_close_v2=no
63410fi
63411rm -f core conftest.err conftest.$ac_objext conftest.beam \
63412    conftest$ac_exeext conftest.$ac_ext
63413LIBS=$ac_check_lib_save_LIBS
63414fi
63415{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_close_v2" >&5
63416printf "%s\n" "$ac_cv_lib_sqlite3_sqlite3_close_v2" >&6; }
63417if test "x$ac_cv_lib_sqlite3_sqlite3_close_v2" = xyes
63418then :
63419
63420    LDFLAGS=$save_old_LDFLAGS
63421    ext_shared=$save_ext_shared
63422
63423
63424printf "%s\n" "#define HAVE_SQLITE3_CLOSE_V2 1" >>confdefs.h
63425
63426
63427
63428else $as_nop
63429
63430    LDFLAGS=$save_old_LDFLAGS
63431    ext_shared=$save_ext_shared
63432    unset ac_cv_lib_sqlite3_sqlite3_close_v2
63433
63434
63435fi
63436
63437
63438
63439  save_old_LDFLAGS=$LDFLAGS
63440  ac_stuff="$PDO_SQLITE_SHARED_LIBADD"
63441
63442  save_ext_shared=$ext_shared
63443  ext_shared=yes
63444
63445  for ac_i in $ac_stuff; do
63446    case $ac_i in
63447    -pthread)
63448      if test "$ext_shared" = "yes"; then
63449        LDFLAGS="$LDFLAGS -pthread"
63450      else
63451
63452
63453  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63454
63455  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
63456  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63457    eval "EXTRA_LDFLAGS$unique=set"
63458    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
63459  fi
63460
63461
63462
63463  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
63464
63465  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
63466  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63467    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
63468    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
63469  fi
63470
63471      fi
63472    ;;
63473    -l*)
63474      ac_ii=`echo $ac_i|cut -c 3-`
63475
63476
63477  case $ac_ii in
63478  c|c_r) ;;
63479  *)
63480    if test "$ext_shared" = "yes"; then
63481        LDFLAGS="$LDFLAGS -l$ac_ii"
63482    else
63483
63484
63485  case $ac_ii in
63486  c|c_r) ;;
63487  *)
63488      LIBS="$LIBS -l$ac_ii"
63489   ;;
63490  esac
63491
63492
63493    fi
63494   ;;
63495  esac
63496
63497
63498    ;;
63499    -L*)
63500      ac_ii=`echo $ac_i|cut -c 3-`
63501
63502  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
63503
63504  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
63505    ai_p=$ac_ii
63506  else
63507
63508    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
63509
63510    ep_realdir=`(cd "$ep_dir" && pwd)`
63511    ai_p="$ep_realdir"/`basename "$ac_ii"`
63512  fi
63513
63514
63515      if test "$ext_shared" = "yes"; then
63516        LDFLAGS="-L$ai_p $LDFLAGS"
63517        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
63518      else
63519
63520
63521
63522  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
63523
63524  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
63525  if test -n "$unique" && test "`eval $cmd`" = "" ; then
63526    eval "LIBPATH$unique=set"
63527
63528    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
63529    LDFLAGS="$LDFLAGS -L$ai_p"
63530    PHP_RPATHS="$PHP_RPATHS $ai_p"
63531
63532  fi
63533
63534
63535      fi
63536
63537  fi
63538
63539    ;;
63540    esac
63541  done
63542
63543  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sqlite3_column_table_name in -lsqlite3" >&5
63544printf %s "checking for sqlite3_column_table_name in -lsqlite3... " >&6; }
63545if test ${ac_cv_lib_sqlite3_sqlite3_column_table_name+y}
63546then :
63547  printf %s "(cached) " >&6
63548else $as_nop
63549  ac_check_lib_save_LIBS=$LIBS
63550LIBS="-lsqlite3  $LIBS"
63551cat confdefs.h - <<_ACEOF >conftest.$ac_ext
63552/* end confdefs.h.  */
63553
63554/* Override any GCC internal prototype to avoid an error.
63555   Use char because int might match the return type of a GCC
63556   builtin and then its argument prototype would still apply.  */
63557char sqlite3_column_table_name ();
63558int
63559main (void)
63560{
63561return sqlite3_column_table_name ();
63562  ;
63563  return 0;
63564}
63565_ACEOF
63566if ac_fn_c_try_link "$LINENO"
63567then :
63568  ac_cv_lib_sqlite3_sqlite3_column_table_name=yes
63569else $as_nop
63570  ac_cv_lib_sqlite3_sqlite3_column_table_name=no
63571fi
63572rm -f core conftest.err conftest.$ac_objext conftest.beam \
63573    conftest$ac_exeext conftest.$ac_ext
63574LIBS=$ac_check_lib_save_LIBS
63575fi
63576{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sqlite3_sqlite3_column_table_name" >&5
63577printf "%s\n" "$ac_cv_lib_sqlite3_sqlite3_column_table_name" >&6; }
63578if test "x$ac_cv_lib_sqlite3_sqlite3_column_table_name" = xyes
63579then :
63580
63581    LDFLAGS=$save_old_LDFLAGS
63582    ext_shared=$save_ext_shared
63583
63584
63585printf "%s\n" "#define HAVE_SQLITE3_COLUMN_TABLE_NAME 1" >>confdefs.h
63586
63587
63588
63589else $as_nop
63590
63591    LDFLAGS=$save_old_LDFLAGS
63592    ext_shared=$save_ext_shared
63593    unset ac_cv_lib_sqlite3_sqlite3_column_table_name
63594
63595
63596fi
63597
63598
63599
63600  PHP_VAR_SUBST="$PHP_VAR_SUBST PDO_SQLITE_SHARED_LIBADD"
63601
63602
63603  ext_builddir=ext/pdo_sqlite
63604  ext_srcdir=$abs_srcdir/ext/pdo_sqlite
63605  ext_dir=ext/pdo_sqlite
63606
63607  ac_extra=`echo "-I$pdo_cv_inc_path"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
63608
63609  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
63610    PHP_PDO_SQLITE_SHARED=no
63611
63612
63613  case $ext_dir in
63614  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
63615  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
63616  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
63617  esac
63618
63619
63620
63621  b_c_pre=$php_c_pre
63622  b_cxx_pre=$php_cxx_pre
63623  b_c_meta=$php_c_meta
63624  b_cxx_meta=$php_cxx_meta
63625  b_c_post=$php_c_post
63626  b_cxx_post=$php_cxx_post
63627  b_lo=$php_lo
63628
63629
63630  old_IFS=$IFS
63631  for ac_src in pdo_sqlite.c sqlite_driver.c sqlite_statement.c; do
63632
63633      IFS=.
63634      set $ac_src
63635      ac_obj=$1
63636      IFS=$old_IFS
63637
63638      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
63639
63640      case $ac_src in
63641        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63642        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63643        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63644        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
63645      esac
63646
63647      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
63648
63649    cat >>Makefile.objects<<EOF
63650-include $ac_bdir$ac_obj.dep
63651$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
63652	$ac_comp
63653EOF
63654  done
63655
63656
63657    EXT_STATIC="$EXT_STATIC pdo_sqlite;$ext_dir"
63658    if test "$ext_shared" != "nocli"; then
63659      EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_sqlite;$ext_dir"
63660    fi
63661  else
63662    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
63663      PHP_PDO_SQLITE_SHARED=yes
63664
63665  case $ext_dir in
63666  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
63667  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
63668  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
63669  esac
63670
63671
63672
63673  b_c_pre=$shared_c_pre
63674  b_cxx_pre=$shared_cxx_pre
63675  b_c_meta=$shared_c_meta
63676  b_cxx_meta=$shared_cxx_meta
63677  b_c_post=$shared_c_post
63678  b_cxx_post=$shared_cxx_post
63679  b_lo=$shared_lo
63680
63681
63682  old_IFS=$IFS
63683  for ac_src in pdo_sqlite.c sqlite_driver.c sqlite_statement.c; do
63684
63685      IFS=.
63686      set $ac_src
63687      ac_obj=$1
63688      IFS=$old_IFS
63689
63690      shared_objects_pdo_sqlite="$shared_objects_pdo_sqlite $ac_bdir$ac_obj.lo"
63691
63692      case $ac_src in
63693        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63694        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63695        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63696        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
63697      esac
63698
63699      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
63700
63701    cat >>Makefile.objects<<EOF
63702-include $ac_bdir$ac_obj.dep
63703$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
63704	$ac_comp
63705EOF
63706  done
63707
63708
63709  install_modules="install-modules"
63710  suffix=la
63711
63712  case $host_alias in
63713    *aix*)
63714      additional_flags="-Wl,-G"
63715      ;;
63716  esac
63717
63718  if test "x" = "xyes"; then
63719    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pdo_sqlite.$suffix"
63720  else
63721    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pdo_sqlite.$suffix"
63722  fi
63723
63724  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pdo_sqlite"
63725
63726  cat >>Makefile.objects<<EOF
63727\$(phplibdir)/pdo_sqlite.$suffix: $ext_builddir/pdo_sqlite.$suffix
63728	\$(LIBTOOL) --mode=install cp $ext_builddir/pdo_sqlite.$suffix \$(phplibdir)
63729
63730$ext_builddir/pdo_sqlite.$suffix: \$(shared_objects_pdo_sqlite) \$(PDO_SQLITE_SHARED_DEPENDENCIES)
63731	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pdo_sqlite) \$(PDO_SQLITE_SHARED_LIBADD)
63732
63733EOF
63734
63735
63736printf "%s\n" "#define COMPILE_DL_PDO_SQLITE 1" >>confdefs.h
63737
63738    fi
63739  fi
63740
63741  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
63742    PHP_PDO_SQLITE_SHARED=no
63743    case "$PHP_SAPI" in
63744      cgi|embed|phpdbg)
63745
63746
63747  case $ext_dir in
63748  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
63749  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
63750  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
63751  esac
63752
63753
63754
63755  b_c_pre=$php_c_pre
63756  b_cxx_pre=$php_cxx_pre
63757  b_c_meta=$php_c_meta
63758  b_cxx_meta=$php_cxx_meta
63759  b_c_post=$php_c_post
63760  b_cxx_post=$php_cxx_post
63761  b_lo=$php_lo
63762
63763
63764  old_IFS=$IFS
63765  for ac_src in pdo_sqlite.c sqlite_driver.c sqlite_statement.c; do
63766
63767      IFS=.
63768      set $ac_src
63769      ac_obj=$1
63770      IFS=$old_IFS
63771
63772      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
63773
63774      case $ac_src in
63775        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63776        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63777        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63778        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
63779      esac
63780
63781      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
63782
63783    cat >>Makefile.objects<<EOF
63784-include $ac_bdir$ac_obj.dep
63785$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
63786	$ac_comp
63787EOF
63788  done
63789
63790
63791        EXT_STATIC="$EXT_STATIC pdo_sqlite;$ext_dir"
63792        ;;
63793      *)
63794
63795
63796  case $ext_dir in
63797  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
63798  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
63799  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
63800  esac
63801
63802
63803
63804  b_c_pre=$php_c_pre
63805  b_cxx_pre=$php_cxx_pre
63806  b_c_meta=$php_c_meta
63807  b_cxx_meta=$php_cxx_meta
63808  b_c_post=$php_c_post
63809  b_cxx_post=$php_cxx_post
63810  b_lo=$php_lo
63811
63812
63813  old_IFS=$IFS
63814  for ac_src in pdo_sqlite.c sqlite_driver.c sqlite_statement.c; do
63815
63816      IFS=.
63817      set $ac_src
63818      ac_obj=$1
63819      IFS=$old_IFS
63820
63821      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
63822
63823      case $ac_src in
63824        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63825        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63826        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
63827        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
63828      esac
63829
63830      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
63831
63832    cat >>Makefile.objects<<EOF
63833-include $ac_bdir$ac_obj.dep
63834$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
63835	$ac_comp
63836EOF
63837  done
63838
63839
63840        ;;
63841    esac
63842    EXT_CLI_STATIC="$EXT_CLI_STATIC pdo_sqlite;$ext_dir"
63843  fi
63844
63845
63846    BUILD_DIR="$BUILD_DIR $ext_builddir"
63847
63848
63849
63850  if test "$ext_builddir" = "."; then
63851    PHP_PECL_EXTENSION=pdo_sqlite
63852
63853  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
63854
63855  fi
63856
63857
63858
63859  am_i_shared=$PHP_PDO_SQLITE_SHARED
63860  is_it_shared=$PHP_PDO_SHARED
63861  is_it_enabled=$PHP_PDO
63862  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
63863    as_fn_error $? "
63864You've configured extension pdo_sqlite to build statically, but it
63865depends on extension pdo, which you've configured to build shared.
63866You either need to build pdo_sqlite shared or build pdo statically for the
63867build to be successful.
63868" "$LINENO" 5
63869  fi
63870  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
63871    as_fn_error $? "
63872You've configured extension pdo_sqlite, which depends on extension pdo,
63873but you've either not enabled pdo, or have disabled it.
63874" "$LINENO" 5
63875  fi
63876
63877fi
63878
63879
63880
63881
63882
63883php_with_pgsql=no
63884
63885{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PostgreSQL support" >&5
63886printf %s "checking for PostgreSQL support... " >&6; }
63887
63888# Check whether --with-pgsql was given.
63889if test ${with_pgsql+y}
63890then :
63891  withval=$with_pgsql; PHP_PGSQL=$withval
63892else $as_nop
63893
63894  PHP_PGSQL=no
63895  test "$PHP_ENABLE_ALL" && PHP_PGSQL=$PHP_ENABLE_ALL
63896
63897fi
63898
63899
63900
63901ext_output="yes, shared"
63902ext_shared=yes
63903case $PHP_PGSQL in
63904shared,*)
63905  PHP_PGSQL=`echo "$PHP_PGSQL"|$SED 's/^shared,//'`
63906  ;;
63907shared)
63908  PHP_PGSQL=yes
63909  ;;
63910no)
63911  ext_output=no
63912  ext_shared=no
63913  ;;
63914*)
63915  ext_output=yes
63916  ext_shared=no
63917  ;;
63918esac
63919
63920
63921
63922{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
63923printf "%s\n" "$ext_output" >&6; }
63924
63925
63926
63927
63928if test "$PHP_PGSQL" != "no"; then
63929
63930  if test -z "$PGSQL_INCLUDE" || echo "$PGSQL_INCLUDE" | grep '^/' >/dev/null ; then
63931    PGSQL_INCLUDE=$PGSQL_INCLUDE
63932  else
63933
63934    ep_dir=`echo $PGSQL_INCLUDE|$SED 's%/*[^/][^/]*/*$%%'`
63935
63936    ep_realdir=`(cd "$ep_dir" && pwd)`
63937    PGSQL_INCLUDE="$ep_realdir"/`basename "$PGSQL_INCLUDE"`
63938  fi
63939
63940
63941
63942  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pg_config" >&5
63943printf %s "checking for pg_config... " >&6; }
63944  for i in $PHP_PGSQL $PHP_PGSQL/bin /usr/local/pgsql/bin /usr/local/bin /usr/bin ""; do
63945	if test -x $i/pg_config; then
63946      PG_CONFIG="$i/pg_config"
63947      break;
63948    fi
63949  done
63950
63951  if test -n "$PG_CONFIG"; then
63952    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
63953printf "%s\n" "$PG_CONFIG" >&6; }
63954    PGSQL_INCLUDE=`$PG_CONFIG --includedir`
63955    PGSQL_LIBDIR=`$PG_CONFIG --libdir`
63956  else
63957    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
63958printf "%s\n" "not found" >&6; }
63959    if test "$PHP_PGSQL" = "yes"; then
63960      PGSQL_SEARCH_PATHS="/usr /usr/local /usr/local/pgsql"
63961    else
63962      PGSQL_SEARCH_PATHS=$PHP_PGSQL
63963    fi
63964
63965    for i in $PGSQL_SEARCH_PATHS; do
63966      for j in include include/pgsql include/postgres include/postgresql ""; do
63967        if test -r "$i/$j/libpq-fe.h"; then
63968          PGSQL_INC_BASE=$i
63969          PGSQL_INCLUDE=$i/$j
63970        fi
63971      done
63972
63973      for j in lib $PHP_LIBDIR/pgsql $PHP_LIBDIR/postgres $PHP_LIBDIR/postgresql ""; do
63974        if test -f "$i/$j/libpq.so" || test -f "$i/$j/libpq.a"; then
63975          PGSQL_LIBDIR=$i/$j
63976        fi
63977      done
63978    done
63979  fi
63980
63981  if test -z "$PGSQL_INCLUDE"; then
63982    as_fn_error $? "Cannot find libpq-fe.h. Please specify correct PostgreSQL installation path" "$LINENO" 5
63983  fi
63984
63985  if test -z "$PGSQL_LIBDIR"; then
63986    as_fn_error $? "Cannot find libpq.so. Please specify correct PostgreSQL installation path" "$LINENO" 5
63987  fi
63988
63989  if test -z "$PGSQL_INCLUDE" -a -z "$PGSQL_LIBDIR" ; then
63990    as_fn_error $? "Unable to find libpq anywhere under $PGSQL_SEARCH_PATHS" "$LINENO" 5
63991  fi
63992
63993
63994printf "%s\n" "#define HAVE_PGSQL 1" >>confdefs.h
63995
63996  old_LIBS=$LIBS
63997  old_LDFLAGS=$LDFLAGS
63998  LDFLAGS="-L$PGSQL_LIBDIR $LDFLAGS"
63999  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PQlibVersion in -lpq" >&5
64000printf %s "checking for PQlibVersion in -lpq... " >&6; }
64001if test ${ac_cv_lib_pq_PQlibVersion+y}
64002then :
64003  printf %s "(cached) " >&6
64004else $as_nop
64005  ac_check_lib_save_LIBS=$LIBS
64006LIBS="-lpq  $LIBS"
64007cat confdefs.h - <<_ACEOF >conftest.$ac_ext
64008/* end confdefs.h.  */
64009
64010/* Override any GCC internal prototype to avoid an error.
64011   Use char because int might match the return type of a GCC
64012   builtin and then its argument prototype would still apply.  */
64013char PQlibVersion ();
64014int
64015main (void)
64016{
64017return PQlibVersion ();
64018  ;
64019  return 0;
64020}
64021_ACEOF
64022if ac_fn_c_try_link "$LINENO"
64023then :
64024  ac_cv_lib_pq_PQlibVersion=yes
64025else $as_nop
64026  ac_cv_lib_pq_PQlibVersion=no
64027fi
64028rm -f core conftest.err conftest.$ac_objext conftest.beam \
64029    conftest$ac_exeext conftest.$ac_ext
64030LIBS=$ac_check_lib_save_LIBS
64031fi
64032{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_PQlibVersion" >&5
64033printf "%s\n" "$ac_cv_lib_pq_PQlibVersion" >&6; }
64034if test "x$ac_cv_lib_pq_PQlibVersion" = xyes
64035then :
64036  printf "%s\n" "#define HAVE_LIBPQ 1" >>confdefs.h
64037
64038  LIBS="-lpq $LIBS"
64039
64040else $as_nop
64041  as_fn_error $? "Unable to build the PostgreSQL extension: at least libpq 9.1 is required" "$LINENO" 5
64042fi
64043
64044  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pg_encoding_to_char in -lpq" >&5
64045printf %s "checking for pg_encoding_to_char in -lpq... " >&6; }
64046if test ${ac_cv_lib_pq_pg_encoding_to_char+y}
64047then :
64048  printf %s "(cached) " >&6
64049else $as_nop
64050  ac_check_lib_save_LIBS=$LIBS
64051LIBS="-lpq  $LIBS"
64052cat confdefs.h - <<_ACEOF >conftest.$ac_ext
64053/* end confdefs.h.  */
64054
64055/* Override any GCC internal prototype to avoid an error.
64056   Use char because int might match the return type of a GCC
64057   builtin and then its argument prototype would still apply.  */
64058char pg_encoding_to_char ();
64059int
64060main (void)
64061{
64062return pg_encoding_to_char ();
64063  ;
64064  return 0;
64065}
64066_ACEOF
64067if ac_fn_c_try_link "$LINENO"
64068then :
64069  ac_cv_lib_pq_pg_encoding_to_char=yes
64070else $as_nop
64071  ac_cv_lib_pq_pg_encoding_to_char=no
64072fi
64073rm -f core conftest.err conftest.$ac_objext conftest.beam \
64074    conftest$ac_exeext conftest.$ac_ext
64075LIBS=$ac_check_lib_save_LIBS
64076fi
64077{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_pg_encoding_to_char" >&5
64078printf "%s\n" "$ac_cv_lib_pq_pg_encoding_to_char" >&6; }
64079if test "x$ac_cv_lib_pq_pg_encoding_to_char" = xyes
64080then :
64081
64082printf "%s\n" "#define HAVE_PGSQL_WITH_MULTIBYTE_SUPPORT 1" >>confdefs.h
64083
64084fi
64085
64086  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lo_truncate64 in -lpq" >&5
64087printf %s "checking for lo_truncate64 in -lpq... " >&6; }
64088if test ${ac_cv_lib_pq_lo_truncate64+y}
64089then :
64090  printf %s "(cached) " >&6
64091else $as_nop
64092  ac_check_lib_save_LIBS=$LIBS
64093LIBS="-lpq  $LIBS"
64094cat confdefs.h - <<_ACEOF >conftest.$ac_ext
64095/* end confdefs.h.  */
64096
64097/* Override any GCC internal prototype to avoid an error.
64098   Use char because int might match the return type of a GCC
64099   builtin and then its argument prototype would still apply.  */
64100char lo_truncate64 ();
64101int
64102main (void)
64103{
64104return lo_truncate64 ();
64105  ;
64106  return 0;
64107}
64108_ACEOF
64109if ac_fn_c_try_link "$LINENO"
64110then :
64111  ac_cv_lib_pq_lo_truncate64=yes
64112else $as_nop
64113  ac_cv_lib_pq_lo_truncate64=no
64114fi
64115rm -f core conftest.err conftest.$ac_objext conftest.beam \
64116    conftest$ac_exeext conftest.$ac_ext
64117LIBS=$ac_check_lib_save_LIBS
64118fi
64119{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_lo_truncate64" >&5
64120printf "%s\n" "$ac_cv_lib_pq_lo_truncate64" >&6; }
64121if test "x$ac_cv_lib_pq_lo_truncate64" = xyes
64122then :
64123
64124printf "%s\n" "#define HAVE_PG_LO64 1" >>confdefs.h
64125
64126fi
64127
64128  LIBS=$old_LIBS
64129  LDFLAGS=$old_LDFLAGS
64130
64131
64132
64133  if test "$ext_shared" = "yes"; then
64134    PGSQL_SHARED_LIBADD="-lpq $PGSQL_SHARED_LIBADD"
64135    if test -n "$PGSQL_LIBDIR"; then
64136
64137  if test "$PGSQL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PGSQL_LIBDIR" != "/usr/lib"; then
64138
64139  if test -z "$PGSQL_LIBDIR" || echo "$PGSQL_LIBDIR" | grep '^/' >/dev/null ; then
64140    ai_p=$PGSQL_LIBDIR
64141  else
64142
64143    ep_dir=`echo $PGSQL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
64144
64145    ep_realdir=`(cd "$ep_dir" && pwd)`
64146    ai_p="$ep_realdir"/`basename "$PGSQL_LIBDIR"`
64147  fi
64148
64149
64150      if test "$ext_shared" = "yes"; then
64151        PGSQL_SHARED_LIBADD="-L$ai_p $PGSQL_SHARED_LIBADD"
64152        test -n "$ld_runpath_switch" && PGSQL_SHARED_LIBADD="$ld_runpath_switch$ai_p $PGSQL_SHARED_LIBADD"
64153      else
64154
64155
64156
64157  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
64158
64159  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
64160  if test -n "$unique" && test "`eval $cmd`" = "" ; then
64161    eval "LIBPATH$unique=set"
64162
64163    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
64164    LDFLAGS="$LDFLAGS -L$ai_p"
64165    PHP_RPATHS="$PHP_RPATHS $ai_p"
64166
64167  fi
64168
64169
64170      fi
64171
64172  fi
64173
64174    fi
64175  else
64176
64177
64178  if test -n "$PGSQL_LIBDIR"; then
64179
64180  if test "$PGSQL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PGSQL_LIBDIR" != "/usr/lib"; then
64181
64182  if test -z "$PGSQL_LIBDIR" || echo "$PGSQL_LIBDIR" | grep '^/' >/dev/null ; then
64183    ai_p=$PGSQL_LIBDIR
64184  else
64185
64186    ep_dir=`echo $PGSQL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
64187
64188    ep_realdir=`(cd "$ep_dir" && pwd)`
64189    ai_p="$ep_realdir"/`basename "$PGSQL_LIBDIR"`
64190  fi
64191
64192
64193
64194
64195
64196  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
64197
64198  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
64199  if test -n "$unique" && test "`eval $cmd`" = "" ; then
64200    eval "LIBPATH$unique=set"
64201
64202    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
64203    LDFLAGS="$LDFLAGS -L$ai_p"
64204    PHP_RPATHS="$PHP_RPATHS $ai_p"
64205
64206  fi
64207
64208
64209
64210  fi
64211
64212  fi
64213
64214
64215  case pq in
64216  c|c_r) ;;
64217  *)
64218      LIBS="-lpq $LIBS"
64219   ;;
64220  esac
64221
64222
64223
64224
64225  fi
64226
64227
64228
64229  PHP_VAR_SUBST="$PHP_VAR_SUBST PGSQL_SHARED_LIBADD"
64230
64231
64232
64233  if test "$PGSQL_INCLUDE" != "/usr/include"; then
64234
64235  if test -z "$PGSQL_INCLUDE" || echo "$PGSQL_INCLUDE" | grep '^/' >/dev/null ; then
64236    ai_p=$PGSQL_INCLUDE
64237  else
64238
64239    ep_dir=`echo $PGSQL_INCLUDE|$SED 's%/*[^/][^/]*/*$%%'`
64240
64241    ep_realdir=`(cd "$ep_dir" && pwd)`
64242    ai_p="$ep_realdir"/`basename "$PGSQL_INCLUDE"`
64243  fi
64244
64245
64246
64247  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
64248
64249  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
64250  if test -n "$unique" && test "`eval $cmd`" = "" ; then
64251    eval "INCLUDEPATH$unique=set"
64252
64253      if test ""; then
64254        INCLUDES="-I$ai_p $INCLUDES"
64255      else
64256        INCLUDES="$INCLUDES -I$ai_p"
64257      fi
64258
64259  fi
64260
64261  fi
64262
64263
64264
64265  ext_builddir=ext/pgsql
64266  ext_srcdir=$abs_srcdir/ext/pgsql
64267  ext_dir=ext/pgsql
64268
64269  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
64270
64271  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
64272    PHP_PGSQL_SHARED=no
64273
64274
64275  case $ext_dir in
64276  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64277  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64278  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64279  esac
64280
64281
64282
64283  b_c_pre=$php_c_pre
64284  b_cxx_pre=$php_cxx_pre
64285  b_c_meta=$php_c_meta
64286  b_cxx_meta=$php_cxx_meta
64287  b_c_post=$php_c_post
64288  b_cxx_post=$php_cxx_post
64289  b_lo=$php_lo
64290
64291
64292  old_IFS=$IFS
64293  for ac_src in pgsql.c; do
64294
64295      IFS=.
64296      set $ac_src
64297      ac_obj=$1
64298      IFS=$old_IFS
64299
64300      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64301
64302      case $ac_src in
64303        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64304        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64305        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64306        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64307      esac
64308
64309      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64310
64311    cat >>Makefile.objects<<EOF
64312-include $ac_bdir$ac_obj.dep
64313$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64314	$ac_comp
64315EOF
64316  done
64317
64318
64319    EXT_STATIC="$EXT_STATIC pgsql;$ext_dir"
64320    if test "$ext_shared" != "nocli"; then
64321      EXT_CLI_STATIC="$EXT_CLI_STATIC pgsql;$ext_dir"
64322    fi
64323  else
64324    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
64325      PHP_PGSQL_SHARED=yes
64326
64327  case $ext_dir in
64328  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64329  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64330  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64331  esac
64332
64333
64334
64335  b_c_pre=$shared_c_pre
64336  b_cxx_pre=$shared_cxx_pre
64337  b_c_meta=$shared_c_meta
64338  b_cxx_meta=$shared_cxx_meta
64339  b_c_post=$shared_c_post
64340  b_cxx_post=$shared_cxx_post
64341  b_lo=$shared_lo
64342
64343
64344  old_IFS=$IFS
64345  for ac_src in pgsql.c; do
64346
64347      IFS=.
64348      set $ac_src
64349      ac_obj=$1
64350      IFS=$old_IFS
64351
64352      shared_objects_pgsql="$shared_objects_pgsql $ac_bdir$ac_obj.lo"
64353
64354      case $ac_src in
64355        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64356        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64357        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64358        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64359      esac
64360
64361      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64362
64363    cat >>Makefile.objects<<EOF
64364-include $ac_bdir$ac_obj.dep
64365$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64366	$ac_comp
64367EOF
64368  done
64369
64370
64371  install_modules="install-modules"
64372  suffix=la
64373
64374  case $host_alias in
64375    *aix*)
64376      additional_flags="-Wl,-G"
64377      ;;
64378  esac
64379
64380  if test "x" = "xyes"; then
64381    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pgsql.$suffix"
64382  else
64383    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pgsql.$suffix"
64384  fi
64385
64386  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pgsql"
64387
64388  cat >>Makefile.objects<<EOF
64389\$(phplibdir)/pgsql.$suffix: $ext_builddir/pgsql.$suffix
64390	\$(LIBTOOL) --mode=install cp $ext_builddir/pgsql.$suffix \$(phplibdir)
64391
64392$ext_builddir/pgsql.$suffix: \$(shared_objects_pgsql) \$(PGSQL_SHARED_DEPENDENCIES)
64393	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pgsql) \$(PGSQL_SHARED_LIBADD)
64394
64395EOF
64396
64397
64398printf "%s\n" "#define COMPILE_DL_PGSQL 1" >>confdefs.h
64399
64400    fi
64401  fi
64402
64403  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
64404    PHP_PGSQL_SHARED=no
64405    case "$PHP_SAPI" in
64406      cgi|embed|phpdbg)
64407
64408
64409  case $ext_dir in
64410  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64411  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64412  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64413  esac
64414
64415
64416
64417  b_c_pre=$php_c_pre
64418  b_cxx_pre=$php_cxx_pre
64419  b_c_meta=$php_c_meta
64420  b_cxx_meta=$php_cxx_meta
64421  b_c_post=$php_c_post
64422  b_cxx_post=$php_cxx_post
64423  b_lo=$php_lo
64424
64425
64426  old_IFS=$IFS
64427  for ac_src in pgsql.c; do
64428
64429      IFS=.
64430      set $ac_src
64431      ac_obj=$1
64432      IFS=$old_IFS
64433
64434      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64435
64436      case $ac_src in
64437        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64438        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64439        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64440        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64441      esac
64442
64443      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64444
64445    cat >>Makefile.objects<<EOF
64446-include $ac_bdir$ac_obj.dep
64447$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64448	$ac_comp
64449EOF
64450  done
64451
64452
64453        EXT_STATIC="$EXT_STATIC pgsql;$ext_dir"
64454        ;;
64455      *)
64456
64457
64458  case $ext_dir in
64459  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64460  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64461  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64462  esac
64463
64464
64465
64466  b_c_pre=$php_c_pre
64467  b_cxx_pre=$php_cxx_pre
64468  b_c_meta=$php_c_meta
64469  b_cxx_meta=$php_cxx_meta
64470  b_c_post=$php_c_post
64471  b_cxx_post=$php_cxx_post
64472  b_lo=$php_lo
64473
64474
64475  old_IFS=$IFS
64476  for ac_src in pgsql.c; do
64477
64478      IFS=.
64479      set $ac_src
64480      ac_obj=$1
64481      IFS=$old_IFS
64482
64483      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64484
64485      case $ac_src in
64486        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64487        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64488        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64489        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64490      esac
64491
64492      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64493
64494    cat >>Makefile.objects<<EOF
64495-include $ac_bdir$ac_obj.dep
64496$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64497	$ac_comp
64498EOF
64499  done
64500
64501
64502        ;;
64503    esac
64504    EXT_CLI_STATIC="$EXT_CLI_STATIC pgsql;$ext_dir"
64505  fi
64506
64507
64508    BUILD_DIR="$BUILD_DIR $ext_builddir"
64509
64510
64511
64512  if test "$ext_builddir" = "."; then
64513    PHP_PECL_EXTENSION=pgsql
64514
64515  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
64516
64517  fi
64518
64519fi
64520
64521
64522
64523
64524
64525php_enable_phar=yes
64526
64527{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phar archive support" >&5
64528printf %s "checking for phar archive support... " >&6; }
64529# Check whether --enable-phar was given.
64530if test ${enable_phar+y}
64531then :
64532  enableval=$enable_phar; PHP_PHAR=$enableval
64533else $as_nop
64534
64535  PHP_PHAR=yes
64536  test "$PHP_ENABLE_ALL" && PHP_PHAR=$PHP_ENABLE_ALL
64537
64538fi
64539
64540
64541
64542ext_output="yes, shared"
64543ext_shared=yes
64544case $PHP_PHAR in
64545shared,*)
64546  PHP_PHAR=`echo "$PHP_PHAR"|$SED 's/^shared,//'`
64547  ;;
64548shared)
64549  PHP_PHAR=yes
64550  ;;
64551no)
64552  ext_output=no
64553  ext_shared=no
64554  ;;
64555*)
64556  ext_output=yes
64557  ext_shared=no
64558  ;;
64559esac
64560
64561
64562
64563{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
64564printf "%s\n" "$ext_output" >&6; }
64565
64566
64567
64568
64569if test "$PHP_PHAR" != "no"; then
64570
64571  ext_builddir=ext/phar
64572  ext_srcdir=$abs_srcdir/ext/phar
64573  ext_dir=ext/phar
64574
64575  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
64576
64577  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
64578    PHP_PHAR_SHARED=no
64579
64580
64581  case $ext_dir in
64582  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64583  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64584  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64585  esac
64586
64587
64588
64589  b_c_pre=$php_c_pre
64590  b_cxx_pre=$php_cxx_pre
64591  b_c_meta=$php_c_meta
64592  b_cxx_meta=$php_cxx_meta
64593  b_c_post=$php_c_post
64594  b_cxx_post=$php_cxx_post
64595  b_lo=$php_lo
64596
64597
64598  old_IFS=$IFS
64599  for ac_src in util.c tar.c zip.c stream.c func_interceptors.c dirstream.c phar.c phar_object.c phar_path_check.c; do
64600
64601      IFS=.
64602      set $ac_src
64603      ac_obj=$1
64604      IFS=$old_IFS
64605
64606      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64607
64608      case $ac_src in
64609        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64610        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64611        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64612        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64613      esac
64614
64615      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64616
64617    cat >>Makefile.objects<<EOF
64618-include $ac_bdir$ac_obj.dep
64619$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64620	$ac_comp
64621EOF
64622  done
64623
64624
64625    EXT_STATIC="$EXT_STATIC phar;$ext_dir"
64626    if test "$ext_shared" != "nocli"; then
64627      EXT_CLI_STATIC="$EXT_CLI_STATIC phar;$ext_dir"
64628    fi
64629  else
64630    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
64631      PHP_PHAR_SHARED=yes
64632
64633  case $ext_dir in
64634  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64635  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64636  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64637  esac
64638
64639
64640
64641  b_c_pre=$shared_c_pre
64642  b_cxx_pre=$shared_cxx_pre
64643  b_c_meta=$shared_c_meta
64644  b_cxx_meta=$shared_cxx_meta
64645  b_c_post=$shared_c_post
64646  b_cxx_post=$shared_cxx_post
64647  b_lo=$shared_lo
64648
64649
64650  old_IFS=$IFS
64651  for ac_src in util.c tar.c zip.c stream.c func_interceptors.c dirstream.c phar.c phar_object.c phar_path_check.c; do
64652
64653      IFS=.
64654      set $ac_src
64655      ac_obj=$1
64656      IFS=$old_IFS
64657
64658      shared_objects_phar="$shared_objects_phar $ac_bdir$ac_obj.lo"
64659
64660      case $ac_src in
64661        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64662        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64663        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64664        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64665      esac
64666
64667      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64668
64669    cat >>Makefile.objects<<EOF
64670-include $ac_bdir$ac_obj.dep
64671$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64672	$ac_comp
64673EOF
64674  done
64675
64676
64677  install_modules="install-modules"
64678  suffix=la
64679
64680  case $host_alias in
64681    *aix*)
64682      additional_flags="-Wl,-G"
64683      ;;
64684  esac
64685
64686  if test "x" = "xyes"; then
64687    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/phar.$suffix"
64688  else
64689    PHP_MODULES="$PHP_MODULES \$(phplibdir)/phar.$suffix"
64690  fi
64691
64692  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_phar"
64693
64694  cat >>Makefile.objects<<EOF
64695\$(phplibdir)/phar.$suffix: $ext_builddir/phar.$suffix
64696	\$(LIBTOOL) --mode=install cp $ext_builddir/phar.$suffix \$(phplibdir)
64697
64698$ext_builddir/phar.$suffix: \$(shared_objects_phar) \$(PHAR_SHARED_DEPENDENCIES)
64699	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_phar) \$(PHAR_SHARED_LIBADD)
64700
64701EOF
64702
64703
64704printf "%s\n" "#define COMPILE_DL_PHAR 1" >>confdefs.h
64705
64706    fi
64707  fi
64708
64709  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
64710    PHP_PHAR_SHARED=no
64711    case "$PHP_SAPI" in
64712      cgi|embed|phpdbg)
64713
64714
64715  case $ext_dir in
64716  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64717  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64718  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64719  esac
64720
64721
64722
64723  b_c_pre=$php_c_pre
64724  b_cxx_pre=$php_cxx_pre
64725  b_c_meta=$php_c_meta
64726  b_cxx_meta=$php_cxx_meta
64727  b_c_post=$php_c_post
64728  b_cxx_post=$php_cxx_post
64729  b_lo=$php_lo
64730
64731
64732  old_IFS=$IFS
64733  for ac_src in util.c tar.c zip.c stream.c func_interceptors.c dirstream.c phar.c phar_object.c phar_path_check.c; do
64734
64735      IFS=.
64736      set $ac_src
64737      ac_obj=$1
64738      IFS=$old_IFS
64739
64740      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64741
64742      case $ac_src in
64743        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64744        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64745        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64746        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64747      esac
64748
64749      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64750
64751    cat >>Makefile.objects<<EOF
64752-include $ac_bdir$ac_obj.dep
64753$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64754	$ac_comp
64755EOF
64756  done
64757
64758
64759        EXT_STATIC="$EXT_STATIC phar;$ext_dir"
64760        ;;
64761      *)
64762
64763
64764  case $ext_dir in
64765  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64766  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64767  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64768  esac
64769
64770
64771
64772  b_c_pre=$php_c_pre
64773  b_cxx_pre=$php_cxx_pre
64774  b_c_meta=$php_c_meta
64775  b_cxx_meta=$php_cxx_meta
64776  b_c_post=$php_c_post
64777  b_cxx_post=$php_cxx_post
64778  b_lo=$php_lo
64779
64780
64781  old_IFS=$IFS
64782  for ac_src in util.c tar.c zip.c stream.c func_interceptors.c dirstream.c phar.c phar_object.c phar_path_check.c; do
64783
64784      IFS=.
64785      set $ac_src
64786      ac_obj=$1
64787      IFS=$old_IFS
64788
64789      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
64790
64791      case $ac_src in
64792        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64793        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64794        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
64795        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
64796      esac
64797
64798      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
64799
64800    cat >>Makefile.objects<<EOF
64801-include $ac_bdir$ac_obj.dep
64802$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
64803	$ac_comp
64804EOF
64805  done
64806
64807
64808        ;;
64809    esac
64810    EXT_CLI_STATIC="$EXT_CLI_STATIC phar;$ext_dir"
64811  fi
64812
64813
64814    BUILD_DIR="$BUILD_DIR $ext_builddir"
64815
64816
64817
64818  if test "$ext_builddir" = "."; then
64819    PHP_PECL_EXTENSION=phar
64820
64821  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
64822
64823  fi
64824
64825  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for phar openssl support" >&5
64826printf %s "checking for phar openssl support... " >&6; }
64827  if test "$PHP_OPENSSL_SHARED" = "yes"; then
64828    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no (shared openssl)" >&5
64829printf "%s\n" "no (shared openssl)" >&6; }
64830  else
64831    if test "$PHP_OPENSSL" = "yes"; then
64832      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
64833printf "%s\n" "yes" >&6; }
64834
64835printf "%s\n" "#define PHAR_HAVE_OPENSSL 1" >>confdefs.h
64836
64837    else
64838      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
64839printf "%s\n" "no" >&6; }
64840    fi
64841  fi
64842
64843  am_i_shared=$PHP_PHAR_SHARED
64844  is_it_shared=$PHP_HASH_SHARED
64845  is_it_enabled=$PHP_HASH
64846  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
64847    as_fn_error $? "
64848You've configured extension phar to build statically, but it
64849depends on extension hash, which you've configured to build shared.
64850You either need to build phar shared or build hash statically for the
64851build to be successful.
64852" "$LINENO" 5
64853  fi
64854  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
64855    as_fn_error $? "
64856You've configured extension phar, which depends on extension hash,
64857but you've either not enabled hash, or have disabled it.
64858" "$LINENO" 5
64859  fi
64860
64861
64862  am_i_shared=$PHP_PHAR_SHARED
64863  is_it_shared=$PHP_SPL_SHARED
64864  is_it_enabled=$PHP_SPL
64865  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
64866    as_fn_error $? "
64867You've configured extension phar to build statically, but it
64868depends on extension spl, which you've configured to build shared.
64869You either need to build phar shared or build spl statically for the
64870build to be successful.
64871" "$LINENO" 5
64872  fi
64873  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
64874    as_fn_error $? "
64875You've configured extension phar, which depends on extension spl,
64876but you've either not enabled spl, or have disabled it.
64877" "$LINENO" 5
64878  fi
64879
64880
64881  src=$ext_srcdir/Makefile.frag
64882  ac_srcdir=$ext_srcdir
64883  ac_builddir=$ext_builddir
64884  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
64885
64886
64887
64888
64889    header_path=ext/phar
64890    for header_file in php_phar.h; do
64891      hp_hf="$header_path/$header_file"
64892
64893
64894  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
64895
64896  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
64897  if test -n "$unique" && test "`eval $cmd`" = "" ; then
64898    eval "INSTALLHEADERS$unique=set"
64899
64900        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
64901
64902  fi
64903
64904    done
64905
64906
64907
64908
64909  PHP_OUTPUT_FILES="$PHP_OUTPUT_FILES ext/phar/phar.1 ext/phar/phar.phar.1"
64910
64911fi
64912
64913
64914
64915
64916
64917php_enable_posix=yes
64918
64919{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable POSIX-like functions" >&5
64920printf %s "checking whether to enable POSIX-like functions... " >&6; }
64921# Check whether --enable-posix was given.
64922if test ${enable_posix+y}
64923then :
64924  enableval=$enable_posix; PHP_POSIX=$enableval
64925else $as_nop
64926
64927  PHP_POSIX=yes
64928  test "$PHP_ENABLE_ALL" && PHP_POSIX=$PHP_ENABLE_ALL
64929
64930fi
64931
64932
64933
64934ext_output="yes, shared"
64935ext_shared=yes
64936case $PHP_POSIX in
64937shared,*)
64938  PHP_POSIX=`echo "$PHP_POSIX"|$SED 's/^shared,//'`
64939  ;;
64940shared)
64941  PHP_POSIX=yes
64942  ;;
64943no)
64944  ext_output=no
64945  ext_shared=no
64946  ;;
64947*)
64948  ext_output=yes
64949  ext_shared=no
64950  ;;
64951esac
64952
64953
64954
64955{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
64956printf "%s\n" "$ext_output" >&6; }
64957
64958
64959
64960
64961if test "$PHP_POSIX" = "yes"; then
64962
64963printf "%s\n" "#define HAVE_POSIX 1" >>confdefs.h
64964
64965
64966  ext_builddir=ext/posix
64967  ext_srcdir=$abs_srcdir/ext/posix
64968  ext_dir=ext/posix
64969
64970  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
64971
64972  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
64973    PHP_POSIX_SHARED=no
64974
64975
64976  case $ext_dir in
64977  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
64978  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
64979  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
64980  esac
64981
64982
64983
64984  b_c_pre=$php_c_pre
64985  b_cxx_pre=$php_cxx_pre
64986  b_c_meta=$php_c_meta
64987  b_cxx_meta=$php_cxx_meta
64988  b_c_post=$php_c_post
64989  b_cxx_post=$php_cxx_post
64990  b_lo=$php_lo
64991
64992
64993  old_IFS=$IFS
64994  for ac_src in posix.c; do
64995
64996      IFS=.
64997      set $ac_src
64998      ac_obj=$1
64999      IFS=$old_IFS
65000
65001      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65002
65003      case $ac_src in
65004        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65005        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65006        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65007        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65008      esac
65009
65010      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65011
65012    cat >>Makefile.objects<<EOF
65013-include $ac_bdir$ac_obj.dep
65014$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65015	$ac_comp
65016EOF
65017  done
65018
65019
65020    EXT_STATIC="$EXT_STATIC posix;$ext_dir"
65021    if test "$ext_shared" != "nocli"; then
65022      EXT_CLI_STATIC="$EXT_CLI_STATIC posix;$ext_dir"
65023    fi
65024  else
65025    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
65026      PHP_POSIX_SHARED=yes
65027
65028  case $ext_dir in
65029  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65030  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65031  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65032  esac
65033
65034
65035
65036  b_c_pre=$shared_c_pre
65037  b_cxx_pre=$shared_cxx_pre
65038  b_c_meta=$shared_c_meta
65039  b_cxx_meta=$shared_cxx_meta
65040  b_c_post=$shared_c_post
65041  b_cxx_post=$shared_cxx_post
65042  b_lo=$shared_lo
65043
65044
65045  old_IFS=$IFS
65046  for ac_src in posix.c; do
65047
65048      IFS=.
65049      set $ac_src
65050      ac_obj=$1
65051      IFS=$old_IFS
65052
65053      shared_objects_posix="$shared_objects_posix $ac_bdir$ac_obj.lo"
65054
65055      case $ac_src in
65056        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65057        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65058        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65059        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65060      esac
65061
65062      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65063
65064    cat >>Makefile.objects<<EOF
65065-include $ac_bdir$ac_obj.dep
65066$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65067	$ac_comp
65068EOF
65069  done
65070
65071
65072  install_modules="install-modules"
65073  suffix=la
65074
65075  case $host_alias in
65076    *aix*)
65077      additional_flags="-Wl,-G"
65078      ;;
65079  esac
65080
65081  if test "x" = "xyes"; then
65082    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/posix.$suffix"
65083  else
65084    PHP_MODULES="$PHP_MODULES \$(phplibdir)/posix.$suffix"
65085  fi
65086
65087  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_posix"
65088
65089  cat >>Makefile.objects<<EOF
65090\$(phplibdir)/posix.$suffix: $ext_builddir/posix.$suffix
65091	\$(LIBTOOL) --mode=install cp $ext_builddir/posix.$suffix \$(phplibdir)
65092
65093$ext_builddir/posix.$suffix: \$(shared_objects_posix) \$(POSIX_SHARED_DEPENDENCIES)
65094	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_posix) \$(POSIX_SHARED_LIBADD)
65095
65096EOF
65097
65098
65099printf "%s\n" "#define COMPILE_DL_POSIX 1" >>confdefs.h
65100
65101    fi
65102  fi
65103
65104  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
65105    PHP_POSIX_SHARED=no
65106    case "$PHP_SAPI" in
65107      cgi|embed|phpdbg)
65108
65109
65110  case $ext_dir in
65111  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65112  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65113  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65114  esac
65115
65116
65117
65118  b_c_pre=$php_c_pre
65119  b_cxx_pre=$php_cxx_pre
65120  b_c_meta=$php_c_meta
65121  b_cxx_meta=$php_cxx_meta
65122  b_c_post=$php_c_post
65123  b_cxx_post=$php_cxx_post
65124  b_lo=$php_lo
65125
65126
65127  old_IFS=$IFS
65128  for ac_src in posix.c; do
65129
65130      IFS=.
65131      set $ac_src
65132      ac_obj=$1
65133      IFS=$old_IFS
65134
65135      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65136
65137      case $ac_src in
65138        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65139        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65140        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65141        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65142      esac
65143
65144      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65145
65146    cat >>Makefile.objects<<EOF
65147-include $ac_bdir$ac_obj.dep
65148$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65149	$ac_comp
65150EOF
65151  done
65152
65153
65154        EXT_STATIC="$EXT_STATIC posix;$ext_dir"
65155        ;;
65156      *)
65157
65158
65159  case $ext_dir in
65160  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65161  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65162  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65163  esac
65164
65165
65166
65167  b_c_pre=$php_c_pre
65168  b_cxx_pre=$php_cxx_pre
65169  b_c_meta=$php_c_meta
65170  b_cxx_meta=$php_cxx_meta
65171  b_c_post=$php_c_post
65172  b_cxx_post=$php_cxx_post
65173  b_lo=$php_lo
65174
65175
65176  old_IFS=$IFS
65177  for ac_src in posix.c; do
65178
65179      IFS=.
65180      set $ac_src
65181      ac_obj=$1
65182      IFS=$old_IFS
65183
65184      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65185
65186      case $ac_src in
65187        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65188        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65189        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65190        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65191      esac
65192
65193      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65194
65195    cat >>Makefile.objects<<EOF
65196-include $ac_bdir$ac_obj.dep
65197$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65198	$ac_comp
65199EOF
65200  done
65201
65202
65203        ;;
65204    esac
65205    EXT_CLI_STATIC="$EXT_CLI_STATIC posix;$ext_dir"
65206  fi
65207
65208
65209    BUILD_DIR="$BUILD_DIR $ext_builddir"
65210
65211
65212
65213  if test "$ext_builddir" = "."; then
65214    PHP_PECL_EXTENSION=posix
65215
65216  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
65217
65218  fi
65219
65220
65221  ac_fn_c_check_header_compile "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
65222if test "x$ac_cv_header_sys_mkdev_h" = xyes
65223then :
65224  printf "%s\n" "#define HAVE_SYS_MKDEV_H 1" >>confdefs.h
65225
65226fi
65227ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
65228if test "x$ac_cv_header_sys_sysmacros_h" = xyes
65229then :
65230  printf "%s\n" "#define HAVE_SYS_SYSMACROS_H 1" >>confdefs.h
65231
65232fi
65233
65234
65235  ac_fn_c_check_func "$LINENO" "seteuid" "ac_cv_func_seteuid"
65236if test "x$ac_cv_func_seteuid" = xyes
65237then :
65238  printf "%s\n" "#define HAVE_SETEUID 1" >>confdefs.h
65239
65240fi
65241ac_fn_c_check_func "$LINENO" "setegid" "ac_cv_func_setegid"
65242if test "x$ac_cv_func_setegid" = xyes
65243then :
65244  printf "%s\n" "#define HAVE_SETEGID 1" >>confdefs.h
65245
65246fi
65247ac_fn_c_check_func "$LINENO" "setsid" "ac_cv_func_setsid"
65248if test "x$ac_cv_func_setsid" = xyes
65249then :
65250  printf "%s\n" "#define HAVE_SETSID 1" >>confdefs.h
65251
65252fi
65253ac_fn_c_check_func "$LINENO" "getsid" "ac_cv_func_getsid"
65254if test "x$ac_cv_func_getsid" = xyes
65255then :
65256  printf "%s\n" "#define HAVE_GETSID 1" >>confdefs.h
65257
65258fi
65259ac_fn_c_check_func "$LINENO" "getpgid" "ac_cv_func_getpgid"
65260if test "x$ac_cv_func_getpgid" = xyes
65261then :
65262  printf "%s\n" "#define HAVE_GETPGID 1" >>confdefs.h
65263
65264fi
65265ac_fn_c_check_func "$LINENO" "ctermid" "ac_cv_func_ctermid"
65266if test "x$ac_cv_func_ctermid" = xyes
65267then :
65268  printf "%s\n" "#define HAVE_CTERMID 1" >>confdefs.h
65269
65270fi
65271ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo"
65272if test "x$ac_cv_func_mkfifo" = xyes
65273then :
65274  printf "%s\n" "#define HAVE_MKFIFO 1" >>confdefs.h
65275
65276fi
65277ac_fn_c_check_func "$LINENO" "mknod" "ac_cv_func_mknod"
65278if test "x$ac_cv_func_mknod" = xyes
65279then :
65280  printf "%s\n" "#define HAVE_MKNOD 1" >>confdefs.h
65281
65282fi
65283ac_fn_c_check_func "$LINENO" "setrlimit" "ac_cv_func_setrlimit"
65284if test "x$ac_cv_func_setrlimit" = xyes
65285then :
65286  printf "%s\n" "#define HAVE_SETRLIMIT 1" >>confdefs.h
65287
65288fi
65289ac_fn_c_check_func "$LINENO" "getrlimit" "ac_cv_func_getrlimit"
65290if test "x$ac_cv_func_getrlimit" = xyes
65291then :
65292  printf "%s\n" "#define HAVE_GETRLIMIT 1" >>confdefs.h
65293
65294fi
65295ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
65296if test "x$ac_cv_func_getgroups" = xyes
65297then :
65298  printf "%s\n" "#define HAVE_GETGROUPS 1" >>confdefs.h
65299
65300fi
65301ac_fn_c_check_func "$LINENO" "makedev" "ac_cv_func_makedev"
65302if test "x$ac_cv_func_makedev" = xyes
65303then :
65304  printf "%s\n" "#define HAVE_MAKEDEV 1" >>confdefs.h
65305
65306fi
65307ac_fn_c_check_func "$LINENO" "initgroups" "ac_cv_func_initgroups"
65308if test "x$ac_cv_func_initgroups" = xyes
65309then :
65310  printf "%s\n" "#define HAVE_INITGROUPS 1" >>confdefs.h
65311
65312fi
65313ac_fn_c_check_func "$LINENO" "getgrgid_r" "ac_cv_func_getgrgid_r"
65314if test "x$ac_cv_func_getgrgid_r" = xyes
65315then :
65316  printf "%s\n" "#define HAVE_GETGRGID_R 1" >>confdefs.h
65317
65318fi
65319
65320
65321  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working ttyname_r() implementation" >&5
65322printf %s "checking for working ttyname_r() implementation... " >&6; }
65323  if test "$cross_compiling" = yes
65324then :
65325
65326    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, cannot detect working ttyname_r() when cross compiling. posix_ttyname() will be thread-unsafe" >&5
65327printf "%s\n" "no, cannot detect working ttyname_r() when cross compiling. posix_ttyname() will be thread-unsafe" >&6; }
65328
65329else $as_nop
65330  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65331/* end confdefs.h.  */
65332
65333#include <unistd.h>
65334
65335int main(int argc, char *argv[])
65336{
65337	char buf[64];
65338
65339	return !ttyname_r(0, buf, 64);
65340}
65341
65342_ACEOF
65343if ac_fn_c_try_run "$LINENO"
65344then :
65345
65346    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
65347printf "%s\n" "yes" >&6; }
65348
65349printf "%s\n" "#define HAVE_TTYNAME_R 1" >>confdefs.h
65350
65351
65352else $as_nop
65353
65354    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, posix_ttyname() will be thread-unsafe" >&5
65355printf "%s\n" "no, posix_ttyname() will be thread-unsafe" >&6; }
65356
65357fi
65358rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
65359  conftest.$ac_objext conftest.beam conftest.$ac_ext
65360fi
65361
65362
65363  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for utsname.domainname" >&5
65364printf %s "checking for utsname.domainname... " >&6; }
65365if test ${ac_cv_have_utsname_domainname+y}
65366then :
65367  printf %s "(cached) " >&6
65368else $as_nop
65369
65370    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65371/* end confdefs.h.  */
65372
65373      #define _GNU_SOURCE
65374      #include <sys/utsname.h>
65375
65376int
65377main (void)
65378{
65379
65380      return sizeof(((struct utsname *)0)->domainname);
65381
65382  ;
65383  return 0;
65384}
65385_ACEOF
65386if ac_fn_c_try_compile "$LINENO"
65387then :
65388
65389      ac_cv_have_utsname_domainname=yes
65390
65391else $as_nop
65392
65393      ac_cv_have_utsname_domainname=no
65394
65395fi
65396rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
65397
65398fi
65399{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_utsname_domainname" >&5
65400printf "%s\n" "$ac_cv_have_utsname_domainname" >&6; }
65401  if test "$ac_cv_have_utsname_domainname" = yes; then
65402
65403printf "%s\n" "#define HAVE_UTSNAME_DOMAINNAME 1" >>confdefs.h
65404
65405  fi
65406fi
65407
65408
65409
65410
65411
65412php_with_pspell=no
65413
65414{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PSPELL support" >&5
65415printf %s "checking for PSPELL support... " >&6; }
65416
65417# Check whether --with-pspell was given.
65418if test ${with_pspell+y}
65419then :
65420  withval=$with_pspell; PHP_PSPELL=$withval
65421else $as_nop
65422
65423  PHP_PSPELL=no
65424  test "$PHP_ENABLE_ALL" && PHP_PSPELL=$PHP_ENABLE_ALL
65425
65426fi
65427
65428
65429
65430ext_output="yes, shared"
65431ext_shared=yes
65432case $PHP_PSPELL in
65433shared,*)
65434  PHP_PSPELL=`echo "$PHP_PSPELL"|$SED 's/^shared,//'`
65435  ;;
65436shared)
65437  PHP_PSPELL=yes
65438  ;;
65439no)
65440  ext_output=no
65441  ext_shared=no
65442  ;;
65443*)
65444  ext_output=yes
65445  ext_shared=no
65446  ;;
65447esac
65448
65449
65450
65451{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
65452printf "%s\n" "$ext_output" >&6; }
65453
65454
65455
65456
65457if test "$PHP_PSPELL" != "no"; then
65458
65459  ext_builddir=ext/pspell
65460  ext_srcdir=$abs_srcdir/ext/pspell
65461  ext_dir=ext/pspell
65462
65463  ac_extra=`echo ""-Wno-strict-prototypes""|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
65464
65465  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
65466    PHP_PSPELL_SHARED=no
65467
65468
65469  case $ext_dir in
65470  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65471  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65472  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65473  esac
65474
65475
65476
65477  b_c_pre=$php_c_pre
65478  b_cxx_pre=$php_cxx_pre
65479  b_c_meta=$php_c_meta
65480  b_cxx_meta=$php_cxx_meta
65481  b_c_post=$php_c_post
65482  b_cxx_post=$php_cxx_post
65483  b_lo=$php_lo
65484
65485
65486  old_IFS=$IFS
65487  for ac_src in pspell.c; do
65488
65489      IFS=.
65490      set $ac_src
65491      ac_obj=$1
65492      IFS=$old_IFS
65493
65494      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65495
65496      case $ac_src in
65497        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65498        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65499        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65500        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65501      esac
65502
65503      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65504
65505    cat >>Makefile.objects<<EOF
65506-include $ac_bdir$ac_obj.dep
65507$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65508	$ac_comp
65509EOF
65510  done
65511
65512
65513    EXT_STATIC="$EXT_STATIC pspell;$ext_dir"
65514    if test "$ext_shared" != "nocli"; then
65515      EXT_CLI_STATIC="$EXT_CLI_STATIC pspell;$ext_dir"
65516    fi
65517  else
65518    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
65519      PHP_PSPELL_SHARED=yes
65520
65521  case $ext_dir in
65522  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65523  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65524  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65525  esac
65526
65527
65528
65529  b_c_pre=$shared_c_pre
65530  b_cxx_pre=$shared_cxx_pre
65531  b_c_meta=$shared_c_meta
65532  b_cxx_meta=$shared_cxx_meta
65533  b_c_post=$shared_c_post
65534  b_cxx_post=$shared_cxx_post
65535  b_lo=$shared_lo
65536
65537
65538  old_IFS=$IFS
65539  for ac_src in pspell.c; do
65540
65541      IFS=.
65542      set $ac_src
65543      ac_obj=$1
65544      IFS=$old_IFS
65545
65546      shared_objects_pspell="$shared_objects_pspell $ac_bdir$ac_obj.lo"
65547
65548      case $ac_src in
65549        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65550        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65551        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65552        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65553      esac
65554
65555      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65556
65557    cat >>Makefile.objects<<EOF
65558-include $ac_bdir$ac_obj.dep
65559$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65560	$ac_comp
65561EOF
65562  done
65563
65564
65565  install_modules="install-modules"
65566  suffix=la
65567
65568  case $host_alias in
65569    *aix*)
65570      additional_flags="-Wl,-G"
65571      ;;
65572  esac
65573
65574  if test "x" = "xyes"; then
65575    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/pspell.$suffix"
65576  else
65577    PHP_MODULES="$PHP_MODULES \$(phplibdir)/pspell.$suffix"
65578  fi
65579
65580  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_pspell"
65581
65582  cat >>Makefile.objects<<EOF
65583\$(phplibdir)/pspell.$suffix: $ext_builddir/pspell.$suffix
65584	\$(LIBTOOL) --mode=install cp $ext_builddir/pspell.$suffix \$(phplibdir)
65585
65586$ext_builddir/pspell.$suffix: \$(shared_objects_pspell) \$(PSPELL_SHARED_DEPENDENCIES)
65587	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_pspell) \$(PSPELL_SHARED_LIBADD)
65588
65589EOF
65590
65591
65592printf "%s\n" "#define COMPILE_DL_PSPELL 1" >>confdefs.h
65593
65594    fi
65595  fi
65596
65597  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
65598    PHP_PSPELL_SHARED=no
65599    case "$PHP_SAPI" in
65600      cgi|embed|phpdbg)
65601
65602
65603  case $ext_dir in
65604  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65605  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65606  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65607  esac
65608
65609
65610
65611  b_c_pre=$php_c_pre
65612  b_cxx_pre=$php_cxx_pre
65613  b_c_meta=$php_c_meta
65614  b_cxx_meta=$php_cxx_meta
65615  b_c_post=$php_c_post
65616  b_cxx_post=$php_cxx_post
65617  b_lo=$php_lo
65618
65619
65620  old_IFS=$IFS
65621  for ac_src in pspell.c; do
65622
65623      IFS=.
65624      set $ac_src
65625      ac_obj=$1
65626      IFS=$old_IFS
65627
65628      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65629
65630      case $ac_src in
65631        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65632        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65633        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65634        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65635      esac
65636
65637      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65638
65639    cat >>Makefile.objects<<EOF
65640-include $ac_bdir$ac_obj.dep
65641$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65642	$ac_comp
65643EOF
65644  done
65645
65646
65647        EXT_STATIC="$EXT_STATIC pspell;$ext_dir"
65648        ;;
65649      *)
65650
65651
65652  case $ext_dir in
65653  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
65654  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
65655  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
65656  esac
65657
65658
65659
65660  b_c_pre=$php_c_pre
65661  b_cxx_pre=$php_cxx_pre
65662  b_c_meta=$php_c_meta
65663  b_cxx_meta=$php_cxx_meta
65664  b_c_post=$php_c_post
65665  b_cxx_post=$php_cxx_post
65666  b_lo=$php_lo
65667
65668
65669  old_IFS=$IFS
65670  for ac_src in pspell.c; do
65671
65672      IFS=.
65673      set $ac_src
65674      ac_obj=$1
65675      IFS=$old_IFS
65676
65677      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
65678
65679      case $ac_src in
65680        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65681        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65682        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
65683        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
65684      esac
65685
65686      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
65687
65688    cat >>Makefile.objects<<EOF
65689-include $ac_bdir$ac_obj.dep
65690$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
65691	$ac_comp
65692EOF
65693  done
65694
65695
65696        ;;
65697    esac
65698    EXT_CLI_STATIC="$EXT_CLI_STATIC pspell;$ext_dir"
65699  fi
65700
65701
65702    BUILD_DIR="$BUILD_DIR $ext_builddir"
65703
65704
65705
65706  if test "$ext_builddir" = "."; then
65707    PHP_PECL_EXTENSION=pspell
65708
65709  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
65710
65711  fi
65712
65713	if test "$PHP_PSPELL" != "yes"; then
65714	    PSPELL_SEARCH_DIRS=$PHP_PSPELL
65715	else
65716	    PSPELL_SEARCH_DIRS="/usr/local /usr"
65717	fi
65718	for i in $PSPELL_SEARCH_DIRS; do
65719		if test -f $i/include/pspell/pspell.h; then
65720			PSPELL_DIR=$i
65721			PSPELL_INCDIR=$i/include/pspell
65722		elif test -f $i/include/pspell.h; then
65723			PSPELL_DIR=$i
65724			PSPELL_INCDIR=$i/include
65725		fi
65726	done
65727
65728	if test -z "$PSPELL_DIR"; then
65729		as_fn_error $? "Cannot find pspell" "$LINENO" 5
65730	fi
65731
65732	PSPELL_LIBDIR=$PSPELL_DIR/$PHP_LIBDIR
65733
65734
65735
65736  if test "$ext_shared" = "yes"; then
65737    PSPELL_SHARED_LIBADD="-lpspell $PSPELL_SHARED_LIBADD"
65738    if test -n "$PSPELL_LIBDIR"; then
65739
65740  if test "$PSPELL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PSPELL_LIBDIR" != "/usr/lib"; then
65741
65742  if test -z "$PSPELL_LIBDIR" || echo "$PSPELL_LIBDIR" | grep '^/' >/dev/null ; then
65743    ai_p=$PSPELL_LIBDIR
65744  else
65745
65746    ep_dir=`echo $PSPELL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
65747
65748    ep_realdir=`(cd "$ep_dir" && pwd)`
65749    ai_p="$ep_realdir"/`basename "$PSPELL_LIBDIR"`
65750  fi
65751
65752
65753      if test "$ext_shared" = "yes"; then
65754        PSPELL_SHARED_LIBADD="-L$ai_p $PSPELL_SHARED_LIBADD"
65755        test -n "$ld_runpath_switch" && PSPELL_SHARED_LIBADD="$ld_runpath_switch$ai_p $PSPELL_SHARED_LIBADD"
65756      else
65757
65758
65759
65760  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
65761
65762  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
65763  if test -n "$unique" && test "`eval $cmd`" = "" ; then
65764    eval "LIBPATH$unique=set"
65765
65766    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
65767    LDFLAGS="$LDFLAGS -L$ai_p"
65768    PHP_RPATHS="$PHP_RPATHS $ai_p"
65769
65770  fi
65771
65772
65773      fi
65774
65775  fi
65776
65777    fi
65778  else
65779
65780
65781  if test -n "$PSPELL_LIBDIR"; then
65782
65783  if test "$PSPELL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PSPELL_LIBDIR" != "/usr/lib"; then
65784
65785  if test -z "$PSPELL_LIBDIR" || echo "$PSPELL_LIBDIR" | grep '^/' >/dev/null ; then
65786    ai_p=$PSPELL_LIBDIR
65787  else
65788
65789    ep_dir=`echo $PSPELL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
65790
65791    ep_realdir=`(cd "$ep_dir" && pwd)`
65792    ai_p="$ep_realdir"/`basename "$PSPELL_LIBDIR"`
65793  fi
65794
65795
65796
65797
65798
65799  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
65800
65801  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
65802  if test -n "$unique" && test "`eval $cmd`" = "" ; then
65803    eval "LIBPATH$unique=set"
65804
65805    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
65806    LDFLAGS="$LDFLAGS -L$ai_p"
65807    PHP_RPATHS="$PHP_RPATHS $ai_p"
65808
65809  fi
65810
65811
65812
65813  fi
65814
65815  fi
65816
65817
65818  case pspell in
65819  c|c_r) ;;
65820  *)
65821      LIBS="-lpspell $LIBS"
65822   ;;
65823  esac
65824
65825
65826
65827
65828  fi
65829
65830
65831
65832
65833  save_old_LDFLAGS=$LDFLAGS
65834  ac_stuff="
65835		-L$PSPELL_LIBDIR
65836	"
65837
65838  save_ext_shared=$ext_shared
65839  ext_shared=yes
65840
65841  for ac_i in $ac_stuff; do
65842    case $ac_i in
65843    -pthread)
65844      if test "$ext_shared" = "yes"; then
65845        LDFLAGS="$LDFLAGS -pthread"
65846      else
65847
65848
65849  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
65850
65851  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
65852  if test -n "$unique" && test "`eval $cmd`" = "" ; then
65853    eval "EXTRA_LDFLAGS$unique=set"
65854    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
65855  fi
65856
65857
65858
65859  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
65860
65861  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
65862  if test -n "$unique" && test "`eval $cmd`" = "" ; then
65863    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
65864    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
65865  fi
65866
65867      fi
65868    ;;
65869    -l*)
65870      ac_ii=`echo $ac_i|cut -c 3-`
65871
65872
65873  case $ac_ii in
65874  c|c_r) ;;
65875  *)
65876    if test "$ext_shared" = "yes"; then
65877        LDFLAGS="$LDFLAGS -l$ac_ii"
65878    else
65879
65880
65881  case $ac_ii in
65882  c|c_r) ;;
65883  *)
65884      LIBS="$LIBS -l$ac_ii"
65885   ;;
65886  esac
65887
65888
65889    fi
65890   ;;
65891  esac
65892
65893
65894    ;;
65895    -L*)
65896      ac_ii=`echo $ac_i|cut -c 3-`
65897
65898  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
65899
65900  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
65901    ai_p=$ac_ii
65902  else
65903
65904    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
65905
65906    ep_realdir=`(cd "$ep_dir" && pwd)`
65907    ai_p="$ep_realdir"/`basename "$ac_ii"`
65908  fi
65909
65910
65911      if test "$ext_shared" = "yes"; then
65912        LDFLAGS="-L$ai_p $LDFLAGS"
65913        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
65914      else
65915
65916
65917
65918  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
65919
65920  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
65921  if test -n "$unique" && test "`eval $cmd`" = "" ; then
65922    eval "LIBPATH$unique=set"
65923
65924    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
65925    LDFLAGS="$LDFLAGS -L$ai_p"
65926    PHP_RPATHS="$PHP_RPATHS $ai_p"
65927
65928  fi
65929
65930
65931      fi
65932
65933  fi
65934
65935    ;;
65936    esac
65937  done
65938
65939  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for new_aspell_config in -laspell" >&5
65940printf %s "checking for new_aspell_config in -laspell... " >&6; }
65941if test ${ac_cv_lib_aspell_new_aspell_config+y}
65942then :
65943  printf %s "(cached) " >&6
65944else $as_nop
65945  ac_check_lib_save_LIBS=$LIBS
65946LIBS="-laspell  $LIBS"
65947cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65948/* end confdefs.h.  */
65949
65950/* Override any GCC internal prototype to avoid an error.
65951   Use char because int might match the return type of a GCC
65952   builtin and then its argument prototype would still apply.  */
65953char new_aspell_config ();
65954int
65955main (void)
65956{
65957return new_aspell_config ();
65958  ;
65959  return 0;
65960}
65961_ACEOF
65962if ac_fn_c_try_link "$LINENO"
65963then :
65964  ac_cv_lib_aspell_new_aspell_config=yes
65965else $as_nop
65966  ac_cv_lib_aspell_new_aspell_config=no
65967fi
65968rm -f core conftest.err conftest.$ac_objext conftest.beam \
65969    conftest$ac_exeext conftest.$ac_ext
65970LIBS=$ac_check_lib_save_LIBS
65971fi
65972{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_aspell_new_aspell_config" >&5
65973printf "%s\n" "$ac_cv_lib_aspell_new_aspell_config" >&6; }
65974if test "x$ac_cv_lib_aspell_new_aspell_config" = xyes
65975then :
65976
65977    LDFLAGS=$save_old_LDFLAGS
65978    ext_shared=$save_ext_shared
65979
65980
65981
65982  if test "$ext_shared" = "yes"; then
65983    PSPELL_SHARED_LIBADD="-laspell $PSPELL_SHARED_LIBADD"
65984    if test -n "$PSPELL_LIBDIR"; then
65985
65986  if test "$PSPELL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PSPELL_LIBDIR" != "/usr/lib"; then
65987
65988  if test -z "$PSPELL_LIBDIR" || echo "$PSPELL_LIBDIR" | grep '^/' >/dev/null ; then
65989    ai_p=$PSPELL_LIBDIR
65990  else
65991
65992    ep_dir=`echo $PSPELL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
65993
65994    ep_realdir=`(cd "$ep_dir" && pwd)`
65995    ai_p="$ep_realdir"/`basename "$PSPELL_LIBDIR"`
65996  fi
65997
65998
65999      if test "$ext_shared" = "yes"; then
66000        PSPELL_SHARED_LIBADD="-L$ai_p $PSPELL_SHARED_LIBADD"
66001        test -n "$ld_runpath_switch" && PSPELL_SHARED_LIBADD="$ld_runpath_switch$ai_p $PSPELL_SHARED_LIBADD"
66002      else
66003
66004
66005
66006  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66007
66008  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66009  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66010    eval "LIBPATH$unique=set"
66011
66012    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66013    LDFLAGS="$LDFLAGS -L$ai_p"
66014    PHP_RPATHS="$PHP_RPATHS $ai_p"
66015
66016  fi
66017
66018
66019      fi
66020
66021  fi
66022
66023    fi
66024  else
66025
66026
66027  if test -n "$PSPELL_LIBDIR"; then
66028
66029  if test "$PSPELL_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$PSPELL_LIBDIR" != "/usr/lib"; then
66030
66031  if test -z "$PSPELL_LIBDIR" || echo "$PSPELL_LIBDIR" | grep '^/' >/dev/null ; then
66032    ai_p=$PSPELL_LIBDIR
66033  else
66034
66035    ep_dir=`echo $PSPELL_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
66036
66037    ep_realdir=`(cd "$ep_dir" && pwd)`
66038    ai_p="$ep_realdir"/`basename "$PSPELL_LIBDIR"`
66039  fi
66040
66041
66042
66043
66044
66045  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66046
66047  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66048  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66049    eval "LIBPATH$unique=set"
66050
66051    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66052    LDFLAGS="$LDFLAGS -L$ai_p"
66053    PHP_RPATHS="$PHP_RPATHS $ai_p"
66054
66055  fi
66056
66057
66058
66059  fi
66060
66061  fi
66062
66063
66064  case aspell in
66065  c|c_r) ;;
66066  *)
66067      LIBS="-laspell $LIBS"
66068   ;;
66069  esac
66070
66071
66072
66073
66074  fi
66075
66076
66077
66078
66079else $as_nop
66080
66081    LDFLAGS=$save_old_LDFLAGS
66082    ext_shared=$save_ext_shared
66083    unset ac_cv_lib_aspell_new_aspell_config
66084
66085
66086fi
66087
66088
66089
66090  if test "$PSPELL_INCDIR" != "/usr/include"; then
66091
66092  if test -z "$PSPELL_INCDIR" || echo "$PSPELL_INCDIR" | grep '^/' >/dev/null ; then
66093    ai_p=$PSPELL_INCDIR
66094  else
66095
66096    ep_dir=`echo $PSPELL_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
66097
66098    ep_realdir=`(cd "$ep_dir" && pwd)`
66099    ai_p="$ep_realdir"/`basename "$PSPELL_INCDIR"`
66100  fi
66101
66102
66103
66104  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66105
66106  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
66107  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66108    eval "INCLUDEPATH$unique=set"
66109
66110      if test ""; then
66111        INCLUDES="-I$ai_p $INCLUDES"
66112      else
66113        INCLUDES="$INCLUDES -I$ai_p"
66114      fi
66115
66116  fi
66117
66118  fi
66119
66120
66121  PHP_VAR_SUBST="$PHP_VAR_SUBST PSPELL_SHARED_LIBADD"
66122
66123
66124printf "%s\n" "#define HAVE_PSPELL 1" >>confdefs.h
66125
66126fi
66127
66128
66129
66130
66131
66132php_with_libedit=no
66133
66134{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libedit readline replacement" >&5
66135printf %s "checking for libedit readline replacement... " >&6; }
66136
66137# Check whether --with-libedit was given.
66138if test ${with_libedit+y}
66139then :
66140  withval=$with_libedit; PHP_LIBEDIT=$withval
66141else $as_nop
66142
66143  PHP_LIBEDIT=no
66144  test "$PHP_ENABLE_ALL" && PHP_LIBEDIT=$PHP_ENABLE_ALL
66145
66146fi
66147
66148
66149
66150ext_output="yes, shared"
66151ext_shared=yes
66152case $PHP_LIBEDIT in
66153shared,*)
66154  PHP_LIBEDIT=`echo "$PHP_LIBEDIT"|$SED 's/^shared,//'`
66155  ;;
66156shared)
66157  PHP_LIBEDIT=yes
66158  ;;
66159no)
66160  ext_output=no
66161  ext_shared=no
66162  ;;
66163*)
66164  ext_output=yes
66165  ext_shared=no
66166  ;;
66167esac
66168
66169
66170
66171{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
66172printf "%s\n" "$ext_output" >&6; }
66173
66174
66175
66176
66177if test "$PHP_LIBEDIT" = "no"; then
66178
66179php_with_readline=no
66180
66181{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for readline support" >&5
66182printf %s "checking for readline support... " >&6; }
66183
66184# Check whether --with-readline was given.
66185if test ${with_readline+y}
66186then :
66187  withval=$with_readline; PHP_READLINE=$withval
66188else $as_nop
66189
66190  PHP_READLINE=no
66191  test "$PHP_ENABLE_ALL" && PHP_READLINE=$PHP_ENABLE_ALL
66192
66193fi
66194
66195
66196
66197ext_output="yes, shared"
66198ext_shared=yes
66199case $PHP_READLINE in
66200shared,*)
66201  PHP_READLINE=`echo "$PHP_READLINE"|$SED 's/^shared,//'`
66202  ;;
66203shared)
66204  PHP_READLINE=yes
66205  ;;
66206no)
66207  ext_output=no
66208  ext_shared=no
66209  ;;
66210*)
66211  ext_output=yes
66212  ext_shared=no
66213  ;;
66214esac
66215
66216
66217
66218{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
66219printf "%s\n" "$ext_output" >&6; }
66220
66221
66222
66223else
66224      php_with_readline=no
66225fi
66226
66227if test "$PHP_READLINE" && test "$PHP_READLINE" != "no"; then
66228  for i in $PHP_READLINE /usr/local /usr; do
66229    test -f $i/include/readline/readline.h && READLINE_DIR=$i && break
66230  done
66231
66232  if test -z "$READLINE_DIR"; then
66233    as_fn_error $? "Please reinstall readline - I cannot find readline.h" "$LINENO" 5
66234  fi
66235
66236
66237  if test "$READLINE_DIR/include" != "/usr/include"; then
66238
66239  if test -z "$READLINE_DIR/include" || echo "$READLINE_DIR/include" | grep '^/' >/dev/null ; then
66240    ai_p=$READLINE_DIR/include
66241  else
66242
66243    ep_dir=`echo $READLINE_DIR/include|$SED 's%/*[^/][^/]*/*$%%'`
66244
66245    ep_realdir=`(cd "$ep_dir" && pwd)`
66246    ai_p="$ep_realdir"/`basename "$READLINE_DIR/include"`
66247  fi
66248
66249
66250
66251  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66252
66253  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
66254  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66255    eval "INCLUDEPATH$unique=set"
66256
66257      if test ""; then
66258        INCLUDES="-I$ai_p $INCLUDES"
66259      else
66260        INCLUDES="$INCLUDES -I$ai_p"
66261      fi
66262
66263  fi
66264
66265  fi
66266
66267
66268  PHP_READLINE_LIBS=""
66269  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5
66270printf %s "checking for tgetent in -lncurses... " >&6; }
66271if test ${ac_cv_lib_ncurses_tgetent+y}
66272then :
66273  printf %s "(cached) " >&6
66274else $as_nop
66275  ac_check_lib_save_LIBS=$LIBS
66276LIBS="-lncurses  $LIBS"
66277cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66278/* end confdefs.h.  */
66279
66280/* Override any GCC internal prototype to avoid an error.
66281   Use char because int might match the return type of a GCC
66282   builtin and then its argument prototype would still apply.  */
66283char tgetent ();
66284int
66285main (void)
66286{
66287return tgetent ();
66288  ;
66289  return 0;
66290}
66291_ACEOF
66292if ac_fn_c_try_link "$LINENO"
66293then :
66294  ac_cv_lib_ncurses_tgetent=yes
66295else $as_nop
66296  ac_cv_lib_ncurses_tgetent=no
66297fi
66298rm -f core conftest.err conftest.$ac_objext conftest.beam \
66299    conftest$ac_exeext conftest.$ac_ext
66300LIBS=$ac_check_lib_save_LIBS
66301fi
66302{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5
66303printf "%s\n" "$ac_cv_lib_ncurses_tgetent" >&6; }
66304if test "x$ac_cv_lib_ncurses_tgetent" = xyes
66305then :
66306
66307
66308
66309  case ncurses in
66310  c|c_r) ;;
66311  *)
66312    if test "$ext_shared" = "yes"; then
66313        READLINE_SHARED_LIBADD="-lncurses $READLINE_SHARED_LIBADD"
66314    else
66315
66316
66317  case ncurses in
66318  c|c_r) ;;
66319  *)
66320      LIBS="-lncurses $LIBS"
66321   ;;
66322  esac
66323
66324
66325    fi
66326   ;;
66327  esac
66328
66329
66330    PHP_READLINE_LIBS="$PHP_READLINE_LIBS -lncurses"
66331
66332else $as_nop
66333
66334    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5
66335printf %s "checking for tgetent in -ltermcap... " >&6; }
66336if test ${ac_cv_lib_termcap_tgetent+y}
66337then :
66338  printf %s "(cached) " >&6
66339else $as_nop
66340  ac_check_lib_save_LIBS=$LIBS
66341LIBS="-ltermcap  $LIBS"
66342cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66343/* end confdefs.h.  */
66344
66345/* Override any GCC internal prototype to avoid an error.
66346   Use char because int might match the return type of a GCC
66347   builtin and then its argument prototype would still apply.  */
66348char tgetent ();
66349int
66350main (void)
66351{
66352return tgetent ();
66353  ;
66354  return 0;
66355}
66356_ACEOF
66357if ac_fn_c_try_link "$LINENO"
66358then :
66359  ac_cv_lib_termcap_tgetent=yes
66360else $as_nop
66361  ac_cv_lib_termcap_tgetent=no
66362fi
66363rm -f core conftest.err conftest.$ac_objext conftest.beam \
66364    conftest$ac_exeext conftest.$ac_ext
66365LIBS=$ac_check_lib_save_LIBS
66366fi
66367{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5
66368printf "%s\n" "$ac_cv_lib_termcap_tgetent" >&6; }
66369if test "x$ac_cv_lib_termcap_tgetent" = xyes
66370then :
66371
66372
66373
66374  case termcap in
66375  c|c_r) ;;
66376  *)
66377    if test "$ext_shared" = "yes"; then
66378        READLINE_SHARED_LIBADD="-ltermcap $READLINE_SHARED_LIBADD"
66379    else
66380
66381
66382  case termcap in
66383  c|c_r) ;;
66384  *)
66385      LIBS="-ltermcap $LIBS"
66386   ;;
66387  esac
66388
66389
66390    fi
66391   ;;
66392  esac
66393
66394
66395      PHP_READLINE_LIBS="$PHP_READLINE_LIBS -ltermcap"
66396
66397fi
66398
66399
66400fi
66401
66402
66403
66404  save_old_LDFLAGS=$LDFLAGS
66405  ac_stuff="
66406    -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS
66407  "
66408
66409  save_ext_shared=$ext_shared
66410  ext_shared=yes
66411
66412  for ac_i in $ac_stuff; do
66413    case $ac_i in
66414    -pthread)
66415      if test "$ext_shared" = "yes"; then
66416        LDFLAGS="$LDFLAGS -pthread"
66417      else
66418
66419
66420  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66421
66422  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
66423  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66424    eval "EXTRA_LDFLAGS$unique=set"
66425    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
66426  fi
66427
66428
66429
66430  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66431
66432  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
66433  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66434    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
66435    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
66436  fi
66437
66438      fi
66439    ;;
66440    -l*)
66441      ac_ii=`echo $ac_i|cut -c 3-`
66442
66443
66444  case $ac_ii in
66445  c|c_r) ;;
66446  *)
66447    if test "$ext_shared" = "yes"; then
66448        LDFLAGS="$LDFLAGS -l$ac_ii"
66449    else
66450
66451
66452  case $ac_ii in
66453  c|c_r) ;;
66454  *)
66455      LIBS="$LIBS -l$ac_ii"
66456   ;;
66457  esac
66458
66459
66460    fi
66461   ;;
66462  esac
66463
66464
66465    ;;
66466    -L*)
66467      ac_ii=`echo $ac_i|cut -c 3-`
66468
66469  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
66470
66471  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
66472    ai_p=$ac_ii
66473  else
66474
66475    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
66476
66477    ep_realdir=`(cd "$ep_dir" && pwd)`
66478    ai_p="$ep_realdir"/`basename "$ac_ii"`
66479  fi
66480
66481
66482      if test "$ext_shared" = "yes"; then
66483        LDFLAGS="-L$ai_p $LDFLAGS"
66484        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
66485      else
66486
66487
66488
66489  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66490
66491  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66492  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66493    eval "LIBPATH$unique=set"
66494
66495    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66496    LDFLAGS="$LDFLAGS -L$ai_p"
66497    PHP_RPATHS="$PHP_RPATHS $ai_p"
66498
66499  fi
66500
66501
66502      fi
66503
66504  fi
66505
66506    ;;
66507    esac
66508  done
66509
66510  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5
66511printf %s "checking for readline in -lreadline... " >&6; }
66512if test ${ac_cv_lib_readline_readline+y}
66513then :
66514  printf %s "(cached) " >&6
66515else $as_nop
66516  ac_check_lib_save_LIBS=$LIBS
66517LIBS="-lreadline  $LIBS"
66518cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66519/* end confdefs.h.  */
66520
66521/* Override any GCC internal prototype to avoid an error.
66522   Use char because int might match the return type of a GCC
66523   builtin and then its argument prototype would still apply.  */
66524char readline ();
66525int
66526main (void)
66527{
66528return readline ();
66529  ;
66530  return 0;
66531}
66532_ACEOF
66533if ac_fn_c_try_link "$LINENO"
66534then :
66535  ac_cv_lib_readline_readline=yes
66536else $as_nop
66537  ac_cv_lib_readline_readline=no
66538fi
66539rm -f core conftest.err conftest.$ac_objext conftest.beam \
66540    conftest$ac_exeext conftest.$ac_ext
66541LIBS=$ac_check_lib_save_LIBS
66542fi
66543{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5
66544printf "%s\n" "$ac_cv_lib_readline_readline" >&6; }
66545if test "x$ac_cv_lib_readline_readline" = xyes
66546then :
66547
66548    LDFLAGS=$save_old_LDFLAGS
66549    ext_shared=$save_ext_shared
66550
66551
66552
66553  if test "$ext_shared" = "yes"; then
66554    READLINE_SHARED_LIBADD="-lreadline $READLINE_SHARED_LIBADD"
66555    if test -n "$READLINE_DIR/$PHP_LIBDIR"; then
66556
66557  if test "$READLINE_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$READLINE_DIR/$PHP_LIBDIR" != "/usr/lib"; then
66558
66559  if test -z "$READLINE_DIR/$PHP_LIBDIR" || echo "$READLINE_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
66560    ai_p=$READLINE_DIR/$PHP_LIBDIR
66561  else
66562
66563    ep_dir=`echo $READLINE_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
66564
66565    ep_realdir=`(cd "$ep_dir" && pwd)`
66566    ai_p="$ep_realdir"/`basename "$READLINE_DIR/$PHP_LIBDIR"`
66567  fi
66568
66569
66570      if test "$ext_shared" = "yes"; then
66571        READLINE_SHARED_LIBADD="-L$ai_p $READLINE_SHARED_LIBADD"
66572        test -n "$ld_runpath_switch" && READLINE_SHARED_LIBADD="$ld_runpath_switch$ai_p $READLINE_SHARED_LIBADD"
66573      else
66574
66575
66576
66577  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66578
66579  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66580  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66581    eval "LIBPATH$unique=set"
66582
66583    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66584    LDFLAGS="$LDFLAGS -L$ai_p"
66585    PHP_RPATHS="$PHP_RPATHS $ai_p"
66586
66587  fi
66588
66589
66590      fi
66591
66592  fi
66593
66594    fi
66595  else
66596
66597
66598  if test -n "$READLINE_DIR/$PHP_LIBDIR"; then
66599
66600  if test "$READLINE_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$READLINE_DIR/$PHP_LIBDIR" != "/usr/lib"; then
66601
66602  if test -z "$READLINE_DIR/$PHP_LIBDIR" || echo "$READLINE_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
66603    ai_p=$READLINE_DIR/$PHP_LIBDIR
66604  else
66605
66606    ep_dir=`echo $READLINE_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
66607
66608    ep_realdir=`(cd "$ep_dir" && pwd)`
66609    ai_p="$ep_realdir"/`basename "$READLINE_DIR/$PHP_LIBDIR"`
66610  fi
66611
66612
66613
66614
66615
66616  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66617
66618  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66619  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66620    eval "LIBPATH$unique=set"
66621
66622    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66623    LDFLAGS="$LDFLAGS -L$ai_p"
66624    PHP_RPATHS="$PHP_RPATHS $ai_p"
66625
66626  fi
66627
66628
66629
66630  fi
66631
66632  fi
66633
66634
66635  case readline in
66636  c|c_r) ;;
66637  *)
66638      LIBS="-lreadline $LIBS"
66639   ;;
66640  esac
66641
66642
66643
66644
66645  fi
66646
66647
66648
66649
66650else $as_nop
66651
66652    LDFLAGS=$save_old_LDFLAGS
66653    ext_shared=$save_ext_shared
66654    unset ac_cv_lib_readline_readline
66655
66656    as_fn_error $? "readline library not found" "$LINENO" 5
66657
66658
66659fi
66660
66661
66662
66663  save_old_LDFLAGS=$LDFLAGS
66664  ac_stuff="
66665    -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS
66666  "
66667
66668  save_ext_shared=$ext_shared
66669  ext_shared=yes
66670
66671  for ac_i in $ac_stuff; do
66672    case $ac_i in
66673    -pthread)
66674      if test "$ext_shared" = "yes"; then
66675        LDFLAGS="$LDFLAGS -pthread"
66676      else
66677
66678
66679  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66680
66681  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
66682  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66683    eval "EXTRA_LDFLAGS$unique=set"
66684    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
66685  fi
66686
66687
66688
66689  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66690
66691  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
66692  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66693    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
66694    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
66695  fi
66696
66697      fi
66698    ;;
66699    -l*)
66700      ac_ii=`echo $ac_i|cut -c 3-`
66701
66702
66703  case $ac_ii in
66704  c|c_r) ;;
66705  *)
66706    if test "$ext_shared" = "yes"; then
66707        LDFLAGS="$LDFLAGS -l$ac_ii"
66708    else
66709
66710
66711  case $ac_ii in
66712  c|c_r) ;;
66713  *)
66714      LIBS="$LIBS -l$ac_ii"
66715   ;;
66716  esac
66717
66718
66719    fi
66720   ;;
66721  esac
66722
66723
66724    ;;
66725    -L*)
66726      ac_ii=`echo $ac_i|cut -c 3-`
66727
66728  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
66729
66730  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
66731    ai_p=$ac_ii
66732  else
66733
66734    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
66735
66736    ep_realdir=`(cd "$ep_dir" && pwd)`
66737    ai_p="$ep_realdir"/`basename "$ac_ii"`
66738  fi
66739
66740
66741      if test "$ext_shared" = "yes"; then
66742        LDFLAGS="-L$ai_p $LDFLAGS"
66743        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
66744      else
66745
66746
66747
66748  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66749
66750  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66751  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66752    eval "LIBPATH$unique=set"
66753
66754    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66755    LDFLAGS="$LDFLAGS -L$ai_p"
66756    PHP_RPATHS="$PHP_RPATHS $ai_p"
66757
66758  fi
66759
66760
66761      fi
66762
66763  fi
66764
66765    ;;
66766    esac
66767  done
66768
66769  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_pending_input in -lreadline" >&5
66770printf %s "checking for rl_pending_input in -lreadline... " >&6; }
66771if test ${ac_cv_lib_readline_rl_pending_input+y}
66772then :
66773  printf %s "(cached) " >&6
66774else $as_nop
66775  ac_check_lib_save_LIBS=$LIBS
66776LIBS="-lreadline  $LIBS"
66777cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66778/* end confdefs.h.  */
66779
66780/* Override any GCC internal prototype to avoid an error.
66781   Use char because int might match the return type of a GCC
66782   builtin and then its argument prototype would still apply.  */
66783char rl_pending_input ();
66784int
66785main (void)
66786{
66787return rl_pending_input ();
66788  ;
66789  return 0;
66790}
66791_ACEOF
66792if ac_fn_c_try_link "$LINENO"
66793then :
66794  ac_cv_lib_readline_rl_pending_input=yes
66795else $as_nop
66796  ac_cv_lib_readline_rl_pending_input=no
66797fi
66798rm -f core conftest.err conftest.$ac_objext conftest.beam \
66799    conftest$ac_exeext conftest.$ac_ext
66800LIBS=$ac_check_lib_save_LIBS
66801fi
66802{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_pending_input" >&5
66803printf "%s\n" "$ac_cv_lib_readline_rl_pending_input" >&6; }
66804if test "x$ac_cv_lib_readline_rl_pending_input" = xyes
66805then :
66806
66807    LDFLAGS=$save_old_LDFLAGS
66808    ext_shared=$save_ext_shared
66809
66810
66811else $as_nop
66812
66813    LDFLAGS=$save_old_LDFLAGS
66814    ext_shared=$save_ext_shared
66815    unset ac_cv_lib_readline_rl_pending_input
66816
66817    as_fn_error $? "invalid readline installation detected. Try --with-libedit instead." "$LINENO" 5
66818
66819
66820fi
66821
66822
66823
66824  save_old_LDFLAGS=$LDFLAGS
66825  ac_stuff="
66826    -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS
66827  "
66828
66829  save_ext_shared=$ext_shared
66830  ext_shared=yes
66831
66832  for ac_i in $ac_stuff; do
66833    case $ac_i in
66834    -pthread)
66835      if test "$ext_shared" = "yes"; then
66836        LDFLAGS="$LDFLAGS -pthread"
66837      else
66838
66839
66840  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66841
66842  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
66843  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66844    eval "EXTRA_LDFLAGS$unique=set"
66845    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
66846  fi
66847
66848
66849
66850  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
66851
66852  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
66853  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66854    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
66855    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
66856  fi
66857
66858      fi
66859    ;;
66860    -l*)
66861      ac_ii=`echo $ac_i|cut -c 3-`
66862
66863
66864  case $ac_ii in
66865  c|c_r) ;;
66866  *)
66867    if test "$ext_shared" = "yes"; then
66868        LDFLAGS="$LDFLAGS -l$ac_ii"
66869    else
66870
66871
66872  case $ac_ii in
66873  c|c_r) ;;
66874  *)
66875      LIBS="$LIBS -l$ac_ii"
66876   ;;
66877  esac
66878
66879
66880    fi
66881   ;;
66882  esac
66883
66884
66885    ;;
66886    -L*)
66887      ac_ii=`echo $ac_i|cut -c 3-`
66888
66889  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
66890
66891  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
66892    ai_p=$ac_ii
66893  else
66894
66895    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
66896
66897    ep_realdir=`(cd "$ep_dir" && pwd)`
66898    ai_p="$ep_realdir"/`basename "$ac_ii"`
66899  fi
66900
66901
66902      if test "$ext_shared" = "yes"; then
66903        LDFLAGS="-L$ai_p $LDFLAGS"
66904        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
66905      else
66906
66907
66908
66909  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
66910
66911  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
66912  if test -n "$unique" && test "`eval $cmd`" = "" ; then
66913    eval "LIBPATH$unique=set"
66914
66915    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
66916    LDFLAGS="$LDFLAGS -L$ai_p"
66917    PHP_RPATHS="$PHP_RPATHS $ai_p"
66918
66919  fi
66920
66921
66922      fi
66923
66924  fi
66925
66926    ;;
66927    esac
66928  done
66929
66930  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_callback_read_char in -lreadline" >&5
66931printf %s "checking for rl_callback_read_char in -lreadline... " >&6; }
66932if test ${ac_cv_lib_readline_rl_callback_read_char+y}
66933then :
66934  printf %s "(cached) " >&6
66935else $as_nop
66936  ac_check_lib_save_LIBS=$LIBS
66937LIBS="-lreadline  $LIBS"
66938cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66939/* end confdefs.h.  */
66940
66941/* Override any GCC internal prototype to avoid an error.
66942   Use char because int might match the return type of a GCC
66943   builtin and then its argument prototype would still apply.  */
66944char rl_callback_read_char ();
66945int
66946main (void)
66947{
66948return rl_callback_read_char ();
66949  ;
66950  return 0;
66951}
66952_ACEOF
66953if ac_fn_c_try_link "$LINENO"
66954then :
66955  ac_cv_lib_readline_rl_callback_read_char=yes
66956else $as_nop
66957  ac_cv_lib_readline_rl_callback_read_char=no
66958fi
66959rm -f core conftest.err conftest.$ac_objext conftest.beam \
66960    conftest$ac_exeext conftest.$ac_ext
66961LIBS=$ac_check_lib_save_LIBS
66962fi
66963{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_callback_read_char" >&5
66964printf "%s\n" "$ac_cv_lib_readline_rl_callback_read_char" >&6; }
66965if test "x$ac_cv_lib_readline_rl_callback_read_char" = xyes
66966then :
66967
66968    LDFLAGS=$save_old_LDFLAGS
66969    ext_shared=$save_ext_shared
66970
66971
66972printf "%s\n" "#define HAVE_RL_CALLBACK_READ_CHAR 1" >>confdefs.h
66973
66974
66975
66976else $as_nop
66977
66978    LDFLAGS=$save_old_LDFLAGS
66979    ext_shared=$save_ext_shared
66980    unset ac_cv_lib_readline_rl_callback_read_char
66981
66982
66983fi
66984
66985
66986
66987  save_old_LDFLAGS=$LDFLAGS
66988  ac_stuff="
66989    -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS
66990  "
66991
66992  save_ext_shared=$ext_shared
66993  ext_shared=yes
66994
66995  for ac_i in $ac_stuff; do
66996    case $ac_i in
66997    -pthread)
66998      if test "$ext_shared" = "yes"; then
66999        LDFLAGS="$LDFLAGS -pthread"
67000      else
67001
67002
67003  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67004
67005  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
67006  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67007    eval "EXTRA_LDFLAGS$unique=set"
67008    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
67009  fi
67010
67011
67012
67013  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67014
67015  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
67016  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67017    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
67018    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
67019  fi
67020
67021      fi
67022    ;;
67023    -l*)
67024      ac_ii=`echo $ac_i|cut -c 3-`
67025
67026
67027  case $ac_ii in
67028  c|c_r) ;;
67029  *)
67030    if test "$ext_shared" = "yes"; then
67031        LDFLAGS="$LDFLAGS -l$ac_ii"
67032    else
67033
67034
67035  case $ac_ii in
67036  c|c_r) ;;
67037  *)
67038      LIBS="$LIBS -l$ac_ii"
67039   ;;
67040  esac
67041
67042
67043    fi
67044   ;;
67045  esac
67046
67047
67048    ;;
67049    -L*)
67050      ac_ii=`echo $ac_i|cut -c 3-`
67051
67052  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
67053
67054  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67055    ai_p=$ac_ii
67056  else
67057
67058    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67059
67060    ep_realdir=`(cd "$ep_dir" && pwd)`
67061    ai_p="$ep_realdir"/`basename "$ac_ii"`
67062  fi
67063
67064
67065      if test "$ext_shared" = "yes"; then
67066        LDFLAGS="-L$ai_p $LDFLAGS"
67067        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
67068      else
67069
67070
67071
67072  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67073
67074  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
67075  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67076    eval "LIBPATH$unique=set"
67077
67078    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
67079    LDFLAGS="$LDFLAGS -L$ai_p"
67080    PHP_RPATHS="$PHP_RPATHS $ai_p"
67081
67082  fi
67083
67084
67085      fi
67086
67087  fi
67088
67089    ;;
67090    esac
67091  done
67092
67093  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_on_new_line in -lreadline" >&5
67094printf %s "checking for rl_on_new_line in -lreadline... " >&6; }
67095if test ${ac_cv_lib_readline_rl_on_new_line+y}
67096then :
67097  printf %s "(cached) " >&6
67098else $as_nop
67099  ac_check_lib_save_LIBS=$LIBS
67100LIBS="-lreadline  $LIBS"
67101cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67102/* end confdefs.h.  */
67103
67104/* Override any GCC internal prototype to avoid an error.
67105   Use char because int might match the return type of a GCC
67106   builtin and then its argument prototype would still apply.  */
67107char rl_on_new_line ();
67108int
67109main (void)
67110{
67111return rl_on_new_line ();
67112  ;
67113  return 0;
67114}
67115_ACEOF
67116if ac_fn_c_try_link "$LINENO"
67117then :
67118  ac_cv_lib_readline_rl_on_new_line=yes
67119else $as_nop
67120  ac_cv_lib_readline_rl_on_new_line=no
67121fi
67122rm -f core conftest.err conftest.$ac_objext conftest.beam \
67123    conftest$ac_exeext conftest.$ac_ext
67124LIBS=$ac_check_lib_save_LIBS
67125fi
67126{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_on_new_line" >&5
67127printf "%s\n" "$ac_cv_lib_readline_rl_on_new_line" >&6; }
67128if test "x$ac_cv_lib_readline_rl_on_new_line" = xyes
67129then :
67130
67131    LDFLAGS=$save_old_LDFLAGS
67132    ext_shared=$save_ext_shared
67133
67134
67135printf "%s\n" "#define HAVE_RL_ON_NEW_LINE 1" >>confdefs.h
67136
67137
67138
67139else $as_nop
67140
67141    LDFLAGS=$save_old_LDFLAGS
67142    ext_shared=$save_ext_shared
67143    unset ac_cv_lib_readline_rl_on_new_line
67144
67145
67146fi
67147
67148
67149
67150  save_old_LDFLAGS=$LDFLAGS
67151  ac_stuff="
67152    -L$READLINE_DIR/$PHP_LIBDIR $PHP_READLINE_LIBS
67153  "
67154
67155  save_ext_shared=$ext_shared
67156  ext_shared=yes
67157
67158  for ac_i in $ac_stuff; do
67159    case $ac_i in
67160    -pthread)
67161      if test "$ext_shared" = "yes"; then
67162        LDFLAGS="$LDFLAGS -pthread"
67163      else
67164
67165
67166  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67167
67168  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
67169  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67170    eval "EXTRA_LDFLAGS$unique=set"
67171    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
67172  fi
67173
67174
67175
67176  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67177
67178  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
67179  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67180    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
67181    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
67182  fi
67183
67184      fi
67185    ;;
67186    -l*)
67187      ac_ii=`echo $ac_i|cut -c 3-`
67188
67189
67190  case $ac_ii in
67191  c|c_r) ;;
67192  *)
67193    if test "$ext_shared" = "yes"; then
67194        LDFLAGS="$LDFLAGS -l$ac_ii"
67195    else
67196
67197
67198  case $ac_ii in
67199  c|c_r) ;;
67200  *)
67201      LIBS="$LIBS -l$ac_ii"
67202   ;;
67203  esac
67204
67205
67206    fi
67207   ;;
67208  esac
67209
67210
67211    ;;
67212    -L*)
67213      ac_ii=`echo $ac_i|cut -c 3-`
67214
67215  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
67216
67217  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67218    ai_p=$ac_ii
67219  else
67220
67221    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67222
67223    ep_realdir=`(cd "$ep_dir" && pwd)`
67224    ai_p="$ep_realdir"/`basename "$ac_ii"`
67225  fi
67226
67227
67228      if test "$ext_shared" = "yes"; then
67229        LDFLAGS="-L$ai_p $LDFLAGS"
67230        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
67231      else
67232
67233
67234
67235  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67236
67237  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
67238  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67239    eval "LIBPATH$unique=set"
67240
67241    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
67242    LDFLAGS="$LDFLAGS -L$ai_p"
67243    PHP_RPATHS="$PHP_RPATHS $ai_p"
67244
67245  fi
67246
67247
67248      fi
67249
67250  fi
67251
67252    ;;
67253    esac
67254  done
67255
67256  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -lreadline" >&5
67257printf %s "checking for rl_completion_matches in -lreadline... " >&6; }
67258if test ${ac_cv_lib_readline_rl_completion_matches+y}
67259then :
67260  printf %s "(cached) " >&6
67261else $as_nop
67262  ac_check_lib_save_LIBS=$LIBS
67263LIBS="-lreadline  $LIBS"
67264cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67265/* end confdefs.h.  */
67266
67267/* Override any GCC internal prototype to avoid an error.
67268   Use char because int might match the return type of a GCC
67269   builtin and then its argument prototype would still apply.  */
67270char rl_completion_matches ();
67271int
67272main (void)
67273{
67274return rl_completion_matches ();
67275  ;
67276  return 0;
67277}
67278_ACEOF
67279if ac_fn_c_try_link "$LINENO"
67280then :
67281  ac_cv_lib_readline_rl_completion_matches=yes
67282else $as_nop
67283  ac_cv_lib_readline_rl_completion_matches=no
67284fi
67285rm -f core conftest.err conftest.$ac_objext conftest.beam \
67286    conftest$ac_exeext conftest.$ac_ext
67287LIBS=$ac_check_lib_save_LIBS
67288fi
67289{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_completion_matches" >&5
67290printf "%s\n" "$ac_cv_lib_readline_rl_completion_matches" >&6; }
67291if test "x$ac_cv_lib_readline_rl_completion_matches" = xyes
67292then :
67293
67294    LDFLAGS=$save_old_LDFLAGS
67295    ext_shared=$save_ext_shared
67296
67297
67298printf "%s\n" "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h
67299
67300
67301
67302else $as_nop
67303
67304    LDFLAGS=$save_old_LDFLAGS
67305    ext_shared=$save_ext_shared
67306    unset ac_cv_lib_readline_rl_completion_matches
67307
67308
67309fi
67310
67311
67312
67313printf "%s\n" "#define HAVE_HISTORY_LIST 1" >>confdefs.h
67314
67315
67316printf "%s\n" "#define HAVE_LIBREADLINE 1" >>confdefs.h
67317
67318
67319elif test "$PHP_LIBEDIT" != "no"; then
67320  if test "$PHP_LIBEDIT" != "yes"; then
67321    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: libedit directory ignored, rely on pkg-config" >&5
67322printf "%s\n" "$as_me: WARNING: libedit directory ignored, rely on pkg-config" >&2;}
67323  fi
67324
67325
67326pkg_failed=no
67327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libedit" >&5
67328printf %s "checking for libedit... " >&6; }
67329
67330if test -n "$EDIT_CFLAGS"; then
67331    pkg_cv_EDIT_CFLAGS="$EDIT_CFLAGS"
67332 elif test -n "$PKG_CONFIG"; then
67333    if test -n "$PKG_CONFIG" && \
67334    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
67335  ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
67336  ac_status=$?
67337  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
67338  test $ac_status = 0; }; then
67339  pkg_cv_EDIT_CFLAGS=`$PKG_CONFIG --cflags "libedit" 2>/dev/null`
67340		      test "x$?" != "x0" && pkg_failed=yes
67341else
67342  pkg_failed=yes
67343fi
67344 else
67345    pkg_failed=untried
67346fi
67347if test -n "$EDIT_LIBS"; then
67348    pkg_cv_EDIT_LIBS="$EDIT_LIBS"
67349 elif test -n "$PKG_CONFIG"; then
67350    if test -n "$PKG_CONFIG" && \
67351    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
67352  ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
67353  ac_status=$?
67354  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
67355  test $ac_status = 0; }; then
67356  pkg_cv_EDIT_LIBS=`$PKG_CONFIG --libs "libedit" 2>/dev/null`
67357		      test "x$?" != "x0" && pkg_failed=yes
67358else
67359  pkg_failed=yes
67360fi
67361 else
67362    pkg_failed=untried
67363fi
67364
67365
67366
67367if test $pkg_failed = yes; then
67368        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
67369printf "%s\n" "no" >&6; }
67370
67371if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
67372        _pkg_short_errors_supported=yes
67373else
67374        _pkg_short_errors_supported=no
67375fi
67376        if test $_pkg_short_errors_supported = yes; then
67377	        EDIT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libedit" 2>&1`
67378        else
67379	        EDIT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libedit" 2>&1`
67380        fi
67381	# Put the nasty error message in config.log where it belongs
67382	echo "$EDIT_PKG_ERRORS" >&5
67383
67384	as_fn_error $? "Package requirements (libedit) were not met:
67385
67386$EDIT_PKG_ERRORS
67387
67388Consider adjusting the PKG_CONFIG_PATH environment variable if you
67389installed software in a non-standard prefix.
67390
67391Alternatively, you may set the environment variables EDIT_CFLAGS
67392and EDIT_LIBS to avoid the need to call pkg-config.
67393See the pkg-config man page for more details." "$LINENO" 5
67394elif test $pkg_failed = untried; then
67395        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
67396printf "%s\n" "no" >&6; }
67397	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
67398printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
67399as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
67400is in your PATH or set the PKG_CONFIG environment variable to the full
67401path to pkg-config.
67402
67403Alternatively, you may set the environment variables EDIT_CFLAGS
67404and EDIT_LIBS to avoid the need to call pkg-config.
67405See the pkg-config man page for more details.
67406
67407To get pkg-config, see <http://pkg-config.freedesktop.org/>.
67408See \`config.log' for more details" "$LINENO" 5; }
67409else
67410	EDIT_CFLAGS=$pkg_cv_EDIT_CFLAGS
67411	EDIT_LIBS=$pkg_cv_EDIT_LIBS
67412        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
67413printf "%s\n" "yes" >&6; }
67414
67415fi
67416
67417  for ac_i in $EDIT_LIBS; do
67418    case $ac_i in
67419    -pthread)
67420      if test "$ext_shared" = "yes"; then
67421        READLINE_SHARED_LIBADD="$READLINE_SHARED_LIBADD -pthread"
67422      else
67423
67424
67425  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67426
67427  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
67428  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67429    eval "EXTRA_LDFLAGS$unique=set"
67430    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
67431  fi
67432
67433
67434
67435  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67436
67437  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
67438  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67439    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
67440    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
67441  fi
67442
67443      fi
67444    ;;
67445    -l*)
67446      ac_ii=`echo $ac_i|cut -c 3-`
67447
67448
67449  case $ac_ii in
67450  c|c_r) ;;
67451  *)
67452    if test "$ext_shared" = "yes"; then
67453        READLINE_SHARED_LIBADD="$READLINE_SHARED_LIBADD -l$ac_ii"
67454    else
67455
67456
67457  case $ac_ii in
67458  c|c_r) ;;
67459  *)
67460      LIBS="$LIBS -l$ac_ii"
67461   ;;
67462  esac
67463
67464
67465    fi
67466   ;;
67467  esac
67468
67469
67470    ;;
67471    -L*)
67472      ac_ii=`echo $ac_i|cut -c 3-`
67473
67474  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
67475
67476  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67477    ai_p=$ac_ii
67478  else
67479
67480    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67481
67482    ep_realdir=`(cd "$ep_dir" && pwd)`
67483    ai_p="$ep_realdir"/`basename "$ac_ii"`
67484  fi
67485
67486
67487      if test "$ext_shared" = "yes"; then
67488        READLINE_SHARED_LIBADD="-L$ai_p $READLINE_SHARED_LIBADD"
67489        test -n "$ld_runpath_switch" && READLINE_SHARED_LIBADD="$ld_runpath_switch$ai_p $READLINE_SHARED_LIBADD"
67490      else
67491
67492
67493
67494  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67495
67496  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
67497  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67498    eval "LIBPATH$unique=set"
67499
67500    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
67501    LDFLAGS="$LDFLAGS -L$ai_p"
67502    PHP_RPATHS="$PHP_RPATHS $ai_p"
67503
67504  fi
67505
67506
67507      fi
67508
67509  fi
67510
67511    ;;
67512    esac
67513  done
67514
67515
67516  for ac_i in $EDIT_CFLAGS; do
67517    case $ac_i in
67518    -I*)
67519      ac_ii=`echo $ac_i|cut -c 3-`
67520
67521  if test "$ac_ii" != "/usr/include"; then
67522
67523  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67524    ai_p=$ac_ii
67525  else
67526
67527    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67528
67529    ep_realdir=`(cd "$ep_dir" && pwd)`
67530    ai_p="$ep_realdir"/`basename "$ac_ii"`
67531  fi
67532
67533
67534
67535  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67536
67537  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
67538  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67539    eval "INCLUDEPATH$unique=set"
67540
67541      if test ""; then
67542        INCLUDES="-I$ai_p $INCLUDES"
67543      else
67544        INCLUDES="$INCLUDES -I$ai_p"
67545      fi
67546
67547  fi
67548
67549  fi
67550
67551    ;;
67552    esac
67553  done
67554
67555
67556  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5
67557printf %s "checking for tgetent in -lncurses... " >&6; }
67558if test ${ac_cv_lib_ncurses_tgetent+y}
67559then :
67560  printf %s "(cached) " >&6
67561else $as_nop
67562  ac_check_lib_save_LIBS=$LIBS
67563LIBS="-lncurses  $LIBS"
67564cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67565/* end confdefs.h.  */
67566
67567/* Override any GCC internal prototype to avoid an error.
67568   Use char because int might match the return type of a GCC
67569   builtin and then its argument prototype would still apply.  */
67570char tgetent ();
67571int
67572main (void)
67573{
67574return tgetent ();
67575  ;
67576  return 0;
67577}
67578_ACEOF
67579if ac_fn_c_try_link "$LINENO"
67580then :
67581  ac_cv_lib_ncurses_tgetent=yes
67582else $as_nop
67583  ac_cv_lib_ncurses_tgetent=no
67584fi
67585rm -f core conftest.err conftest.$ac_objext conftest.beam \
67586    conftest$ac_exeext conftest.$ac_ext
67587LIBS=$ac_check_lib_save_LIBS
67588fi
67589{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5
67590printf "%s\n" "$ac_cv_lib_ncurses_tgetent" >&6; }
67591if test "x$ac_cv_lib_ncurses_tgetent" = xyes
67592then :
67593
67594
67595
67596  case ncurses in
67597  c|c_r) ;;
67598  *)
67599    if test "$ext_shared" = "yes"; then
67600        READLINE_SHARED_LIBADD="-lncurses $READLINE_SHARED_LIBADD"
67601    else
67602
67603
67604  case ncurses in
67605  c|c_r) ;;
67606  *)
67607      LIBS="-lncurses $LIBS"
67608   ;;
67609  esac
67610
67611
67612    fi
67613   ;;
67614  esac
67615
67616
67617
67618else $as_nop
67619
67620    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5
67621printf %s "checking for tgetent in -ltermcap... " >&6; }
67622if test ${ac_cv_lib_termcap_tgetent+y}
67623then :
67624  printf %s "(cached) " >&6
67625else $as_nop
67626  ac_check_lib_save_LIBS=$LIBS
67627LIBS="-ltermcap  $LIBS"
67628cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67629/* end confdefs.h.  */
67630
67631/* Override any GCC internal prototype to avoid an error.
67632   Use char because int might match the return type of a GCC
67633   builtin and then its argument prototype would still apply.  */
67634char tgetent ();
67635int
67636main (void)
67637{
67638return tgetent ();
67639  ;
67640  return 0;
67641}
67642_ACEOF
67643if ac_fn_c_try_link "$LINENO"
67644then :
67645  ac_cv_lib_termcap_tgetent=yes
67646else $as_nop
67647  ac_cv_lib_termcap_tgetent=no
67648fi
67649rm -f core conftest.err conftest.$ac_objext conftest.beam \
67650    conftest$ac_exeext conftest.$ac_ext
67651LIBS=$ac_check_lib_save_LIBS
67652fi
67653{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5
67654printf "%s\n" "$ac_cv_lib_termcap_tgetent" >&6; }
67655if test "x$ac_cv_lib_termcap_tgetent" = xyes
67656then :
67657
67658
67659
67660  case termcap in
67661  c|c_r) ;;
67662  *)
67663    if test "$ext_shared" = "yes"; then
67664        READLINE_SHARED_LIBADD="-ltermcap $READLINE_SHARED_LIBADD"
67665    else
67666
67667
67668  case termcap in
67669  c|c_r) ;;
67670  *)
67671      LIBS="-ltermcap $LIBS"
67672   ;;
67673  esac
67674
67675
67676    fi
67677   ;;
67678  esac
67679
67680
67681
67682fi
67683
67684
67685fi
67686
67687
67688
67689  save_old_LDFLAGS=$LDFLAGS
67690  ac_stuff="
67691    $READLINE_SHARED_LIBADD
67692  "
67693
67694  save_ext_shared=$ext_shared
67695  ext_shared=yes
67696
67697  for ac_i in $ac_stuff; do
67698    case $ac_i in
67699    -pthread)
67700      if test "$ext_shared" = "yes"; then
67701        LDFLAGS="$LDFLAGS -pthread"
67702      else
67703
67704
67705  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67706
67707  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
67708  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67709    eval "EXTRA_LDFLAGS$unique=set"
67710    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
67711  fi
67712
67713
67714
67715  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67716
67717  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
67718  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67719    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
67720    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
67721  fi
67722
67723      fi
67724    ;;
67725    -l*)
67726      ac_ii=`echo $ac_i|cut -c 3-`
67727
67728
67729  case $ac_ii in
67730  c|c_r) ;;
67731  *)
67732    if test "$ext_shared" = "yes"; then
67733        LDFLAGS="$LDFLAGS -l$ac_ii"
67734    else
67735
67736
67737  case $ac_ii in
67738  c|c_r) ;;
67739  *)
67740      LIBS="$LIBS -l$ac_ii"
67741   ;;
67742  esac
67743
67744
67745    fi
67746   ;;
67747  esac
67748
67749
67750    ;;
67751    -L*)
67752      ac_ii=`echo $ac_i|cut -c 3-`
67753
67754  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
67755
67756  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67757    ai_p=$ac_ii
67758  else
67759
67760    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67761
67762    ep_realdir=`(cd "$ep_dir" && pwd)`
67763    ai_p="$ep_realdir"/`basename "$ac_ii"`
67764  fi
67765
67766
67767      if test "$ext_shared" = "yes"; then
67768        LDFLAGS="-L$ai_p $LDFLAGS"
67769        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
67770      else
67771
67772
67773
67774  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67775
67776  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
67777  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67778    eval "LIBPATH$unique=set"
67779
67780    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
67781    LDFLAGS="$LDFLAGS -L$ai_p"
67782    PHP_RPATHS="$PHP_RPATHS $ai_p"
67783
67784  fi
67785
67786
67787      fi
67788
67789  fi
67790
67791    ;;
67792    esac
67793  done
67794
67795  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for readline in -ledit" >&5
67796printf %s "checking for readline in -ledit... " >&6; }
67797if test ${ac_cv_lib_edit_readline+y}
67798then :
67799  printf %s "(cached) " >&6
67800else $as_nop
67801  ac_check_lib_save_LIBS=$LIBS
67802LIBS="-ledit  $LIBS"
67803cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67804/* end confdefs.h.  */
67805
67806/* Override any GCC internal prototype to avoid an error.
67807   Use char because int might match the return type of a GCC
67808   builtin and then its argument prototype would still apply.  */
67809char readline ();
67810int
67811main (void)
67812{
67813return readline ();
67814  ;
67815  return 0;
67816}
67817_ACEOF
67818if ac_fn_c_try_link "$LINENO"
67819then :
67820  ac_cv_lib_edit_readline=yes
67821else $as_nop
67822  ac_cv_lib_edit_readline=no
67823fi
67824rm -f core conftest.err conftest.$ac_objext conftest.beam \
67825    conftest$ac_exeext conftest.$ac_ext
67826LIBS=$ac_check_lib_save_LIBS
67827fi
67828{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_readline" >&5
67829printf "%s\n" "$ac_cv_lib_edit_readline" >&6; }
67830if test "x$ac_cv_lib_edit_readline" = xyes
67831then :
67832
67833    LDFLAGS=$save_old_LDFLAGS
67834    ext_shared=$save_ext_shared
67835
67836
67837
67838else $as_nop
67839
67840    LDFLAGS=$save_old_LDFLAGS
67841    ext_shared=$save_ext_shared
67842    unset ac_cv_lib_edit_readline
67843
67844    as_fn_error $? "edit library required by readline not found" "$LINENO" 5
67845
67846
67847fi
67848
67849
67850
67851  save_old_LDFLAGS=$LDFLAGS
67852  ac_stuff="
67853    $READLINE_SHARED_LIBADD
67854  "
67855
67856  save_ext_shared=$ext_shared
67857  ext_shared=yes
67858
67859  for ac_i in $ac_stuff; do
67860    case $ac_i in
67861    -pthread)
67862      if test "$ext_shared" = "yes"; then
67863        LDFLAGS="$LDFLAGS -pthread"
67864      else
67865
67866
67867  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67868
67869  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
67870  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67871    eval "EXTRA_LDFLAGS$unique=set"
67872    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
67873  fi
67874
67875
67876
67877  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
67878
67879  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
67880  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67881    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
67882    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
67883  fi
67884
67885      fi
67886    ;;
67887    -l*)
67888      ac_ii=`echo $ac_i|cut -c 3-`
67889
67890
67891  case $ac_ii in
67892  c|c_r) ;;
67893  *)
67894    if test "$ext_shared" = "yes"; then
67895        LDFLAGS="$LDFLAGS -l$ac_ii"
67896    else
67897
67898
67899  case $ac_ii in
67900  c|c_r) ;;
67901  *)
67902      LIBS="$LIBS -l$ac_ii"
67903   ;;
67904  esac
67905
67906
67907    fi
67908   ;;
67909  esac
67910
67911
67912    ;;
67913    -L*)
67914      ac_ii=`echo $ac_i|cut -c 3-`
67915
67916  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
67917
67918  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
67919    ai_p=$ac_ii
67920  else
67921
67922    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
67923
67924    ep_realdir=`(cd "$ep_dir" && pwd)`
67925    ai_p="$ep_realdir"/`basename "$ac_ii"`
67926  fi
67927
67928
67929      if test "$ext_shared" = "yes"; then
67930        LDFLAGS="-L$ai_p $LDFLAGS"
67931        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
67932      else
67933
67934
67935
67936  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
67937
67938  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
67939  if test -n "$unique" && test "`eval $cmd`" = "" ; then
67940    eval "LIBPATH$unique=set"
67941
67942    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
67943    LDFLAGS="$LDFLAGS -L$ai_p"
67944    PHP_RPATHS="$PHP_RPATHS $ai_p"
67945
67946  fi
67947
67948
67949      fi
67950
67951  fi
67952
67953    ;;
67954    esac
67955  done
67956
67957  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_callback_read_char in -ledit" >&5
67958printf %s "checking for rl_callback_read_char in -ledit... " >&6; }
67959if test ${ac_cv_lib_edit_rl_callback_read_char+y}
67960then :
67961  printf %s "(cached) " >&6
67962else $as_nop
67963  ac_check_lib_save_LIBS=$LIBS
67964LIBS="-ledit  $LIBS"
67965cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67966/* end confdefs.h.  */
67967
67968/* Override any GCC internal prototype to avoid an error.
67969   Use char because int might match the return type of a GCC
67970   builtin and then its argument prototype would still apply.  */
67971char rl_callback_read_char ();
67972int
67973main (void)
67974{
67975return rl_callback_read_char ();
67976  ;
67977  return 0;
67978}
67979_ACEOF
67980if ac_fn_c_try_link "$LINENO"
67981then :
67982  ac_cv_lib_edit_rl_callback_read_char=yes
67983else $as_nop
67984  ac_cv_lib_edit_rl_callback_read_char=no
67985fi
67986rm -f core conftest.err conftest.$ac_objext conftest.beam \
67987    conftest$ac_exeext conftest.$ac_ext
67988LIBS=$ac_check_lib_save_LIBS
67989fi
67990{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_rl_callback_read_char" >&5
67991printf "%s\n" "$ac_cv_lib_edit_rl_callback_read_char" >&6; }
67992if test "x$ac_cv_lib_edit_rl_callback_read_char" = xyes
67993then :
67994
67995    LDFLAGS=$save_old_LDFLAGS
67996    ext_shared=$save_ext_shared
67997
67998
67999printf "%s\n" "#define HAVE_RL_CALLBACK_READ_CHAR 1" >>confdefs.h
68000
68001
68002
68003else $as_nop
68004
68005    LDFLAGS=$save_old_LDFLAGS
68006    ext_shared=$save_ext_shared
68007    unset ac_cv_lib_edit_rl_callback_read_char
68008
68009
68010fi
68011
68012
68013
68014  save_old_LDFLAGS=$LDFLAGS
68015  ac_stuff="
68016    $READLINE_SHARED_LIBADD
68017  "
68018
68019  save_ext_shared=$ext_shared
68020  ext_shared=yes
68021
68022  for ac_i in $ac_stuff; do
68023    case $ac_i in
68024    -pthread)
68025      if test "$ext_shared" = "yes"; then
68026        LDFLAGS="$LDFLAGS -pthread"
68027      else
68028
68029
68030  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68031
68032  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
68033  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68034    eval "EXTRA_LDFLAGS$unique=set"
68035    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
68036  fi
68037
68038
68039
68040  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68041
68042  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
68043  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68044    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
68045    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
68046  fi
68047
68048      fi
68049    ;;
68050    -l*)
68051      ac_ii=`echo $ac_i|cut -c 3-`
68052
68053
68054  case $ac_ii in
68055  c|c_r) ;;
68056  *)
68057    if test "$ext_shared" = "yes"; then
68058        LDFLAGS="$LDFLAGS -l$ac_ii"
68059    else
68060
68061
68062  case $ac_ii in
68063  c|c_r) ;;
68064  *)
68065      LIBS="$LIBS -l$ac_ii"
68066   ;;
68067  esac
68068
68069
68070    fi
68071   ;;
68072  esac
68073
68074
68075    ;;
68076    -L*)
68077      ac_ii=`echo $ac_i|cut -c 3-`
68078
68079  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
68080
68081  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
68082    ai_p=$ac_ii
68083  else
68084
68085    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
68086
68087    ep_realdir=`(cd "$ep_dir" && pwd)`
68088    ai_p="$ep_realdir"/`basename "$ac_ii"`
68089  fi
68090
68091
68092      if test "$ext_shared" = "yes"; then
68093        LDFLAGS="-L$ai_p $LDFLAGS"
68094        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
68095      else
68096
68097
68098
68099  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
68100
68101  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
68102  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68103    eval "LIBPATH$unique=set"
68104
68105    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
68106    LDFLAGS="$LDFLAGS -L$ai_p"
68107    PHP_RPATHS="$PHP_RPATHS $ai_p"
68108
68109  fi
68110
68111
68112      fi
68113
68114  fi
68115
68116    ;;
68117    esac
68118  done
68119
68120  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_on_new_line in -ledit" >&5
68121printf %s "checking for rl_on_new_line in -ledit... " >&6; }
68122if test ${ac_cv_lib_edit_rl_on_new_line+y}
68123then :
68124  printf %s "(cached) " >&6
68125else $as_nop
68126  ac_check_lib_save_LIBS=$LIBS
68127LIBS="-ledit  $LIBS"
68128cat confdefs.h - <<_ACEOF >conftest.$ac_ext
68129/* end confdefs.h.  */
68130
68131/* Override any GCC internal prototype to avoid an error.
68132   Use char because int might match the return type of a GCC
68133   builtin and then its argument prototype would still apply.  */
68134char rl_on_new_line ();
68135int
68136main (void)
68137{
68138return rl_on_new_line ();
68139  ;
68140  return 0;
68141}
68142_ACEOF
68143if ac_fn_c_try_link "$LINENO"
68144then :
68145  ac_cv_lib_edit_rl_on_new_line=yes
68146else $as_nop
68147  ac_cv_lib_edit_rl_on_new_line=no
68148fi
68149rm -f core conftest.err conftest.$ac_objext conftest.beam \
68150    conftest$ac_exeext conftest.$ac_ext
68151LIBS=$ac_check_lib_save_LIBS
68152fi
68153{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_rl_on_new_line" >&5
68154printf "%s\n" "$ac_cv_lib_edit_rl_on_new_line" >&6; }
68155if test "x$ac_cv_lib_edit_rl_on_new_line" = xyes
68156then :
68157
68158    LDFLAGS=$save_old_LDFLAGS
68159    ext_shared=$save_ext_shared
68160
68161
68162printf "%s\n" "#define HAVE_RL_ON_NEW_LINE 1" >>confdefs.h
68163
68164
68165
68166else $as_nop
68167
68168    LDFLAGS=$save_old_LDFLAGS
68169    ext_shared=$save_ext_shared
68170    unset ac_cv_lib_edit_rl_on_new_line
68171
68172
68173fi
68174
68175
68176
68177  save_old_LDFLAGS=$LDFLAGS
68178  ac_stuff="
68179    $READLINE_SHARED_LIBADD
68180  "
68181
68182  save_ext_shared=$ext_shared
68183  ext_shared=yes
68184
68185  for ac_i in $ac_stuff; do
68186    case $ac_i in
68187    -pthread)
68188      if test "$ext_shared" = "yes"; then
68189        LDFLAGS="$LDFLAGS -pthread"
68190      else
68191
68192
68193  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68194
68195  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
68196  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68197    eval "EXTRA_LDFLAGS$unique=set"
68198    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
68199  fi
68200
68201
68202
68203  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68204
68205  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
68206  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68207    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
68208    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
68209  fi
68210
68211      fi
68212    ;;
68213    -l*)
68214      ac_ii=`echo $ac_i|cut -c 3-`
68215
68216
68217  case $ac_ii in
68218  c|c_r) ;;
68219  *)
68220    if test "$ext_shared" = "yes"; then
68221        LDFLAGS="$LDFLAGS -l$ac_ii"
68222    else
68223
68224
68225  case $ac_ii in
68226  c|c_r) ;;
68227  *)
68228      LIBS="$LIBS -l$ac_ii"
68229   ;;
68230  esac
68231
68232
68233    fi
68234   ;;
68235  esac
68236
68237
68238    ;;
68239    -L*)
68240      ac_ii=`echo $ac_i|cut -c 3-`
68241
68242  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
68243
68244  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
68245    ai_p=$ac_ii
68246  else
68247
68248    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
68249
68250    ep_realdir=`(cd "$ep_dir" && pwd)`
68251    ai_p="$ep_realdir"/`basename "$ac_ii"`
68252  fi
68253
68254
68255      if test "$ext_shared" = "yes"; then
68256        LDFLAGS="-L$ai_p $LDFLAGS"
68257        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
68258      else
68259
68260
68261
68262  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
68263
68264  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
68265  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68266    eval "LIBPATH$unique=set"
68267
68268    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
68269    LDFLAGS="$LDFLAGS -L$ai_p"
68270    PHP_RPATHS="$PHP_RPATHS $ai_p"
68271
68272  fi
68273
68274
68275      fi
68276
68277  fi
68278
68279    ;;
68280    esac
68281  done
68282
68283  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for rl_completion_matches in -ledit" >&5
68284printf %s "checking for rl_completion_matches in -ledit... " >&6; }
68285if test ${ac_cv_lib_edit_rl_completion_matches+y}
68286then :
68287  printf %s "(cached) " >&6
68288else $as_nop
68289  ac_check_lib_save_LIBS=$LIBS
68290LIBS="-ledit  $LIBS"
68291cat confdefs.h - <<_ACEOF >conftest.$ac_ext
68292/* end confdefs.h.  */
68293
68294/* Override any GCC internal prototype to avoid an error.
68295   Use char because int might match the return type of a GCC
68296   builtin and then its argument prototype would still apply.  */
68297char rl_completion_matches ();
68298int
68299main (void)
68300{
68301return rl_completion_matches ();
68302  ;
68303  return 0;
68304}
68305_ACEOF
68306if ac_fn_c_try_link "$LINENO"
68307then :
68308  ac_cv_lib_edit_rl_completion_matches=yes
68309else $as_nop
68310  ac_cv_lib_edit_rl_completion_matches=no
68311fi
68312rm -f core conftest.err conftest.$ac_objext conftest.beam \
68313    conftest$ac_exeext conftest.$ac_ext
68314LIBS=$ac_check_lib_save_LIBS
68315fi
68316{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_rl_completion_matches" >&5
68317printf "%s\n" "$ac_cv_lib_edit_rl_completion_matches" >&6; }
68318if test "x$ac_cv_lib_edit_rl_completion_matches" = xyes
68319then :
68320
68321    LDFLAGS=$save_old_LDFLAGS
68322    ext_shared=$save_ext_shared
68323
68324
68325printf "%s\n" "#define HAVE_RL_COMPLETION_MATCHES 1" >>confdefs.h
68326
68327
68328
68329else $as_nop
68330
68331    LDFLAGS=$save_old_LDFLAGS
68332    ext_shared=$save_ext_shared
68333    unset ac_cv_lib_edit_rl_completion_matches
68334
68335
68336fi
68337
68338
68339
68340  save_old_LDFLAGS=$LDFLAGS
68341  ac_stuff="
68342    $READLINE_SHARED_LIBADD
68343  "
68344
68345  save_ext_shared=$ext_shared
68346  ext_shared=yes
68347
68348  for ac_i in $ac_stuff; do
68349    case $ac_i in
68350    -pthread)
68351      if test "$ext_shared" = "yes"; then
68352        LDFLAGS="$LDFLAGS -pthread"
68353      else
68354
68355
68356  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68357
68358  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
68359  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68360    eval "EXTRA_LDFLAGS$unique=set"
68361    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
68362  fi
68363
68364
68365
68366  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
68367
68368  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
68369  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68370    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
68371    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
68372  fi
68373
68374      fi
68375    ;;
68376    -l*)
68377      ac_ii=`echo $ac_i|cut -c 3-`
68378
68379
68380  case $ac_ii in
68381  c|c_r) ;;
68382  *)
68383    if test "$ext_shared" = "yes"; then
68384        LDFLAGS="$LDFLAGS -l$ac_ii"
68385    else
68386
68387
68388  case $ac_ii in
68389  c|c_r) ;;
68390  *)
68391      LIBS="$LIBS -l$ac_ii"
68392   ;;
68393  esac
68394
68395
68396    fi
68397   ;;
68398  esac
68399
68400
68401    ;;
68402    -L*)
68403      ac_ii=`echo $ac_i|cut -c 3-`
68404
68405  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
68406
68407  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
68408    ai_p=$ac_ii
68409  else
68410
68411    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
68412
68413    ep_realdir=`(cd "$ep_dir" && pwd)`
68414    ai_p="$ep_realdir"/`basename "$ac_ii"`
68415  fi
68416
68417
68418      if test "$ext_shared" = "yes"; then
68419        LDFLAGS="-L$ai_p $LDFLAGS"
68420        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
68421      else
68422
68423
68424
68425  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
68426
68427  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
68428  if test -n "$unique" && test "`eval $cmd`" = "" ; then
68429    eval "LIBPATH$unique=set"
68430
68431    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
68432    LDFLAGS="$LDFLAGS -L$ai_p"
68433    PHP_RPATHS="$PHP_RPATHS $ai_p"
68434
68435  fi
68436
68437
68438      fi
68439
68440  fi
68441
68442    ;;
68443    esac
68444  done
68445
68446  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for history_list in -ledit" >&5
68447printf %s "checking for history_list in -ledit... " >&6; }
68448if test ${ac_cv_lib_edit_history_list+y}
68449then :
68450  printf %s "(cached) " >&6
68451else $as_nop
68452  ac_check_lib_save_LIBS=$LIBS
68453LIBS="-ledit  $LIBS"
68454cat confdefs.h - <<_ACEOF >conftest.$ac_ext
68455/* end confdefs.h.  */
68456
68457/* Override any GCC internal prototype to avoid an error.
68458   Use char because int might match the return type of a GCC
68459   builtin and then its argument prototype would still apply.  */
68460char history_list ();
68461int
68462main (void)
68463{
68464return history_list ();
68465  ;
68466  return 0;
68467}
68468_ACEOF
68469if ac_fn_c_try_link "$LINENO"
68470then :
68471  ac_cv_lib_edit_history_list=yes
68472else $as_nop
68473  ac_cv_lib_edit_history_list=no
68474fi
68475rm -f core conftest.err conftest.$ac_objext conftest.beam \
68476    conftest$ac_exeext conftest.$ac_ext
68477LIBS=$ac_check_lib_save_LIBS
68478fi
68479{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_history_list" >&5
68480printf "%s\n" "$ac_cv_lib_edit_history_list" >&6; }
68481if test "x$ac_cv_lib_edit_history_list" = xyes
68482then :
68483
68484    LDFLAGS=$save_old_LDFLAGS
68485    ext_shared=$save_ext_shared
68486
68487
68488printf "%s\n" "#define HAVE_HISTORY_LIST 1" >>confdefs.h
68489
68490
68491
68492else $as_nop
68493
68494    LDFLAGS=$save_old_LDFLAGS
68495    ext_shared=$save_ext_shared
68496    unset ac_cv_lib_edit_history_list
68497
68498
68499fi
68500
68501
68502
68503printf "%s\n" "#define HAVE_LIBEDIT 1" >>confdefs.h
68504
68505fi
68506
68507if test "$PHP_READLINE" != "no" || test "$PHP_LIBEDIT" != "no"; then
68508
68509  ext_builddir=ext/readline
68510  ext_srcdir=$abs_srcdir/ext/readline
68511  ext_dir=ext/readline
68512
68513  ac_extra=`echo ""-Wno-strict-prototypes""|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
68514
68515  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "cli" != "cli"; then
68516    PHP_READLINE_SHARED=no
68517
68518
68519  case $ext_dir in
68520  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68521  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68522  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68523  esac
68524
68525
68526
68527  b_c_pre=$php_c_pre
68528  b_cxx_pre=$php_cxx_pre
68529  b_c_meta=$php_c_meta
68530  b_cxx_meta=$php_cxx_meta
68531  b_c_post=$php_c_post
68532  b_cxx_post=$php_cxx_post
68533  b_lo=$php_lo
68534
68535
68536  old_IFS=$IFS
68537  for ac_src in readline.c readline_cli.c; do
68538
68539      IFS=.
68540      set $ac_src
68541      ac_obj=$1
68542      IFS=$old_IFS
68543
68544      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68545
68546      case $ac_src in
68547        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68548        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68549        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68550        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68551      esac
68552
68553      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68554
68555    cat >>Makefile.objects<<EOF
68556-include $ac_bdir$ac_obj.dep
68557$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68558	$ac_comp
68559EOF
68560  done
68561
68562
68563    EXT_STATIC="$EXT_STATIC readline;$ext_dir"
68564    if test "$ext_shared" != "nocli"; then
68565      EXT_CLI_STATIC="$EXT_CLI_STATIC readline;$ext_dir"
68566    fi
68567  else
68568    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
68569      PHP_READLINE_SHARED=yes
68570
68571  case $ext_dir in
68572  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68573  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68574  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68575  esac
68576
68577
68578
68579  b_c_pre=$shared_c_pre
68580  b_cxx_pre=$shared_cxx_pre
68581  b_c_meta=$shared_c_meta
68582  b_cxx_meta=$shared_cxx_meta
68583  b_c_post=$shared_c_post
68584  b_cxx_post=$shared_cxx_post
68585  b_lo=$shared_lo
68586
68587
68588  old_IFS=$IFS
68589  for ac_src in readline.c readline_cli.c; do
68590
68591      IFS=.
68592      set $ac_src
68593      ac_obj=$1
68594      IFS=$old_IFS
68595
68596      shared_objects_readline="$shared_objects_readline $ac_bdir$ac_obj.lo"
68597
68598      case $ac_src in
68599        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68600        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68601        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68602        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68603      esac
68604
68605      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68606
68607    cat >>Makefile.objects<<EOF
68608-include $ac_bdir$ac_obj.dep
68609$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68610	$ac_comp
68611EOF
68612  done
68613
68614
68615  install_modules="install-modules"
68616  suffix=la
68617
68618  case $host_alias in
68619    *aix*)
68620      additional_flags="-Wl,-G"
68621      ;;
68622  esac
68623
68624  if test "x" = "xyes"; then
68625    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/readline.$suffix"
68626  else
68627    PHP_MODULES="$PHP_MODULES \$(phplibdir)/readline.$suffix"
68628  fi
68629
68630  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_readline"
68631
68632  cat >>Makefile.objects<<EOF
68633\$(phplibdir)/readline.$suffix: $ext_builddir/readline.$suffix
68634	\$(LIBTOOL) --mode=install cp $ext_builddir/readline.$suffix \$(phplibdir)
68635
68636$ext_builddir/readline.$suffix: \$(shared_objects_readline) \$(READLINE_SHARED_DEPENDENCIES)
68637	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_readline) \$(READLINE_SHARED_LIBADD)
68638
68639EOF
68640
68641
68642printf "%s\n" "#define COMPILE_DL_READLINE 1" >>confdefs.h
68643
68644    fi
68645  fi
68646
68647  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "cli" = "cli"; then
68648    PHP_READLINE_SHARED=no
68649    case "$PHP_SAPI" in
68650      cgi|embed|phpdbg)
68651
68652
68653  case $ext_dir in
68654  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68655  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68656  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68657  esac
68658
68659
68660
68661  b_c_pre=$php_c_pre
68662  b_cxx_pre=$php_cxx_pre
68663  b_c_meta=$php_c_meta
68664  b_cxx_meta=$php_cxx_meta
68665  b_c_post=$php_c_post
68666  b_cxx_post=$php_cxx_post
68667  b_lo=$php_lo
68668
68669
68670  old_IFS=$IFS
68671  for ac_src in readline.c readline_cli.c; do
68672
68673      IFS=.
68674      set $ac_src
68675      ac_obj=$1
68676      IFS=$old_IFS
68677
68678      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68679
68680      case $ac_src in
68681        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68682        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68683        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68684        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68685      esac
68686
68687      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68688
68689    cat >>Makefile.objects<<EOF
68690-include $ac_bdir$ac_obj.dep
68691$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68692	$ac_comp
68693EOF
68694  done
68695
68696
68697        EXT_STATIC="$EXT_STATIC readline;$ext_dir"
68698        ;;
68699      *)
68700
68701
68702  case $ext_dir in
68703  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68704  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68705  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68706  esac
68707
68708
68709
68710  b_c_pre=$php_c_pre
68711  b_cxx_pre=$php_cxx_pre
68712  b_c_meta=$php_c_meta
68713  b_cxx_meta=$php_cxx_meta
68714  b_c_post=$php_c_post
68715  b_cxx_post=$php_cxx_post
68716  b_lo=$php_lo
68717
68718
68719  old_IFS=$IFS
68720  for ac_src in readline.c readline_cli.c; do
68721
68722      IFS=.
68723      set $ac_src
68724      ac_obj=$1
68725      IFS=$old_IFS
68726
68727      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68728
68729      case $ac_src in
68730        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68731        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68732        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68733        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68734      esac
68735
68736      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68737
68738    cat >>Makefile.objects<<EOF
68739-include $ac_bdir$ac_obj.dep
68740$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68741	$ac_comp
68742EOF
68743  done
68744
68745
68746        ;;
68747    esac
68748    EXT_CLI_STATIC="$EXT_CLI_STATIC readline;$ext_dir"
68749  fi
68750
68751
68752    BUILD_DIR="$BUILD_DIR $ext_builddir"
68753
68754
68755
68756  if test "$ext_builddir" = "."; then
68757    PHP_PECL_EXTENSION=readline
68758
68759  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
68760
68761  fi
68762
68763
68764  PHP_VAR_SUBST="$PHP_VAR_SUBST READLINE_SHARED_LIBADD"
68765
68766fi
68767
68768
68769
68770
68771
68772  ext_builddir=ext/reflection
68773  ext_srcdir=$abs_srcdir/ext/reflection
68774  ext_dir=ext/reflection
68775
68776  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
68777
68778  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
68779    PHP_REFLECTION_SHARED=no
68780
68781
68782  case $ext_dir in
68783  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68784  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68785  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68786  esac
68787
68788
68789
68790  b_c_pre=$php_c_pre
68791  b_cxx_pre=$php_cxx_pre
68792  b_c_meta=$php_c_meta
68793  b_cxx_meta=$php_cxx_meta
68794  b_c_post=$php_c_post
68795  b_cxx_post=$php_cxx_post
68796  b_lo=$php_lo
68797
68798
68799  old_IFS=$IFS
68800  for ac_src in php_reflection.c; do
68801
68802      IFS=.
68803      set $ac_src
68804      ac_obj=$1
68805      IFS=$old_IFS
68806
68807      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68808
68809      case $ac_src in
68810        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68811        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68812        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68813        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68814      esac
68815
68816      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68817
68818    cat >>Makefile.objects<<EOF
68819-include $ac_bdir$ac_obj.dep
68820$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68821	$ac_comp
68822EOF
68823  done
68824
68825
68826    EXT_STATIC="$EXT_STATIC reflection;$ext_dir"
68827    if test "no" != "nocli"; then
68828      EXT_CLI_STATIC="$EXT_CLI_STATIC reflection;$ext_dir"
68829    fi
68830  else
68831    if test "no" = "shared" || test "no" = "yes"; then
68832      PHP_REFLECTION_SHARED=yes
68833
68834  case $ext_dir in
68835  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68836  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68837  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68838  esac
68839
68840
68841
68842  b_c_pre=$shared_c_pre
68843  b_cxx_pre=$shared_cxx_pre
68844  b_c_meta=$shared_c_meta
68845  b_cxx_meta=$shared_cxx_meta
68846  b_c_post=$shared_c_post
68847  b_cxx_post=$shared_cxx_post
68848  b_lo=$shared_lo
68849
68850
68851  old_IFS=$IFS
68852  for ac_src in php_reflection.c; do
68853
68854      IFS=.
68855      set $ac_src
68856      ac_obj=$1
68857      IFS=$old_IFS
68858
68859      shared_objects_reflection="$shared_objects_reflection $ac_bdir$ac_obj.lo"
68860
68861      case $ac_src in
68862        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68863        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68864        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68865        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68866      esac
68867
68868      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68869
68870    cat >>Makefile.objects<<EOF
68871-include $ac_bdir$ac_obj.dep
68872$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68873	$ac_comp
68874EOF
68875  done
68876
68877
68878  install_modules="install-modules"
68879  suffix=la
68880
68881  case $host_alias in
68882    *aix*)
68883      additional_flags="-Wl,-G"
68884      ;;
68885  esac
68886
68887  if test "x" = "xyes"; then
68888    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/reflection.$suffix"
68889  else
68890    PHP_MODULES="$PHP_MODULES \$(phplibdir)/reflection.$suffix"
68891  fi
68892
68893  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_reflection"
68894
68895  cat >>Makefile.objects<<EOF
68896\$(phplibdir)/reflection.$suffix: $ext_builddir/reflection.$suffix
68897	\$(LIBTOOL) --mode=install cp $ext_builddir/reflection.$suffix \$(phplibdir)
68898
68899$ext_builddir/reflection.$suffix: \$(shared_objects_reflection) \$(REFLECTION_SHARED_DEPENDENCIES)
68900	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_reflection) \$(REFLECTION_SHARED_LIBADD)
68901
68902EOF
68903
68904
68905printf "%s\n" "#define COMPILE_DL_REFLECTION 1" >>confdefs.h
68906
68907    fi
68908  fi
68909
68910  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
68911    PHP_REFLECTION_SHARED=no
68912    case "$PHP_SAPI" in
68913      cgi|embed|phpdbg)
68914
68915
68916  case $ext_dir in
68917  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68918  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68919  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68920  esac
68921
68922
68923
68924  b_c_pre=$php_c_pre
68925  b_cxx_pre=$php_cxx_pre
68926  b_c_meta=$php_c_meta
68927  b_cxx_meta=$php_cxx_meta
68928  b_c_post=$php_c_post
68929  b_cxx_post=$php_cxx_post
68930  b_lo=$php_lo
68931
68932
68933  old_IFS=$IFS
68934  for ac_src in php_reflection.c; do
68935
68936      IFS=.
68937      set $ac_src
68938      ac_obj=$1
68939      IFS=$old_IFS
68940
68941      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68942
68943      case $ac_src in
68944        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68945        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68946        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68947        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68948      esac
68949
68950      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
68951
68952    cat >>Makefile.objects<<EOF
68953-include $ac_bdir$ac_obj.dep
68954$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
68955	$ac_comp
68956EOF
68957  done
68958
68959
68960        EXT_STATIC="$EXT_STATIC reflection;$ext_dir"
68961        ;;
68962      *)
68963
68964
68965  case $ext_dir in
68966  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
68967  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
68968  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
68969  esac
68970
68971
68972
68973  b_c_pre=$php_c_pre
68974  b_cxx_pre=$php_cxx_pre
68975  b_c_meta=$php_c_meta
68976  b_cxx_meta=$php_cxx_meta
68977  b_c_post=$php_c_post
68978  b_cxx_post=$php_cxx_post
68979  b_lo=$php_lo
68980
68981
68982  old_IFS=$IFS
68983  for ac_src in php_reflection.c; do
68984
68985      IFS=.
68986      set $ac_src
68987      ac_obj=$1
68988      IFS=$old_IFS
68989
68990      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
68991
68992      case $ac_src in
68993        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68994        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68995        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
68996        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
68997      esac
68998
68999      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69000
69001    cat >>Makefile.objects<<EOF
69002-include $ac_bdir$ac_obj.dep
69003$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69004	$ac_comp
69005EOF
69006  done
69007
69008
69009        ;;
69010    esac
69011    EXT_CLI_STATIC="$EXT_CLI_STATIC reflection;$ext_dir"
69012  fi
69013
69014
69015    BUILD_DIR="$BUILD_DIR $ext_builddir"
69016
69017
69018
69019  if test "$ext_builddir" = "."; then
69020    PHP_PECL_EXTENSION=reflection
69021
69022  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
69023
69024  fi
69025
69026
69027
69028
69029
69030
69031php_enable_session=yes
69032
69033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable PHP sessions" >&5
69034printf %s "checking whether to enable PHP sessions... " >&6; }
69035# Check whether --enable-session was given.
69036if test ${enable_session+y}
69037then :
69038  enableval=$enable_session; PHP_SESSION=$enableval
69039else $as_nop
69040
69041  PHP_SESSION=yes
69042  test "$PHP_ENABLE_ALL" && PHP_SESSION=$PHP_ENABLE_ALL
69043
69044fi
69045
69046
69047
69048ext_output="yes, shared"
69049ext_shared=yes
69050case $PHP_SESSION in
69051shared,*)
69052  PHP_SESSION=`echo "$PHP_SESSION"|$SED 's/^shared,//'`
69053  ;;
69054shared)
69055  PHP_SESSION=yes
69056  ;;
69057no)
69058  ext_output=no
69059  ext_shared=no
69060  ;;
69061*)
69062  ext_output=yes
69063  ext_shared=no
69064  ;;
69065esac
69066
69067
69068
69069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
69070printf "%s\n" "$ext_output" >&6; }
69071
69072
69073
69074
69075
69076php_with_mm=no
69077
69078{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mm support" >&5
69079printf %s "checking for mm support... " >&6; }
69080
69081# Check whether --with-mm was given.
69082if test ${with_mm+y}
69083then :
69084  withval=$with_mm; PHP_MM=$withval
69085else $as_nop
69086
69087  PHP_MM=no
69088
69089
69090fi
69091
69092
69093ext_output=$PHP_MM
69094{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
69095printf "%s\n" "$ext_output" >&6; }
69096
69097
69098
69099
69100if test "$PHP_SESSION" != "no"; then
69101
69102  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pwrite works" >&5
69103printf %s "checking whether pwrite works... " >&6; }
69104if test ${ac_cv_pwrite+y}
69105then :
69106  printf %s "(cached) " >&6
69107else $as_nop
69108
69109
69110  if test "$cross_compiling" = yes
69111then :
69112
69113    ac_cv_pwrite=no
69114
69115else $as_nop
69116  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69117/* end confdefs.h.  */
69118
69119#include <sys/types.h>
69120#include <sys/stat.h>
69121#include <fcntl.h>
69122#include <unistd.h>
69123#include <errno.h>
69124#include <stdlib.h>
69125
69126    int main() {
69127    int fd = open("conftest_in", O_WRONLY|O_CREAT, 0600);
69128
69129    if (fd < 0) return 1;
69130    if (pwrite(fd, "text", 4, 0) != 4) return 1;
69131    /* Linux glibc breakage until 2.2.5 */
69132    if (pwrite(fd, "text", 4, -1) != -1 || errno != EINVAL) return 1;
69133    return 0;
69134    }
69135
69136
69137_ACEOF
69138if ac_fn_c_try_run "$LINENO"
69139then :
69140
69141    ac_cv_pwrite=yes
69142
69143else $as_nop
69144
69145    ac_cv_pwrite=no
69146
69147fi
69148rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
69149  conftest.$ac_objext conftest.beam conftest.$ac_ext
69150fi
69151
69152
69153    if test "$ac_cv_pwrite" = "no"; then
69154
69155  if test "$cross_compiling" = yes
69156then :
69157
69158    ac_cv_pwrite=no
69159
69160else $as_nop
69161  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69162/* end confdefs.h.  */
69163
69164#include <sys/types.h>
69165#include <sys/stat.h>
69166#include <fcntl.h>
69167#include <unistd.h>
69168#include <errno.h>
69169#include <stdlib.h>
69170ssize_t pwrite(int, void *, size_t, off64_t);
69171    int main() {
69172    int fd = open("conftest_in", O_WRONLY|O_CREAT, 0600);
69173
69174    if (fd < 0) return 1;
69175    if (pwrite(fd, "text", 4, 0) != 4) return 1;
69176    /* Linux glibc breakage until 2.2.5 */
69177    if (pwrite(fd, "text", 4, -1) != -1 || errno != EINVAL) return 1;
69178    return 0;
69179    }
69180
69181
69182_ACEOF
69183if ac_fn_c_try_run "$LINENO"
69184then :
69185
69186    ac_cv_pwrite=yes
69187
69188else $as_nop
69189
69190    ac_cv_pwrite=no
69191
69192fi
69193rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
69194  conftest.$ac_objext conftest.beam conftest.$ac_ext
69195fi
69196
69197
69198      if test "$ac_cv_pwrite" = "yes"; then
69199        ac_cv_pwrite=64
69200      fi
69201    fi
69202
69203fi
69204{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pwrite" >&5
69205printf "%s\n" "$ac_cv_pwrite" >&6; }
69206
69207  if test "$ac_cv_pwrite" != "no"; then
69208
69209printf "%s\n" "#define HAVE_PWRITE 1" >>confdefs.h
69210
69211    if test "$ac_cv_pwrite" = "64"; then
69212
69213printf "%s\n" "#define PHP_PWRITE_64 1" >>confdefs.h
69214
69215    fi
69216  fi
69217
69218
69219  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pread works" >&5
69220printf %s "checking whether pread works... " >&6; }
69221if test ${ac_cv_pread+y}
69222then :
69223  printf %s "(cached) " >&6
69224else $as_nop
69225
69226
69227  echo test > conftest_in
69228  if test "$cross_compiling" = yes
69229then :
69230
69231    ac_cv_pread=no
69232
69233else $as_nop
69234  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69235/* end confdefs.h.  */
69236
69237#include <sys/types.h>
69238#include <sys/stat.h>
69239#include <fcntl.h>
69240#include <unistd.h>
69241#include <errno.h>
69242#include <stdlib.h>
69243
69244    int main() {
69245    char buf[3];
69246    int fd = open("conftest_in", O_RDONLY);
69247    if (fd < 0) return 1;
69248    if (pread(fd, buf, 2, 0) != 2) return 1;
69249    /* Linux glibc breakage until 2.2.5 */
69250    if (pread(fd, buf, 2, -1) != -1 || errno != EINVAL) return 1;
69251    return 0;
69252    }
69253
69254_ACEOF
69255if ac_fn_c_try_run "$LINENO"
69256then :
69257
69258    ac_cv_pread=yes
69259
69260else $as_nop
69261
69262    ac_cv_pread=no
69263
69264fi
69265rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
69266  conftest.$ac_objext conftest.beam conftest.$ac_ext
69267fi
69268
69269  rm -f conftest_in
69270
69271    if test "$ac_cv_pread" = "no"; then
69272
69273  echo test > conftest_in
69274  if test "$cross_compiling" = yes
69275then :
69276
69277    ac_cv_pread=no
69278
69279else $as_nop
69280  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69281/* end confdefs.h.  */
69282
69283#include <sys/types.h>
69284#include <sys/stat.h>
69285#include <fcntl.h>
69286#include <unistd.h>
69287#include <errno.h>
69288#include <stdlib.h>
69289ssize_t pread(int, void *, size_t, off64_t);
69290    int main() {
69291    char buf[3];
69292    int fd = open("conftest_in", O_RDONLY);
69293    if (fd < 0) return 1;
69294    if (pread(fd, buf, 2, 0) != 2) return 1;
69295    /* Linux glibc breakage until 2.2.5 */
69296    if (pread(fd, buf, 2, -1) != -1 || errno != EINVAL) return 1;
69297    return 0;
69298    }
69299
69300_ACEOF
69301if ac_fn_c_try_run "$LINENO"
69302then :
69303
69304    ac_cv_pread=yes
69305
69306else $as_nop
69307
69308    ac_cv_pread=no
69309
69310fi
69311rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
69312  conftest.$ac_objext conftest.beam conftest.$ac_ext
69313fi
69314
69315  rm -f conftest_in
69316
69317      if test "$ac_cv_pread" = "yes"; then
69318        ac_cv_pread=64
69319      fi
69320    fi
69321
69322fi
69323{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pread" >&5
69324printf "%s\n" "$ac_cv_pread" >&6; }
69325
69326  if test "$ac_cv_pread" != "no"; then
69327
69328printf "%s\n" "#define HAVE_PREAD 1" >>confdefs.h
69329
69330    if test "$ac_cv_pread" = "64"; then
69331
69332printf "%s\n" "#define PHP_PREAD_64 1" >>confdefs.h
69333
69334    fi
69335  fi
69336
69337
69338  ext_builddir=ext/session
69339  ext_srcdir=$abs_srcdir/ext/session
69340  ext_dir=ext/session
69341
69342  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
69343
69344  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
69345    PHP_SESSION_SHARED=no
69346
69347
69348  case $ext_dir in
69349  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69350  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69351  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69352  esac
69353
69354
69355
69356  b_c_pre=$php_c_pre
69357  b_cxx_pre=$php_cxx_pre
69358  b_c_meta=$php_c_meta
69359  b_cxx_meta=$php_cxx_meta
69360  b_c_post=$php_c_post
69361  b_cxx_post=$php_cxx_post
69362  b_lo=$php_lo
69363
69364
69365  old_IFS=$IFS
69366  for ac_src in mod_user_class.c session.c mod_files.c mod_mm.c mod_user.c; do
69367
69368      IFS=.
69369      set $ac_src
69370      ac_obj=$1
69371      IFS=$old_IFS
69372
69373      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
69374
69375      case $ac_src in
69376        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69377        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69378        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69379        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69380      esac
69381
69382      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69383
69384    cat >>Makefile.objects<<EOF
69385-include $ac_bdir$ac_obj.dep
69386$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69387	$ac_comp
69388EOF
69389  done
69390
69391
69392    EXT_STATIC="$EXT_STATIC session;$ext_dir"
69393    if test "$ext_shared" != "nocli"; then
69394      EXT_CLI_STATIC="$EXT_CLI_STATIC session;$ext_dir"
69395    fi
69396  else
69397    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
69398      PHP_SESSION_SHARED=yes
69399
69400  case $ext_dir in
69401  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69402  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69403  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69404  esac
69405
69406
69407
69408  b_c_pre=$shared_c_pre
69409  b_cxx_pre=$shared_cxx_pre
69410  b_c_meta=$shared_c_meta
69411  b_cxx_meta=$shared_cxx_meta
69412  b_c_post=$shared_c_post
69413  b_cxx_post=$shared_cxx_post
69414  b_lo=$shared_lo
69415
69416
69417  old_IFS=$IFS
69418  for ac_src in mod_user_class.c session.c mod_files.c mod_mm.c mod_user.c; do
69419
69420      IFS=.
69421      set $ac_src
69422      ac_obj=$1
69423      IFS=$old_IFS
69424
69425      shared_objects_session="$shared_objects_session $ac_bdir$ac_obj.lo"
69426
69427      case $ac_src in
69428        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69429        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69430        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69431        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69432      esac
69433
69434      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69435
69436    cat >>Makefile.objects<<EOF
69437-include $ac_bdir$ac_obj.dep
69438$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69439	$ac_comp
69440EOF
69441  done
69442
69443
69444  install_modules="install-modules"
69445  suffix=la
69446
69447  case $host_alias in
69448    *aix*)
69449      additional_flags="-Wl,-G"
69450      ;;
69451  esac
69452
69453  if test "x" = "xyes"; then
69454    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/session.$suffix"
69455  else
69456    PHP_MODULES="$PHP_MODULES \$(phplibdir)/session.$suffix"
69457  fi
69458
69459  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_session"
69460
69461  cat >>Makefile.objects<<EOF
69462\$(phplibdir)/session.$suffix: $ext_builddir/session.$suffix
69463	\$(LIBTOOL) --mode=install cp $ext_builddir/session.$suffix \$(phplibdir)
69464
69465$ext_builddir/session.$suffix: \$(shared_objects_session) \$(SESSION_SHARED_DEPENDENCIES)
69466	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_session) \$(SESSION_SHARED_LIBADD)
69467
69468EOF
69469
69470
69471printf "%s\n" "#define COMPILE_DL_SESSION 1" >>confdefs.h
69472
69473    fi
69474  fi
69475
69476  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
69477    PHP_SESSION_SHARED=no
69478    case "$PHP_SAPI" in
69479      cgi|embed|phpdbg)
69480
69481
69482  case $ext_dir in
69483  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69484  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69485  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69486  esac
69487
69488
69489
69490  b_c_pre=$php_c_pre
69491  b_cxx_pre=$php_cxx_pre
69492  b_c_meta=$php_c_meta
69493  b_cxx_meta=$php_cxx_meta
69494  b_c_post=$php_c_post
69495  b_cxx_post=$php_cxx_post
69496  b_lo=$php_lo
69497
69498
69499  old_IFS=$IFS
69500  for ac_src in mod_user_class.c session.c mod_files.c mod_mm.c mod_user.c; do
69501
69502      IFS=.
69503      set $ac_src
69504      ac_obj=$1
69505      IFS=$old_IFS
69506
69507      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
69508
69509      case $ac_src in
69510        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69511        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69512        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69513        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69514      esac
69515
69516      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69517
69518    cat >>Makefile.objects<<EOF
69519-include $ac_bdir$ac_obj.dep
69520$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69521	$ac_comp
69522EOF
69523  done
69524
69525
69526        EXT_STATIC="$EXT_STATIC session;$ext_dir"
69527        ;;
69528      *)
69529
69530
69531  case $ext_dir in
69532  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69533  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69534  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69535  esac
69536
69537
69538
69539  b_c_pre=$php_c_pre
69540  b_cxx_pre=$php_cxx_pre
69541  b_c_meta=$php_c_meta
69542  b_cxx_meta=$php_cxx_meta
69543  b_c_post=$php_c_post
69544  b_cxx_post=$php_cxx_post
69545  b_lo=$php_lo
69546
69547
69548  old_IFS=$IFS
69549  for ac_src in mod_user_class.c session.c mod_files.c mod_mm.c mod_user.c; do
69550
69551      IFS=.
69552      set $ac_src
69553      ac_obj=$1
69554      IFS=$old_IFS
69555
69556      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
69557
69558      case $ac_src in
69559        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69560        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69561        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69562        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69563      esac
69564
69565      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69566
69567    cat >>Makefile.objects<<EOF
69568-include $ac_bdir$ac_obj.dep
69569$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69570	$ac_comp
69571EOF
69572  done
69573
69574
69575        ;;
69576    esac
69577    EXT_CLI_STATIC="$EXT_CLI_STATIC session;$ext_dir"
69578  fi
69579
69580
69581    BUILD_DIR="$BUILD_DIR $ext_builddir"
69582
69583
69584
69585  if test "$ext_builddir" = "."; then
69586    PHP_PECL_EXTENSION=session
69587
69588  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
69589
69590  fi
69591
69592
69593  am_i_shared=$PHP_SESSION_SHARED
69594  is_it_shared=$PHP_HASH_SHARED
69595  is_it_enabled=$PHP_HASH
69596  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
69597    as_fn_error $? "
69598You've configured extension session to build statically, but it
69599depends on extension hash, which you've configured to build shared.
69600You either need to build session shared or build hash statically for the
69601build to be successful.
69602" "$LINENO" 5
69603  fi
69604  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
69605    as_fn_error $? "
69606You've configured extension session, which depends on extension hash,
69607but you've either not enabled hash, or have disabled it.
69608" "$LINENO" 5
69609  fi
69610
69611
69612  am_i_shared=$PHP_SESSION_SHARED
69613  is_it_shared=$PHP_SPL_SHARED
69614  is_it_enabled=$PHP_SPL
69615  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
69616    as_fn_error $? "
69617You've configured extension session to build statically, but it
69618depends on extension spl, which you've configured to build shared.
69619You either need to build session shared or build spl statically for the
69620build to be successful.
69621" "$LINENO" 5
69622  fi
69623  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
69624    as_fn_error $? "
69625You've configured extension session, which depends on extension spl,
69626but you've either not enabled spl, or have disabled it.
69627" "$LINENO" 5
69628  fi
69629
69630
69631  PHP_VAR_SUBST="$PHP_VAR_SUBST SESSION_SHARED_LIBADD"
69632
69633
69634
69635    header_path=ext/session
69636    for header_file in php_session.h mod_files.h mod_user.h; do
69637      hp_hf="$header_path/$header_file"
69638
69639
69640  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
69641
69642  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
69643  if test -n "$unique" && test "`eval $cmd`" = "" ; then
69644    eval "INSTALLHEADERS$unique=set"
69645
69646        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
69647
69648  fi
69649
69650    done
69651
69652
69653
69654printf "%s\n" "#define HAVE_PHP_SESSION 1" >>confdefs.h
69655
69656fi
69657
69658if test "$PHP_MM" != "no"; then
69659  for i in $PHP_MM /usr/local /usr; do
69660    test -f "$i/include/mm.h" && MM_DIR=$i && break
69661  done
69662
69663  if test -z "$MM_DIR" ; then
69664    as_fn_error $? "cannot find mm library" "$LINENO" 5
69665  fi
69666
69667  if test "$PHP_THREAD_SAFETY" = "yes"; then
69668        as_fn_error $? "--with-mm cannot be combined with --enable-zts" "$LINENO" 5
69669  fi
69670
69671
69672
69673  if test "$ext_shared" = "yes"; then
69674    SESSION_SHARED_LIBADD="-lmm $SESSION_SHARED_LIBADD"
69675    if test -n "$MM_DIR/$PHP_LIBDIR"; then
69676
69677  if test "$MM_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$MM_DIR/$PHP_LIBDIR" != "/usr/lib"; then
69678
69679  if test -z "$MM_DIR/$PHP_LIBDIR" || echo "$MM_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
69680    ai_p=$MM_DIR/$PHP_LIBDIR
69681  else
69682
69683    ep_dir=`echo $MM_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
69684
69685    ep_realdir=`(cd "$ep_dir" && pwd)`
69686    ai_p="$ep_realdir"/`basename "$MM_DIR/$PHP_LIBDIR"`
69687  fi
69688
69689
69690      if test "$ext_shared" = "yes"; then
69691        SESSION_SHARED_LIBADD="-L$ai_p $SESSION_SHARED_LIBADD"
69692        test -n "$ld_runpath_switch" && SESSION_SHARED_LIBADD="$ld_runpath_switch$ai_p $SESSION_SHARED_LIBADD"
69693      else
69694
69695
69696
69697  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
69698
69699  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
69700  if test -n "$unique" && test "`eval $cmd`" = "" ; then
69701    eval "LIBPATH$unique=set"
69702
69703    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
69704    LDFLAGS="$LDFLAGS -L$ai_p"
69705    PHP_RPATHS="$PHP_RPATHS $ai_p"
69706
69707  fi
69708
69709
69710      fi
69711
69712  fi
69713
69714    fi
69715  else
69716
69717
69718  if test -n "$MM_DIR/$PHP_LIBDIR"; then
69719
69720  if test "$MM_DIR/$PHP_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$MM_DIR/$PHP_LIBDIR" != "/usr/lib"; then
69721
69722  if test -z "$MM_DIR/$PHP_LIBDIR" || echo "$MM_DIR/$PHP_LIBDIR" | grep '^/' >/dev/null ; then
69723    ai_p=$MM_DIR/$PHP_LIBDIR
69724  else
69725
69726    ep_dir=`echo $MM_DIR/$PHP_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
69727
69728    ep_realdir=`(cd "$ep_dir" && pwd)`
69729    ai_p="$ep_realdir"/`basename "$MM_DIR/$PHP_LIBDIR"`
69730  fi
69731
69732
69733
69734
69735
69736  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
69737
69738  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
69739  if test -n "$unique" && test "`eval $cmd`" = "" ; then
69740    eval "LIBPATH$unique=set"
69741
69742    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
69743    LDFLAGS="$LDFLAGS -L$ai_p"
69744    PHP_RPATHS="$PHP_RPATHS $ai_p"
69745
69746  fi
69747
69748
69749
69750  fi
69751
69752  fi
69753
69754
69755  case mm in
69756  c|c_r) ;;
69757  *)
69758      LIBS="-lmm $LIBS"
69759   ;;
69760  esac
69761
69762
69763
69764
69765  fi
69766
69767
69768
69769  if test "$MM_DIR/include" != "/usr/include"; then
69770
69771  if test -z "$MM_DIR/include" || echo "$MM_DIR/include" | grep '^/' >/dev/null ; then
69772    ai_p=$MM_DIR/include
69773  else
69774
69775    ep_dir=`echo $MM_DIR/include|$SED 's%/*[^/][^/]*/*$%%'`
69776
69777    ep_realdir=`(cd "$ep_dir" && pwd)`
69778    ai_p="$ep_realdir"/`basename "$MM_DIR/include"`
69779  fi
69780
69781
69782
69783  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
69784
69785  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
69786  if test -n "$unique" && test "`eval $cmd`" = "" ; then
69787    eval "INCLUDEPATH$unique=set"
69788
69789      if test ""; then
69790        INCLUDES="-I$ai_p $INCLUDES"
69791      else
69792        INCLUDES="$INCLUDES -I$ai_p"
69793      fi
69794
69795  fi
69796
69797  fi
69798
69799
69800
69801    for header_file in ext/session/mod_mm.h; do
69802
69803
69804  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
69805
69806  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
69807  if test -n "$unique" && test "`eval $cmd`" = "" ; then
69808    eval "INSTALLHEADERS$unique=set"
69809
69810        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
69811
69812  fi
69813
69814    done
69815
69816
69817
69818printf "%s\n" "#define HAVE_LIBMM 1" >>confdefs.h
69819
69820fi
69821
69822
69823
69824
69825
69826php_enable_shmop=no
69827
69828{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable shmop support" >&5
69829printf %s "checking whether to enable shmop support... " >&6; }
69830# Check whether --enable-shmop was given.
69831if test ${enable_shmop+y}
69832then :
69833  enableval=$enable_shmop; PHP_SHMOP=$enableval
69834else $as_nop
69835
69836  PHP_SHMOP=no
69837  test "$PHP_ENABLE_ALL" && PHP_SHMOP=$PHP_ENABLE_ALL
69838
69839fi
69840
69841
69842
69843ext_output="yes, shared"
69844ext_shared=yes
69845case $PHP_SHMOP in
69846shared,*)
69847  PHP_SHMOP=`echo "$PHP_SHMOP"|$SED 's/^shared,//'`
69848  ;;
69849shared)
69850  PHP_SHMOP=yes
69851  ;;
69852no)
69853  ext_output=no
69854  ext_shared=no
69855  ;;
69856*)
69857  ext_output=yes
69858  ext_shared=no
69859  ;;
69860esac
69861
69862
69863
69864{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
69865printf "%s\n" "$ext_output" >&6; }
69866
69867
69868
69869
69870if test "$PHP_SHMOP" != "no"; then
69871
69872printf "%s\n" "#define HAVE_SHMOP 1" >>confdefs.h
69873
69874
69875  ext_builddir=ext/shmop
69876  ext_srcdir=$abs_srcdir/ext/shmop
69877  ext_dir=ext/shmop
69878
69879  ac_extra=
69880
69881  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
69882    PHP_SHMOP_SHARED=no
69883
69884
69885  case $ext_dir in
69886  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69887  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69888  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69889  esac
69890
69891
69892
69893  b_c_pre=$php_c_pre
69894  b_cxx_pre=$php_cxx_pre
69895  b_c_meta=$php_c_meta
69896  b_cxx_meta=$php_cxx_meta
69897  b_c_post=$php_c_post
69898  b_cxx_post=$php_cxx_post
69899  b_lo=$php_lo
69900
69901
69902  old_IFS=$IFS
69903  for ac_src in shmop.c; do
69904
69905      IFS=.
69906      set $ac_src
69907      ac_obj=$1
69908      IFS=$old_IFS
69909
69910      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
69911
69912      case $ac_src in
69913        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69914        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69915        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69916        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69917      esac
69918
69919      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69920
69921    cat >>Makefile.objects<<EOF
69922-include $ac_bdir$ac_obj.dep
69923$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69924	$ac_comp
69925EOF
69926  done
69927
69928
69929    EXT_STATIC="$EXT_STATIC shmop;$ext_dir"
69930    if test "$ext_shared" != "nocli"; then
69931      EXT_CLI_STATIC="$EXT_CLI_STATIC shmop;$ext_dir"
69932    fi
69933  else
69934    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
69935      PHP_SHMOP_SHARED=yes
69936
69937  case $ext_dir in
69938  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
69939  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
69940  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
69941  esac
69942
69943
69944
69945  b_c_pre=$shared_c_pre
69946  b_cxx_pre=$shared_cxx_pre
69947  b_c_meta=$shared_c_meta
69948  b_cxx_meta=$shared_cxx_meta
69949  b_c_post=$shared_c_post
69950  b_cxx_post=$shared_cxx_post
69951  b_lo=$shared_lo
69952
69953
69954  old_IFS=$IFS
69955  for ac_src in shmop.c; do
69956
69957      IFS=.
69958      set $ac_src
69959      ac_obj=$1
69960      IFS=$old_IFS
69961
69962      shared_objects_shmop="$shared_objects_shmop $ac_bdir$ac_obj.lo"
69963
69964      case $ac_src in
69965        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69966        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69967        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
69968        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
69969      esac
69970
69971      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
69972
69973    cat >>Makefile.objects<<EOF
69974-include $ac_bdir$ac_obj.dep
69975$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
69976	$ac_comp
69977EOF
69978  done
69979
69980
69981  install_modules="install-modules"
69982  suffix=la
69983
69984  case $host_alias in
69985    *aix*)
69986      additional_flags="-Wl,-G"
69987      ;;
69988  esac
69989
69990  if test "x" = "xyes"; then
69991    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/shmop.$suffix"
69992  else
69993    PHP_MODULES="$PHP_MODULES \$(phplibdir)/shmop.$suffix"
69994  fi
69995
69996  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_shmop"
69997
69998  cat >>Makefile.objects<<EOF
69999\$(phplibdir)/shmop.$suffix: $ext_builddir/shmop.$suffix
70000	\$(LIBTOOL) --mode=install cp $ext_builddir/shmop.$suffix \$(phplibdir)
70001
70002$ext_builddir/shmop.$suffix: \$(shared_objects_shmop) \$(SHMOP_SHARED_DEPENDENCIES)
70003	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_shmop) \$(SHMOP_SHARED_LIBADD)
70004
70005EOF
70006
70007
70008printf "%s\n" "#define COMPILE_DL_SHMOP 1" >>confdefs.h
70009
70010    fi
70011  fi
70012
70013  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
70014    PHP_SHMOP_SHARED=no
70015    case "$PHP_SAPI" in
70016      cgi|embed|phpdbg)
70017
70018
70019  case $ext_dir in
70020  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70021  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70022  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70023  esac
70024
70025
70026
70027  b_c_pre=$php_c_pre
70028  b_cxx_pre=$php_cxx_pre
70029  b_c_meta=$php_c_meta
70030  b_cxx_meta=$php_cxx_meta
70031  b_c_post=$php_c_post
70032  b_cxx_post=$php_cxx_post
70033  b_lo=$php_lo
70034
70035
70036  old_IFS=$IFS
70037  for ac_src in shmop.c; do
70038
70039      IFS=.
70040      set $ac_src
70041      ac_obj=$1
70042      IFS=$old_IFS
70043
70044      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
70045
70046      case $ac_src in
70047        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70048        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70049        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70050        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70051      esac
70052
70053      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70054
70055    cat >>Makefile.objects<<EOF
70056-include $ac_bdir$ac_obj.dep
70057$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70058	$ac_comp
70059EOF
70060  done
70061
70062
70063        EXT_STATIC="$EXT_STATIC shmop;$ext_dir"
70064        ;;
70065      *)
70066
70067
70068  case $ext_dir in
70069  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70070  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70071  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70072  esac
70073
70074
70075
70076  b_c_pre=$php_c_pre
70077  b_cxx_pre=$php_cxx_pre
70078  b_c_meta=$php_c_meta
70079  b_cxx_meta=$php_cxx_meta
70080  b_c_post=$php_c_post
70081  b_cxx_post=$php_cxx_post
70082  b_lo=$php_lo
70083
70084
70085  old_IFS=$IFS
70086  for ac_src in shmop.c; do
70087
70088      IFS=.
70089      set $ac_src
70090      ac_obj=$1
70091      IFS=$old_IFS
70092
70093      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
70094
70095      case $ac_src in
70096        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70097        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70098        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70099        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70100      esac
70101
70102      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70103
70104    cat >>Makefile.objects<<EOF
70105-include $ac_bdir$ac_obj.dep
70106$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70107	$ac_comp
70108EOF
70109  done
70110
70111
70112        ;;
70113    esac
70114    EXT_CLI_STATIC="$EXT_CLI_STATIC shmop;$ext_dir"
70115  fi
70116
70117
70118    BUILD_DIR="$BUILD_DIR $ext_builddir"
70119
70120
70121
70122  if test "$ext_builddir" = "."; then
70123    PHP_PECL_EXTENSION=shmop
70124
70125  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
70126
70127  fi
70128
70129fi
70130
70131
70132
70133
70134
70135php_enable_simplexml=yes
70136
70137{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable SimpleXML support" >&5
70138printf %s "checking whether to enable SimpleXML support... " >&6; }
70139# Check whether --enable-simplexml was given.
70140if test ${enable_simplexml+y}
70141then :
70142  enableval=$enable_simplexml; PHP_SIMPLEXML=$enableval
70143else $as_nop
70144
70145  PHP_SIMPLEXML=yes
70146  test "$PHP_ENABLE_ALL" && PHP_SIMPLEXML=$PHP_ENABLE_ALL
70147
70148fi
70149
70150
70151
70152ext_output="yes, shared"
70153ext_shared=yes
70154case $PHP_SIMPLEXML in
70155shared,*)
70156  PHP_SIMPLEXML=`echo "$PHP_SIMPLEXML"|$SED 's/^shared,//'`
70157  ;;
70158shared)
70159  PHP_SIMPLEXML=yes
70160  ;;
70161no)
70162  ext_output=no
70163  ext_shared=no
70164  ;;
70165*)
70166  ext_output=yes
70167  ext_shared=no
70168  ;;
70169esac
70170
70171
70172
70173{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
70174printf "%s\n" "$ext_output" >&6; }
70175
70176
70177
70178
70179if test "$PHP_SIMPLEXML" != "no"; then
70180
70181  if test "$PHP_LIBXML" = "no"; then
70182    as_fn_error $? "SimpleXML extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
70183  fi
70184
70185
70186
70187pkg_failed=no
70188{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
70189printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
70190
70191if test -n "$LIBXML_CFLAGS"; then
70192    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
70193 elif test -n "$PKG_CONFIG"; then
70194    if test -n "$PKG_CONFIG" && \
70195    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
70196  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
70197  ac_status=$?
70198  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
70199  test $ac_status = 0; }; then
70200  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
70201		      test "x$?" != "x0" && pkg_failed=yes
70202else
70203  pkg_failed=yes
70204fi
70205 else
70206    pkg_failed=untried
70207fi
70208if test -n "$LIBXML_LIBS"; then
70209    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
70210 elif test -n "$PKG_CONFIG"; then
70211    if test -n "$PKG_CONFIG" && \
70212    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
70213  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
70214  ac_status=$?
70215  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
70216  test $ac_status = 0; }; then
70217  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
70218		      test "x$?" != "x0" && pkg_failed=yes
70219else
70220  pkg_failed=yes
70221fi
70222 else
70223    pkg_failed=untried
70224fi
70225
70226
70227
70228if test $pkg_failed = yes; then
70229        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
70230printf "%s\n" "no" >&6; }
70231
70232if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
70233        _pkg_short_errors_supported=yes
70234else
70235        _pkg_short_errors_supported=no
70236fi
70237        if test $_pkg_short_errors_supported = yes; then
70238	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
70239        else
70240	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
70241        fi
70242	# Put the nasty error message in config.log where it belongs
70243	echo "$LIBXML_PKG_ERRORS" >&5
70244
70245	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
70246
70247$LIBXML_PKG_ERRORS
70248
70249Consider adjusting the PKG_CONFIG_PATH environment variable if you
70250installed software in a non-standard prefix.
70251
70252Alternatively, you may set the environment variables LIBXML_CFLAGS
70253and LIBXML_LIBS to avoid the need to call pkg-config.
70254See the pkg-config man page for more details." "$LINENO" 5
70255elif test $pkg_failed = untried; then
70256        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
70257printf "%s\n" "no" >&6; }
70258	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
70259printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
70260as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
70261is in your PATH or set the PKG_CONFIG environment variable to the full
70262path to pkg-config.
70263
70264Alternatively, you may set the environment variables LIBXML_CFLAGS
70265and LIBXML_LIBS to avoid the need to call pkg-config.
70266See the pkg-config man page for more details.
70267
70268To get pkg-config, see <http://pkg-config.freedesktop.org/>.
70269See \`config.log' for more details" "$LINENO" 5; }
70270else
70271	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
70272	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
70273        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
70274printf "%s\n" "yes" >&6; }
70275
70276fi
70277
70278
70279  for ac_i in $LIBXML_CFLAGS; do
70280    case $ac_i in
70281    -I*)
70282      ac_ii=`echo $ac_i|cut -c 3-`
70283
70284  if test "$ac_ii" != "/usr/include"; then
70285
70286  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
70287    ai_p=$ac_ii
70288  else
70289
70290    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
70291
70292    ep_realdir=`(cd "$ep_dir" && pwd)`
70293    ai_p="$ep_realdir"/`basename "$ac_ii"`
70294  fi
70295
70296
70297
70298  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
70299
70300  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
70301  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70302    eval "INCLUDEPATH$unique=set"
70303
70304      if test ""; then
70305        INCLUDES="-I$ai_p $INCLUDES"
70306      else
70307        INCLUDES="$INCLUDES -I$ai_p"
70308      fi
70309
70310  fi
70311
70312  fi
70313
70314    ;;
70315    esac
70316  done
70317
70318
70319  for ac_i in $LIBXML_LIBS; do
70320    case $ac_i in
70321    -pthread)
70322      if test "$ext_shared" = "yes"; then
70323        SIMPLEXML_SHARED_LIBADD="$SIMPLEXML_SHARED_LIBADD -pthread"
70324      else
70325
70326
70327  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
70328
70329  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
70330  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70331    eval "EXTRA_LDFLAGS$unique=set"
70332    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
70333  fi
70334
70335
70336
70337  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
70338
70339  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
70340  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70341    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
70342    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
70343  fi
70344
70345      fi
70346    ;;
70347    -l*)
70348      ac_ii=`echo $ac_i|cut -c 3-`
70349
70350
70351  case $ac_ii in
70352  c|c_r) ;;
70353  *)
70354    if test "$ext_shared" = "yes"; then
70355        SIMPLEXML_SHARED_LIBADD="$SIMPLEXML_SHARED_LIBADD -l$ac_ii"
70356    else
70357
70358
70359  case $ac_ii in
70360  c|c_r) ;;
70361  *)
70362      LIBS="$LIBS -l$ac_ii"
70363   ;;
70364  esac
70365
70366
70367    fi
70368   ;;
70369  esac
70370
70371
70372    ;;
70373    -L*)
70374      ac_ii=`echo $ac_i|cut -c 3-`
70375
70376  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
70377
70378  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
70379    ai_p=$ac_ii
70380  else
70381
70382    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
70383
70384    ep_realdir=`(cd "$ep_dir" && pwd)`
70385    ai_p="$ep_realdir"/`basename "$ac_ii"`
70386  fi
70387
70388
70389      if test "$ext_shared" = "yes"; then
70390        SIMPLEXML_SHARED_LIBADD="-L$ai_p $SIMPLEXML_SHARED_LIBADD"
70391        test -n "$ld_runpath_switch" && SIMPLEXML_SHARED_LIBADD="$ld_runpath_switch$ai_p $SIMPLEXML_SHARED_LIBADD"
70392      else
70393
70394
70395
70396  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
70397
70398  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
70399  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70400    eval "LIBPATH$unique=set"
70401
70402    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
70403    LDFLAGS="$LDFLAGS -L$ai_p"
70404    PHP_RPATHS="$PHP_RPATHS $ai_p"
70405
70406  fi
70407
70408
70409      fi
70410
70411  fi
70412
70413    ;;
70414    esac
70415  done
70416
70417
70418
70419printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
70420
70421
70422
70423
70424printf "%s\n" "#define HAVE_SIMPLEXML 1" >>confdefs.h
70425
70426
70427  ext_builddir=ext/simplexml
70428  ext_srcdir=$abs_srcdir/ext/simplexml
70429  ext_dir=ext/simplexml
70430
70431  ac_extra=
70432
70433  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
70434    PHP_SIMPLEXML_SHARED=no
70435
70436
70437  case $ext_dir in
70438  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70439  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70440  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70441  esac
70442
70443
70444
70445  b_c_pre=$php_c_pre
70446  b_cxx_pre=$php_cxx_pre
70447  b_c_meta=$php_c_meta
70448  b_cxx_meta=$php_cxx_meta
70449  b_c_post=$php_c_post
70450  b_cxx_post=$php_cxx_post
70451  b_lo=$php_lo
70452
70453
70454  old_IFS=$IFS
70455  for ac_src in simplexml.c; do
70456
70457      IFS=.
70458      set $ac_src
70459      ac_obj=$1
70460      IFS=$old_IFS
70461
70462      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
70463
70464      case $ac_src in
70465        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70466        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70467        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70468        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70469      esac
70470
70471      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70472
70473    cat >>Makefile.objects<<EOF
70474-include $ac_bdir$ac_obj.dep
70475$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70476	$ac_comp
70477EOF
70478  done
70479
70480
70481    EXT_STATIC="$EXT_STATIC simplexml;$ext_dir"
70482    if test "$ext_shared" != "nocli"; then
70483      EXT_CLI_STATIC="$EXT_CLI_STATIC simplexml;$ext_dir"
70484    fi
70485  else
70486    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
70487      PHP_SIMPLEXML_SHARED=yes
70488
70489  case $ext_dir in
70490  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70491  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70492  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70493  esac
70494
70495
70496
70497  b_c_pre=$shared_c_pre
70498  b_cxx_pre=$shared_cxx_pre
70499  b_c_meta=$shared_c_meta
70500  b_cxx_meta=$shared_cxx_meta
70501  b_c_post=$shared_c_post
70502  b_cxx_post=$shared_cxx_post
70503  b_lo=$shared_lo
70504
70505
70506  old_IFS=$IFS
70507  for ac_src in simplexml.c; do
70508
70509      IFS=.
70510      set $ac_src
70511      ac_obj=$1
70512      IFS=$old_IFS
70513
70514      shared_objects_simplexml="$shared_objects_simplexml $ac_bdir$ac_obj.lo"
70515
70516      case $ac_src in
70517        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70518        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70519        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70520        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70521      esac
70522
70523      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70524
70525    cat >>Makefile.objects<<EOF
70526-include $ac_bdir$ac_obj.dep
70527$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70528	$ac_comp
70529EOF
70530  done
70531
70532
70533  install_modules="install-modules"
70534  suffix=la
70535
70536  case $host_alias in
70537    *aix*)
70538      additional_flags="-Wl,-G"
70539      ;;
70540  esac
70541
70542  if test "x" = "xyes"; then
70543    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/simplexml.$suffix"
70544  else
70545    PHP_MODULES="$PHP_MODULES \$(phplibdir)/simplexml.$suffix"
70546  fi
70547
70548  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_simplexml"
70549
70550  cat >>Makefile.objects<<EOF
70551\$(phplibdir)/simplexml.$suffix: $ext_builddir/simplexml.$suffix
70552	\$(LIBTOOL) --mode=install cp $ext_builddir/simplexml.$suffix \$(phplibdir)
70553
70554$ext_builddir/simplexml.$suffix: \$(shared_objects_simplexml) \$(SIMPLEXML_SHARED_DEPENDENCIES)
70555	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_simplexml) \$(SIMPLEXML_SHARED_LIBADD)
70556
70557EOF
70558
70559
70560printf "%s\n" "#define COMPILE_DL_SIMPLEXML 1" >>confdefs.h
70561
70562    fi
70563  fi
70564
70565  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
70566    PHP_SIMPLEXML_SHARED=no
70567    case "$PHP_SAPI" in
70568      cgi|embed|phpdbg)
70569
70570
70571  case $ext_dir in
70572  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70573  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70574  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70575  esac
70576
70577
70578
70579  b_c_pre=$php_c_pre
70580  b_cxx_pre=$php_cxx_pre
70581  b_c_meta=$php_c_meta
70582  b_cxx_meta=$php_cxx_meta
70583  b_c_post=$php_c_post
70584  b_cxx_post=$php_cxx_post
70585  b_lo=$php_lo
70586
70587
70588  old_IFS=$IFS
70589  for ac_src in simplexml.c; do
70590
70591      IFS=.
70592      set $ac_src
70593      ac_obj=$1
70594      IFS=$old_IFS
70595
70596      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
70597
70598      case $ac_src in
70599        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70600        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70601        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70602        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70603      esac
70604
70605      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70606
70607    cat >>Makefile.objects<<EOF
70608-include $ac_bdir$ac_obj.dep
70609$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70610	$ac_comp
70611EOF
70612  done
70613
70614
70615        EXT_STATIC="$EXT_STATIC simplexml;$ext_dir"
70616        ;;
70617      *)
70618
70619
70620  case $ext_dir in
70621  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
70622  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
70623  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
70624  esac
70625
70626
70627
70628  b_c_pre=$php_c_pre
70629  b_cxx_pre=$php_cxx_pre
70630  b_c_meta=$php_c_meta
70631  b_cxx_meta=$php_cxx_meta
70632  b_c_post=$php_c_post
70633  b_cxx_post=$php_cxx_post
70634  b_lo=$php_lo
70635
70636
70637  old_IFS=$IFS
70638  for ac_src in simplexml.c; do
70639
70640      IFS=.
70641      set $ac_src
70642      ac_obj=$1
70643      IFS=$old_IFS
70644
70645      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
70646
70647      case $ac_src in
70648        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70649        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70650        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
70651        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
70652      esac
70653
70654      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
70655
70656    cat >>Makefile.objects<<EOF
70657-include $ac_bdir$ac_obj.dep
70658$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
70659	$ac_comp
70660EOF
70661  done
70662
70663
70664        ;;
70665    esac
70666    EXT_CLI_STATIC="$EXT_CLI_STATIC simplexml;$ext_dir"
70667  fi
70668
70669
70670    BUILD_DIR="$BUILD_DIR $ext_builddir"
70671
70672
70673
70674  if test "$ext_builddir" = "."; then
70675    PHP_PECL_EXTENSION=simplexml
70676
70677  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
70678
70679  fi
70680
70681
70682
70683    for header_file in ext/simplexml/php_simplexml.h ext/simplexml/php_simplexml_exports.h; do
70684
70685
70686  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
70687
70688  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
70689  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70690    eval "INSTALLHEADERS$unique=set"
70691
70692        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
70693
70694  fi
70695
70696    done
70697
70698
70699
70700  PHP_VAR_SUBST="$PHP_VAR_SUBST SIMPLEXML_SHARED_LIBADD"
70701
70702
70703
70704
70705  am_i_shared=$PHP_SIMPLEXML_SHARED
70706  is_it_shared=$PHP_LIBXML_SHARED
70707  is_it_enabled=$PHP_LIBXML
70708  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
70709    as_fn_error $? "
70710You've configured extension simplexml to build statically, but it
70711depends on extension libxml, which you've configured to build shared.
70712You either need to build simplexml shared or build libxml statically for the
70713build to be successful.
70714" "$LINENO" 5
70715  fi
70716  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
70717    as_fn_error $? "
70718You've configured extension simplexml, which depends on extension libxml,
70719but you've either not enabled libxml, or have disabled it.
70720" "$LINENO" 5
70721  fi
70722
70723
70724  am_i_shared=$PHP_SIMPLEXML_SHARED
70725  is_it_shared=$PHP_SPL_SHARED
70726  is_it_enabled=$PHP_SPL
70727  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
70728    as_fn_error $? "
70729You've configured extension simplexml to build statically, but it
70730depends on extension spl, which you've configured to build shared.
70731You either need to build simplexml shared or build spl statically for the
70732build to be successful.
70733" "$LINENO" 5
70734  fi
70735  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
70736    as_fn_error $? "
70737You've configured extension simplexml, which depends on extension spl,
70738but you've either not enabled spl, or have disabled it.
70739" "$LINENO" 5
70740  fi
70741
70742fi
70743
70744
70745
70746
70747
70748php_with_snmp=no
70749
70750{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SNMP support" >&5
70751printf %s "checking for SNMP support... " >&6; }
70752
70753# Check whether --with-snmp was given.
70754if test ${with_snmp+y}
70755then :
70756  withval=$with_snmp; PHP_SNMP=$withval
70757else $as_nop
70758
70759  PHP_SNMP=no
70760  test "$PHP_ENABLE_ALL" && PHP_SNMP=$PHP_ENABLE_ALL
70761
70762fi
70763
70764
70765
70766ext_output="yes, shared"
70767ext_shared=yes
70768case $PHP_SNMP in
70769shared,*)
70770  PHP_SNMP=`echo "$PHP_SNMP"|$SED 's/^shared,//'`
70771  ;;
70772shared)
70773  PHP_SNMP=yes
70774  ;;
70775no)
70776  ext_output=no
70777  ext_shared=no
70778  ;;
70779*)
70780  ext_output=yes
70781  ext_shared=no
70782  ;;
70783esac
70784
70785
70786
70787{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
70788printf "%s\n" "$ext_output" >&6; }
70789
70790
70791
70792
70793if test "$PHP_SNMP" != "no"; then
70794
70795  if test "$PHP_SNMP" = "yes"; then
70796    # Extract the first word of "net-snmp-config", so it can be a program name with args.
70797set dummy net-snmp-config; ac_word=$2
70798{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
70799printf %s "checking for $ac_word... " >&6; }
70800if test ${ac_cv_path_SNMP_CONFIG+y}
70801then :
70802  printf %s "(cached) " >&6
70803else $as_nop
70804  case $SNMP_CONFIG in
70805  [\\/]* | ?:[\\/]*)
70806  ac_cv_path_SNMP_CONFIG="$SNMP_CONFIG" # Let the user override the test with a path.
70807  ;;
70808  *)
70809  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
70810as_dummy="/usr/local/bin:$PATH"
70811for as_dir in $as_dummy
70812do
70813  IFS=$as_save_IFS
70814  case $as_dir in #(((
70815    '') as_dir=./ ;;
70816    */) ;;
70817    *) as_dir=$as_dir/ ;;
70818  esac
70819    for ac_exec_ext in '' $ac_executable_extensions; do
70820  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
70821    ac_cv_path_SNMP_CONFIG="$as_dir$ac_word$ac_exec_ext"
70822    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
70823    break 2
70824  fi
70825done
70826  done
70827IFS=$as_save_IFS
70828
70829  ;;
70830esac
70831fi
70832SNMP_CONFIG=$ac_cv_path_SNMP_CONFIG
70833if test -n "$SNMP_CONFIG"; then
70834  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SNMP_CONFIG" >&5
70835printf "%s\n" "$SNMP_CONFIG" >&6; }
70836else
70837  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
70838printf "%s\n" "no" >&6; }
70839fi
70840
70841
70842  else
70843    SNMP_CONFIG="$PHP_SNMP/bin/net-snmp-config"
70844  fi
70845
70846  if test -x "$SNMP_CONFIG"; then
70847    SNMP_LIBS=`$SNMP_CONFIG --netsnmp-libs`
70848    SNMP_LIBS="$SNMP_LIBS `$SNMP_CONFIG --external-libs`"
70849    SNMP_PREFIX=`$SNMP_CONFIG --prefix`
70850    snmp_full_version=`$SNMP_CONFIG --version`
70851    ac_IFS=$IFS
70852    IFS="."
70853    set $snmp_full_version
70854    IFS=$ac_IFS
70855    SNMP_VERSION=`expr $1 \* 1000 + $2`
70856    if test "$SNMP_VERSION" -ge "5003"; then
70857      if test -n "$SNMP_LIBS" && test -n "$SNMP_PREFIX"; then
70858
70859  if test "${SNMP_PREFIX}/include" != "/usr/include"; then
70860
70861  if test -z "${SNMP_PREFIX}/include" || echo "${SNMP_PREFIX}/include" | grep '^/' >/dev/null ; then
70862    ai_p=${SNMP_PREFIX}/include
70863  else
70864
70865    ep_dir=`echo $SNMP_PREFIX/include|$SED 's%/*[^/][^/]*/*$%%'`
70866
70867    ep_realdir=`(cd "$ep_dir" && pwd)`
70868    ai_p="$ep_realdir"/`basename "${SNMP_PREFIX}/include"`
70869  fi
70870
70871
70872
70873  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
70874
70875  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
70876  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70877    eval "INCLUDEPATH$unique=set"
70878
70879      if test ""; then
70880        INCLUDES="-I$ai_p $INCLUDES"
70881      else
70882        INCLUDES="$INCLUDES -I$ai_p"
70883      fi
70884
70885  fi
70886
70887  fi
70888
70889
70890  for ac_i in $SNMP_LIBS; do
70891    case $ac_i in
70892    -pthread)
70893      if test "$ext_shared" = "yes"; then
70894        SNMP_SHARED_LIBADD="$SNMP_SHARED_LIBADD -pthread"
70895      else
70896
70897
70898  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
70899
70900  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
70901  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70902    eval "EXTRA_LDFLAGS$unique=set"
70903    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
70904  fi
70905
70906
70907
70908  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
70909
70910  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
70911  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70912    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
70913    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
70914  fi
70915
70916      fi
70917    ;;
70918    -l*)
70919      ac_ii=`echo $ac_i|cut -c 3-`
70920
70921
70922  case $ac_ii in
70923  c|c_r) ;;
70924  *)
70925    if test "$ext_shared" = "yes"; then
70926        SNMP_SHARED_LIBADD="$SNMP_SHARED_LIBADD -l$ac_ii"
70927    else
70928
70929
70930  case $ac_ii in
70931  c|c_r) ;;
70932  *)
70933      LIBS="$LIBS -l$ac_ii"
70934   ;;
70935  esac
70936
70937
70938    fi
70939   ;;
70940  esac
70941
70942
70943    ;;
70944    -L*)
70945      ac_ii=`echo $ac_i|cut -c 3-`
70946
70947  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
70948
70949  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
70950    ai_p=$ac_ii
70951  else
70952
70953    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
70954
70955    ep_realdir=`(cd "$ep_dir" && pwd)`
70956    ai_p="$ep_realdir"/`basename "$ac_ii"`
70957  fi
70958
70959
70960      if test "$ext_shared" = "yes"; then
70961        SNMP_SHARED_LIBADD="-L$ai_p $SNMP_SHARED_LIBADD"
70962        test -n "$ld_runpath_switch" && SNMP_SHARED_LIBADD="$ld_runpath_switch$ai_p $SNMP_SHARED_LIBADD"
70963      else
70964
70965
70966
70967  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
70968
70969  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
70970  if test -n "$unique" && test "`eval $cmd`" = "" ; then
70971    eval "LIBPATH$unique=set"
70972
70973    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
70974    LDFLAGS="$LDFLAGS -L$ai_p"
70975    PHP_RPATHS="$PHP_RPATHS $ai_p"
70976
70977  fi
70978
70979
70980      fi
70981
70982  fi
70983
70984    ;;
70985    esac
70986  done
70987
70988        SNMP_LIBNAME=netsnmp
70989      else
70990        as_fn_error $? "Could not find the required paths. Please check your net-snmp installation." "$LINENO" 5
70991      fi
70992    else
70993      as_fn_error $? "Net-SNMP version 5.3 or greater required (detected $snmp_full_version)." "$LINENO" 5
70994    fi
70995  else
70996    as_fn_error $? "Could not find net-snmp-config binary. Please check your net-snmp installation." "$LINENO" 5
70997  fi
70998
70999
71000  save_old_LDFLAGS=$LDFLAGS
71001  ac_stuff="
71002    $SNMP_SHARED_LIBADD
71003  "
71004
71005  save_ext_shared=$ext_shared
71006  ext_shared=yes
71007
71008  for ac_i in $ac_stuff; do
71009    case $ac_i in
71010    -pthread)
71011      if test "$ext_shared" = "yes"; then
71012        LDFLAGS="$LDFLAGS -pthread"
71013      else
71014
71015
71016  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71017
71018  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
71019  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71020    eval "EXTRA_LDFLAGS$unique=set"
71021    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
71022  fi
71023
71024
71025
71026  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71027
71028  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
71029  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71030    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
71031    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
71032  fi
71033
71034      fi
71035    ;;
71036    -l*)
71037      ac_ii=`echo $ac_i|cut -c 3-`
71038
71039
71040  case $ac_ii in
71041  c|c_r) ;;
71042  *)
71043    if test "$ext_shared" = "yes"; then
71044        LDFLAGS="$LDFLAGS -l$ac_ii"
71045    else
71046
71047
71048  case $ac_ii in
71049  c|c_r) ;;
71050  *)
71051      LIBS="$LIBS -l$ac_ii"
71052   ;;
71053  esac
71054
71055
71056    fi
71057   ;;
71058  esac
71059
71060
71061    ;;
71062    -L*)
71063      ac_ii=`echo $ac_i|cut -c 3-`
71064
71065  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
71066
71067  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
71068    ai_p=$ac_ii
71069  else
71070
71071    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
71072
71073    ep_realdir=`(cd "$ep_dir" && pwd)`
71074    ai_p="$ep_realdir"/`basename "$ac_ii"`
71075  fi
71076
71077
71078      if test "$ext_shared" = "yes"; then
71079        LDFLAGS="-L$ai_p $LDFLAGS"
71080        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
71081      else
71082
71083
71084
71085  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
71086
71087  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
71088  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71089    eval "LIBPATH$unique=set"
71090
71091    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
71092    LDFLAGS="$LDFLAGS -L$ai_p"
71093    PHP_RPATHS="$PHP_RPATHS $ai_p"
71094
71095  fi
71096
71097
71098      fi
71099
71100  fi
71101
71102    ;;
71103    esac
71104  done
71105
71106  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$SNMP_LIBNAME""_init_snmp" | $as_tr_sh`
71107{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for init_snmp in -l$SNMP_LIBNAME" >&5
71108printf %s "checking for init_snmp in -l$SNMP_LIBNAME... " >&6; }
71109if eval test \${$as_ac_Lib+y}
71110then :
71111  printf %s "(cached) " >&6
71112else $as_nop
71113  ac_check_lib_save_LIBS=$LIBS
71114LIBS="-l$SNMP_LIBNAME  $LIBS"
71115cat confdefs.h - <<_ACEOF >conftest.$ac_ext
71116/* end confdefs.h.  */
71117
71118/* Override any GCC internal prototype to avoid an error.
71119   Use char because int might match the return type of a GCC
71120   builtin and then its argument prototype would still apply.  */
71121char init_snmp ();
71122int
71123main (void)
71124{
71125return init_snmp ();
71126  ;
71127  return 0;
71128}
71129_ACEOF
71130if ac_fn_c_try_link "$LINENO"
71131then :
71132  eval "$as_ac_Lib=yes"
71133else $as_nop
71134  eval "$as_ac_Lib=no"
71135fi
71136rm -f core conftest.err conftest.$ac_objext conftest.beam \
71137    conftest$ac_exeext conftest.$ac_ext
71138LIBS=$ac_check_lib_save_LIBS
71139fi
71140eval ac_res=\$$as_ac_Lib
71141	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
71142printf "%s\n" "$ac_res" >&6; }
71143if eval test \"x\$"$as_ac_Lib"\" = x"yes"
71144then :
71145
71146    LDFLAGS=$save_old_LDFLAGS
71147    ext_shared=$save_ext_shared
71148
71149
71150printf "%s\n" "#define HAVE_SNMP 1" >>confdefs.h
71151
71152
71153
71154else $as_nop
71155
71156    LDFLAGS=$save_old_LDFLAGS
71157    ext_shared=$save_ext_shared
71158    unset ac_cv_lib_$SNMP_LIBNAME_init_snmp
71159
71160    as_fn_error $? "SNMP sanity check failed. Please check config.log for more information." "$LINENO" 5
71161
71162
71163fi
71164
71165
71166
71167  save_old_LDFLAGS=$LDFLAGS
71168  ac_stuff="
71169    $SNMP_SHARED_LIBADD
71170  "
71171
71172  save_ext_shared=$ext_shared
71173  ext_shared=yes
71174
71175  for ac_i in $ac_stuff; do
71176    case $ac_i in
71177    -pthread)
71178      if test "$ext_shared" = "yes"; then
71179        LDFLAGS="$LDFLAGS -pthread"
71180      else
71181
71182
71183  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71184
71185  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
71186  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71187    eval "EXTRA_LDFLAGS$unique=set"
71188    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
71189  fi
71190
71191
71192
71193  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71194
71195  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
71196  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71197    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
71198    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
71199  fi
71200
71201      fi
71202    ;;
71203    -l*)
71204      ac_ii=`echo $ac_i|cut -c 3-`
71205
71206
71207  case $ac_ii in
71208  c|c_r) ;;
71209  *)
71210    if test "$ext_shared" = "yes"; then
71211        LDFLAGS="$LDFLAGS -l$ac_ii"
71212    else
71213
71214
71215  case $ac_ii in
71216  c|c_r) ;;
71217  *)
71218      LIBS="$LIBS -l$ac_ii"
71219   ;;
71220  esac
71221
71222
71223    fi
71224   ;;
71225  esac
71226
71227
71228    ;;
71229    -L*)
71230      ac_ii=`echo $ac_i|cut -c 3-`
71231
71232  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
71233
71234  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
71235    ai_p=$ac_ii
71236  else
71237
71238    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
71239
71240    ep_realdir=`(cd "$ep_dir" && pwd)`
71241    ai_p="$ep_realdir"/`basename "$ac_ii"`
71242  fi
71243
71244
71245      if test "$ext_shared" = "yes"; then
71246        LDFLAGS="-L$ai_p $LDFLAGS"
71247        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
71248      else
71249
71250
71251
71252  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
71253
71254  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
71255  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71256    eval "LIBPATH$unique=set"
71257
71258    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
71259    LDFLAGS="$LDFLAGS -L$ai_p"
71260    PHP_RPATHS="$PHP_RPATHS $ai_p"
71261
71262  fi
71263
71264
71265      fi
71266
71267  fi
71268
71269    ;;
71270    esac
71271  done
71272
71273  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$SNMP_LIBNAME""_shutdown_snmp_logging" | $as_tr_sh`
71274{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shutdown_snmp_logging in -l$SNMP_LIBNAME" >&5
71275printf %s "checking for shutdown_snmp_logging in -l$SNMP_LIBNAME... " >&6; }
71276if eval test \${$as_ac_Lib+y}
71277then :
71278  printf %s "(cached) " >&6
71279else $as_nop
71280  ac_check_lib_save_LIBS=$LIBS
71281LIBS="-l$SNMP_LIBNAME  $LIBS"
71282cat confdefs.h - <<_ACEOF >conftest.$ac_ext
71283/* end confdefs.h.  */
71284
71285/* Override any GCC internal prototype to avoid an error.
71286   Use char because int might match the return type of a GCC
71287   builtin and then its argument prototype would still apply.  */
71288char shutdown_snmp_logging ();
71289int
71290main (void)
71291{
71292return shutdown_snmp_logging ();
71293  ;
71294  return 0;
71295}
71296_ACEOF
71297if ac_fn_c_try_link "$LINENO"
71298then :
71299  eval "$as_ac_Lib=yes"
71300else $as_nop
71301  eval "$as_ac_Lib=no"
71302fi
71303rm -f core conftest.err conftest.$ac_objext conftest.beam \
71304    conftest$ac_exeext conftest.$ac_ext
71305LIBS=$ac_check_lib_save_LIBS
71306fi
71307eval ac_res=\$$as_ac_Lib
71308	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
71309printf "%s\n" "$ac_res" >&6; }
71310if eval test \"x\$"$as_ac_Lib"\" = x"yes"
71311then :
71312
71313    LDFLAGS=$save_old_LDFLAGS
71314    ext_shared=$save_ext_shared
71315
71316
71317printf "%s\n" "#define HAVE_SHUTDOWN_SNMP_LOGGING 1" >>confdefs.h
71318
71319
71320
71321else $as_nop
71322
71323    LDFLAGS=$save_old_LDFLAGS
71324    ext_shared=$save_ext_shared
71325    unset ac_cv_lib_$SNMP_LIBNAME_shutdown_snmp_logging
71326
71327
71328fi
71329
71330
71331
71332  save_old_LDFLAGS=$LDFLAGS
71333  ac_stuff="
71334    $SNMP_SHARED_LIBADD
71335  "
71336
71337  save_ext_shared=$ext_shared
71338  ext_shared=yes
71339
71340  for ac_i in $ac_stuff; do
71341    case $ac_i in
71342    -pthread)
71343      if test "$ext_shared" = "yes"; then
71344        LDFLAGS="$LDFLAGS -pthread"
71345      else
71346
71347
71348  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71349
71350  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
71351  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71352    eval "EXTRA_LDFLAGS$unique=set"
71353    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
71354  fi
71355
71356
71357
71358  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71359
71360  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
71361  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71362    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
71363    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
71364  fi
71365
71366      fi
71367    ;;
71368    -l*)
71369      ac_ii=`echo $ac_i|cut -c 3-`
71370
71371
71372  case $ac_ii in
71373  c|c_r) ;;
71374  *)
71375    if test "$ext_shared" = "yes"; then
71376        LDFLAGS="$LDFLAGS -l$ac_ii"
71377    else
71378
71379
71380  case $ac_ii in
71381  c|c_r) ;;
71382  *)
71383      LIBS="$LIBS -l$ac_ii"
71384   ;;
71385  esac
71386
71387
71388    fi
71389   ;;
71390  esac
71391
71392
71393    ;;
71394    -L*)
71395      ac_ii=`echo $ac_i|cut -c 3-`
71396
71397  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
71398
71399  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
71400    ai_p=$ac_ii
71401  else
71402
71403    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
71404
71405    ep_realdir=`(cd "$ep_dir" && pwd)`
71406    ai_p="$ep_realdir"/`basename "$ac_ii"`
71407  fi
71408
71409
71410      if test "$ext_shared" = "yes"; then
71411        LDFLAGS="-L$ai_p $LDFLAGS"
71412        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
71413      else
71414
71415
71416
71417  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
71418
71419  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
71420  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71421    eval "LIBPATH$unique=set"
71422
71423    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
71424    LDFLAGS="$LDFLAGS -L$ai_p"
71425    PHP_RPATHS="$PHP_RPATHS $ai_p"
71426
71427  fi
71428
71429
71430      fi
71431
71432  fi
71433
71434    ;;
71435    esac
71436  done
71437
71438  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$SNMP_LIBNAME""_usmHMAC192SHA256AuthProtocol" | $as_tr_sh`
71439{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usmHMAC192SHA256AuthProtocol in -l$SNMP_LIBNAME" >&5
71440printf %s "checking for usmHMAC192SHA256AuthProtocol in -l$SNMP_LIBNAME... " >&6; }
71441if eval test \${$as_ac_Lib+y}
71442then :
71443  printf %s "(cached) " >&6
71444else $as_nop
71445  ac_check_lib_save_LIBS=$LIBS
71446LIBS="-l$SNMP_LIBNAME  $LIBS"
71447cat confdefs.h - <<_ACEOF >conftest.$ac_ext
71448/* end confdefs.h.  */
71449
71450/* Override any GCC internal prototype to avoid an error.
71451   Use char because int might match the return type of a GCC
71452   builtin and then its argument prototype would still apply.  */
71453char usmHMAC192SHA256AuthProtocol ();
71454int
71455main (void)
71456{
71457return usmHMAC192SHA256AuthProtocol ();
71458  ;
71459  return 0;
71460}
71461_ACEOF
71462if ac_fn_c_try_link "$LINENO"
71463then :
71464  eval "$as_ac_Lib=yes"
71465else $as_nop
71466  eval "$as_ac_Lib=no"
71467fi
71468rm -f core conftest.err conftest.$ac_objext conftest.beam \
71469    conftest$ac_exeext conftest.$ac_ext
71470LIBS=$ac_check_lib_save_LIBS
71471fi
71472eval ac_res=\$$as_ac_Lib
71473	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
71474printf "%s\n" "$ac_res" >&6; }
71475if eval test \"x\$"$as_ac_Lib"\" = x"yes"
71476then :
71477
71478    LDFLAGS=$save_old_LDFLAGS
71479    ext_shared=$save_ext_shared
71480
71481
71482printf "%s\n" "#define HAVE_SNMP_SHA256 1" >>confdefs.h
71483
71484
71485
71486else $as_nop
71487
71488    LDFLAGS=$save_old_LDFLAGS
71489    ext_shared=$save_ext_shared
71490    unset ac_cv_lib_$SNMP_LIBNAME_usmHMAC192SHA256AuthProtocol
71491
71492
71493fi
71494
71495
71496
71497  save_old_LDFLAGS=$LDFLAGS
71498  ac_stuff="
71499    $SNMP_SHARED_LIBADD
71500  "
71501
71502  save_ext_shared=$ext_shared
71503  ext_shared=yes
71504
71505  for ac_i in $ac_stuff; do
71506    case $ac_i in
71507    -pthread)
71508      if test "$ext_shared" = "yes"; then
71509        LDFLAGS="$LDFLAGS -pthread"
71510      else
71511
71512
71513  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71514
71515  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
71516  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71517    eval "EXTRA_LDFLAGS$unique=set"
71518    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
71519  fi
71520
71521
71522
71523  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
71524
71525  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
71526  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71527    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
71528    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
71529  fi
71530
71531      fi
71532    ;;
71533    -l*)
71534      ac_ii=`echo $ac_i|cut -c 3-`
71535
71536
71537  case $ac_ii in
71538  c|c_r) ;;
71539  *)
71540    if test "$ext_shared" = "yes"; then
71541        LDFLAGS="$LDFLAGS -l$ac_ii"
71542    else
71543
71544
71545  case $ac_ii in
71546  c|c_r) ;;
71547  *)
71548      LIBS="$LIBS -l$ac_ii"
71549   ;;
71550  esac
71551
71552
71553    fi
71554   ;;
71555  esac
71556
71557
71558    ;;
71559    -L*)
71560      ac_ii=`echo $ac_i|cut -c 3-`
71561
71562  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
71563
71564  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
71565    ai_p=$ac_ii
71566  else
71567
71568    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
71569
71570    ep_realdir=`(cd "$ep_dir" && pwd)`
71571    ai_p="$ep_realdir"/`basename "$ac_ii"`
71572  fi
71573
71574
71575      if test "$ext_shared" = "yes"; then
71576        LDFLAGS="-L$ai_p $LDFLAGS"
71577        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
71578      else
71579
71580
71581
71582  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
71583
71584  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
71585  if test -n "$unique" && test "`eval $cmd`" = "" ; then
71586    eval "LIBPATH$unique=set"
71587
71588    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
71589    LDFLAGS="$LDFLAGS -L$ai_p"
71590    PHP_RPATHS="$PHP_RPATHS $ai_p"
71591
71592  fi
71593
71594
71595      fi
71596
71597  fi
71598
71599    ;;
71600    esac
71601  done
71602
71603  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$SNMP_LIBNAME""_usmHMAC384SHA512AuthProtocol" | $as_tr_sh`
71604{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usmHMAC384SHA512AuthProtocol in -l$SNMP_LIBNAME" >&5
71605printf %s "checking for usmHMAC384SHA512AuthProtocol in -l$SNMP_LIBNAME... " >&6; }
71606if eval test \${$as_ac_Lib+y}
71607then :
71608  printf %s "(cached) " >&6
71609else $as_nop
71610  ac_check_lib_save_LIBS=$LIBS
71611LIBS="-l$SNMP_LIBNAME  $LIBS"
71612cat confdefs.h - <<_ACEOF >conftest.$ac_ext
71613/* end confdefs.h.  */
71614
71615/* Override any GCC internal prototype to avoid an error.
71616   Use char because int might match the return type of a GCC
71617   builtin and then its argument prototype would still apply.  */
71618char usmHMAC384SHA512AuthProtocol ();
71619int
71620main (void)
71621{
71622return usmHMAC384SHA512AuthProtocol ();
71623  ;
71624  return 0;
71625}
71626_ACEOF
71627if ac_fn_c_try_link "$LINENO"
71628then :
71629  eval "$as_ac_Lib=yes"
71630else $as_nop
71631  eval "$as_ac_Lib=no"
71632fi
71633rm -f core conftest.err conftest.$ac_objext conftest.beam \
71634    conftest$ac_exeext conftest.$ac_ext
71635LIBS=$ac_check_lib_save_LIBS
71636fi
71637eval ac_res=\$$as_ac_Lib
71638	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
71639printf "%s\n" "$ac_res" >&6; }
71640if eval test \"x\$"$as_ac_Lib"\" = x"yes"
71641then :
71642
71643    LDFLAGS=$save_old_LDFLAGS
71644    ext_shared=$save_ext_shared
71645
71646
71647printf "%s\n" "#define HAVE_SNMP_SHA512 1" >>confdefs.h
71648
71649
71650
71651else $as_nop
71652
71653    LDFLAGS=$save_old_LDFLAGS
71654    ext_shared=$save_ext_shared
71655    unset ac_cv_lib_$SNMP_LIBNAME_usmHMAC384SHA512AuthProtocol
71656
71657
71658fi
71659
71660
71661
71662  ext_builddir=ext/snmp
71663  ext_srcdir=$abs_srcdir/ext/snmp
71664  ext_dir=ext/snmp
71665
71666  ac_extra=
71667
71668  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
71669    PHP_SNMP_SHARED=no
71670
71671
71672  case $ext_dir in
71673  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
71674  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
71675  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
71676  esac
71677
71678
71679
71680  b_c_pre=$php_c_pre
71681  b_cxx_pre=$php_cxx_pre
71682  b_c_meta=$php_c_meta
71683  b_cxx_meta=$php_cxx_meta
71684  b_c_post=$php_c_post
71685  b_cxx_post=$php_cxx_post
71686  b_lo=$php_lo
71687
71688
71689  old_IFS=$IFS
71690  for ac_src in snmp.c; do
71691
71692      IFS=.
71693      set $ac_src
71694      ac_obj=$1
71695      IFS=$old_IFS
71696
71697      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
71698
71699      case $ac_src in
71700        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71701        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71702        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71703        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
71704      esac
71705
71706      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
71707
71708    cat >>Makefile.objects<<EOF
71709-include $ac_bdir$ac_obj.dep
71710$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
71711	$ac_comp
71712EOF
71713  done
71714
71715
71716    EXT_STATIC="$EXT_STATIC snmp;$ext_dir"
71717    if test "$ext_shared" != "nocli"; then
71718      EXT_CLI_STATIC="$EXT_CLI_STATIC snmp;$ext_dir"
71719    fi
71720  else
71721    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
71722      PHP_SNMP_SHARED=yes
71723
71724  case $ext_dir in
71725  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
71726  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
71727  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
71728  esac
71729
71730
71731
71732  b_c_pre=$shared_c_pre
71733  b_cxx_pre=$shared_cxx_pre
71734  b_c_meta=$shared_c_meta
71735  b_cxx_meta=$shared_cxx_meta
71736  b_c_post=$shared_c_post
71737  b_cxx_post=$shared_cxx_post
71738  b_lo=$shared_lo
71739
71740
71741  old_IFS=$IFS
71742  for ac_src in snmp.c; do
71743
71744      IFS=.
71745      set $ac_src
71746      ac_obj=$1
71747      IFS=$old_IFS
71748
71749      shared_objects_snmp="$shared_objects_snmp $ac_bdir$ac_obj.lo"
71750
71751      case $ac_src in
71752        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71753        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71754        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71755        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
71756      esac
71757
71758      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
71759
71760    cat >>Makefile.objects<<EOF
71761-include $ac_bdir$ac_obj.dep
71762$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
71763	$ac_comp
71764EOF
71765  done
71766
71767
71768  install_modules="install-modules"
71769  suffix=la
71770
71771  case $host_alias in
71772    *aix*)
71773      additional_flags="-Wl,-G"
71774      ;;
71775  esac
71776
71777  if test "x" = "xyes"; then
71778    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/snmp.$suffix"
71779  else
71780    PHP_MODULES="$PHP_MODULES \$(phplibdir)/snmp.$suffix"
71781  fi
71782
71783  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_snmp"
71784
71785  cat >>Makefile.objects<<EOF
71786\$(phplibdir)/snmp.$suffix: $ext_builddir/snmp.$suffix
71787	\$(LIBTOOL) --mode=install cp $ext_builddir/snmp.$suffix \$(phplibdir)
71788
71789$ext_builddir/snmp.$suffix: \$(shared_objects_snmp) \$(SNMP_SHARED_DEPENDENCIES)
71790	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_snmp) \$(SNMP_SHARED_LIBADD)
71791
71792EOF
71793
71794
71795printf "%s\n" "#define COMPILE_DL_SNMP 1" >>confdefs.h
71796
71797    fi
71798  fi
71799
71800  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
71801    PHP_SNMP_SHARED=no
71802    case "$PHP_SAPI" in
71803      cgi|embed|phpdbg)
71804
71805
71806  case $ext_dir in
71807  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
71808  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
71809  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
71810  esac
71811
71812
71813
71814  b_c_pre=$php_c_pre
71815  b_cxx_pre=$php_cxx_pre
71816  b_c_meta=$php_c_meta
71817  b_cxx_meta=$php_cxx_meta
71818  b_c_post=$php_c_post
71819  b_cxx_post=$php_cxx_post
71820  b_lo=$php_lo
71821
71822
71823  old_IFS=$IFS
71824  for ac_src in snmp.c; do
71825
71826      IFS=.
71827      set $ac_src
71828      ac_obj=$1
71829      IFS=$old_IFS
71830
71831      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
71832
71833      case $ac_src in
71834        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71835        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71836        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71837        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
71838      esac
71839
71840      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
71841
71842    cat >>Makefile.objects<<EOF
71843-include $ac_bdir$ac_obj.dep
71844$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
71845	$ac_comp
71846EOF
71847  done
71848
71849
71850        EXT_STATIC="$EXT_STATIC snmp;$ext_dir"
71851        ;;
71852      *)
71853
71854
71855  case $ext_dir in
71856  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
71857  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
71858  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
71859  esac
71860
71861
71862
71863  b_c_pre=$php_c_pre
71864  b_cxx_pre=$php_cxx_pre
71865  b_c_meta=$php_c_meta
71866  b_cxx_meta=$php_cxx_meta
71867  b_c_post=$php_c_post
71868  b_cxx_post=$php_cxx_post
71869  b_lo=$php_lo
71870
71871
71872  old_IFS=$IFS
71873  for ac_src in snmp.c; do
71874
71875      IFS=.
71876      set $ac_src
71877      ac_obj=$1
71878      IFS=$old_IFS
71879
71880      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
71881
71882      case $ac_src in
71883        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71884        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71885        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
71886        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
71887      esac
71888
71889      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
71890
71891    cat >>Makefile.objects<<EOF
71892-include $ac_bdir$ac_obj.dep
71893$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
71894	$ac_comp
71895EOF
71896  done
71897
71898
71899        ;;
71900    esac
71901    EXT_CLI_STATIC="$EXT_CLI_STATIC snmp;$ext_dir"
71902  fi
71903
71904
71905    BUILD_DIR="$BUILD_DIR $ext_builddir"
71906
71907
71908
71909  if test "$ext_builddir" = "."; then
71910    PHP_PECL_EXTENSION=snmp
71911
71912  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
71913
71914  fi
71915
71916
71917  PHP_VAR_SUBST="$PHP_VAR_SUBST SNMP_SHARED_LIBADD"
71918
71919fi
71920
71921
71922
71923
71924
71925php_enable_soap=no
71926
71927{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable SOAP support" >&5
71928printf %s "checking whether to enable SOAP support... " >&6; }
71929# Check whether --enable-soap was given.
71930if test ${enable_soap+y}
71931then :
71932  enableval=$enable_soap; PHP_SOAP=$enableval
71933else $as_nop
71934
71935  PHP_SOAP=no
71936  test "$PHP_ENABLE_ALL" && PHP_SOAP=$PHP_ENABLE_ALL
71937
71938fi
71939
71940
71941
71942ext_output="yes, shared"
71943ext_shared=yes
71944case $PHP_SOAP in
71945shared,*)
71946  PHP_SOAP=`echo "$PHP_SOAP"|$SED 's/^shared,//'`
71947  ;;
71948shared)
71949  PHP_SOAP=yes
71950  ;;
71951no)
71952  ext_output=no
71953  ext_shared=no
71954  ;;
71955*)
71956  ext_output=yes
71957  ext_shared=no
71958  ;;
71959esac
71960
71961
71962
71963{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
71964printf "%s\n" "$ext_output" >&6; }
71965
71966
71967
71968
71969if test "$PHP_SOAP" != "no"; then
71970
71971  if test "$PHP_LIBXML" = "no"; then
71972    as_fn_error $? "SOAP extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
71973  fi
71974
71975
71976
71977pkg_failed=no
71978{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
71979printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
71980
71981if test -n "$LIBXML_CFLAGS"; then
71982    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
71983 elif test -n "$PKG_CONFIG"; then
71984    if test -n "$PKG_CONFIG" && \
71985    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
71986  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
71987  ac_status=$?
71988  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
71989  test $ac_status = 0; }; then
71990  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
71991		      test "x$?" != "x0" && pkg_failed=yes
71992else
71993  pkg_failed=yes
71994fi
71995 else
71996    pkg_failed=untried
71997fi
71998if test -n "$LIBXML_LIBS"; then
71999    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
72000 elif test -n "$PKG_CONFIG"; then
72001    if test -n "$PKG_CONFIG" && \
72002    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
72003  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
72004  ac_status=$?
72005  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
72006  test $ac_status = 0; }; then
72007  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
72008		      test "x$?" != "x0" && pkg_failed=yes
72009else
72010  pkg_failed=yes
72011fi
72012 else
72013    pkg_failed=untried
72014fi
72015
72016
72017
72018if test $pkg_failed = yes; then
72019        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
72020printf "%s\n" "no" >&6; }
72021
72022if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
72023        _pkg_short_errors_supported=yes
72024else
72025        _pkg_short_errors_supported=no
72026fi
72027        if test $_pkg_short_errors_supported = yes; then
72028	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
72029        else
72030	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
72031        fi
72032	# Put the nasty error message in config.log where it belongs
72033	echo "$LIBXML_PKG_ERRORS" >&5
72034
72035	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
72036
72037$LIBXML_PKG_ERRORS
72038
72039Consider adjusting the PKG_CONFIG_PATH environment variable if you
72040installed software in a non-standard prefix.
72041
72042Alternatively, you may set the environment variables LIBXML_CFLAGS
72043and LIBXML_LIBS to avoid the need to call pkg-config.
72044See the pkg-config man page for more details." "$LINENO" 5
72045elif test $pkg_failed = untried; then
72046        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
72047printf "%s\n" "no" >&6; }
72048	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
72049printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
72050as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
72051is in your PATH or set the PKG_CONFIG environment variable to the full
72052path to pkg-config.
72053
72054Alternatively, you may set the environment variables LIBXML_CFLAGS
72055and LIBXML_LIBS to avoid the need to call pkg-config.
72056See the pkg-config man page for more details.
72057
72058To get pkg-config, see <http://pkg-config.freedesktop.org/>.
72059See \`config.log' for more details" "$LINENO" 5; }
72060else
72061	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
72062	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
72063        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
72064printf "%s\n" "yes" >&6; }
72065
72066fi
72067
72068
72069  for ac_i in $LIBXML_CFLAGS; do
72070    case $ac_i in
72071    -I*)
72072      ac_ii=`echo $ac_i|cut -c 3-`
72073
72074  if test "$ac_ii" != "/usr/include"; then
72075
72076  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
72077    ai_p=$ac_ii
72078  else
72079
72080    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
72081
72082    ep_realdir=`(cd "$ep_dir" && pwd)`
72083    ai_p="$ep_realdir"/`basename "$ac_ii"`
72084  fi
72085
72086
72087
72088  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
72089
72090  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
72091  if test -n "$unique" && test "`eval $cmd`" = "" ; then
72092    eval "INCLUDEPATH$unique=set"
72093
72094      if test ""; then
72095        INCLUDES="-I$ai_p $INCLUDES"
72096      else
72097        INCLUDES="$INCLUDES -I$ai_p"
72098      fi
72099
72100  fi
72101
72102  fi
72103
72104    ;;
72105    esac
72106  done
72107
72108
72109  for ac_i in $LIBXML_LIBS; do
72110    case $ac_i in
72111    -pthread)
72112      if test "$ext_shared" = "yes"; then
72113        SOAP_SHARED_LIBADD="$SOAP_SHARED_LIBADD -pthread"
72114      else
72115
72116
72117  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
72118
72119  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
72120  if test -n "$unique" && test "`eval $cmd`" = "" ; then
72121    eval "EXTRA_LDFLAGS$unique=set"
72122    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
72123  fi
72124
72125
72126
72127  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
72128
72129  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
72130  if test -n "$unique" && test "`eval $cmd`" = "" ; then
72131    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
72132    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
72133  fi
72134
72135      fi
72136    ;;
72137    -l*)
72138      ac_ii=`echo $ac_i|cut -c 3-`
72139
72140
72141  case $ac_ii in
72142  c|c_r) ;;
72143  *)
72144    if test "$ext_shared" = "yes"; then
72145        SOAP_SHARED_LIBADD="$SOAP_SHARED_LIBADD -l$ac_ii"
72146    else
72147
72148
72149  case $ac_ii in
72150  c|c_r) ;;
72151  *)
72152      LIBS="$LIBS -l$ac_ii"
72153   ;;
72154  esac
72155
72156
72157    fi
72158   ;;
72159  esac
72160
72161
72162    ;;
72163    -L*)
72164      ac_ii=`echo $ac_i|cut -c 3-`
72165
72166  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
72167
72168  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
72169    ai_p=$ac_ii
72170  else
72171
72172    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
72173
72174    ep_realdir=`(cd "$ep_dir" && pwd)`
72175    ai_p="$ep_realdir"/`basename "$ac_ii"`
72176  fi
72177
72178
72179      if test "$ext_shared" = "yes"; then
72180        SOAP_SHARED_LIBADD="-L$ai_p $SOAP_SHARED_LIBADD"
72181        test -n "$ld_runpath_switch" && SOAP_SHARED_LIBADD="$ld_runpath_switch$ai_p $SOAP_SHARED_LIBADD"
72182      else
72183
72184
72185
72186  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
72187
72188  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
72189  if test -n "$unique" && test "`eval $cmd`" = "" ; then
72190    eval "LIBPATH$unique=set"
72191
72192    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
72193    LDFLAGS="$LDFLAGS -L$ai_p"
72194    PHP_RPATHS="$PHP_RPATHS $ai_p"
72195
72196  fi
72197
72198
72199      fi
72200
72201  fi
72202
72203    ;;
72204    esac
72205  done
72206
72207
72208
72209printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
72210
72211
72212
72213
72214printf "%s\n" "#define HAVE_SOAP 1" >>confdefs.h
72215
72216
72217  ext_builddir=ext/soap
72218  ext_srcdir=$abs_srcdir/ext/soap
72219  ext_dir=ext/soap
72220
72221  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
72222
72223  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
72224    PHP_SOAP_SHARED=no
72225
72226
72227  case $ext_dir in
72228  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72229  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72230  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72231  esac
72232
72233
72234
72235  b_c_pre=$php_c_pre
72236  b_cxx_pre=$php_cxx_pre
72237  b_c_meta=$php_c_meta
72238  b_cxx_meta=$php_cxx_meta
72239  b_c_post=$php_c_post
72240  b_cxx_post=$php_cxx_post
72241  b_lo=$php_lo
72242
72243
72244  old_IFS=$IFS
72245  for ac_src in soap.c php_encoding.c php_http.c php_packet_soap.c php_schema.c php_sdl.c php_xml.c; do
72246
72247      IFS=.
72248      set $ac_src
72249      ac_obj=$1
72250      IFS=$old_IFS
72251
72252      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72253
72254      case $ac_src in
72255        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72256        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72257        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72258        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72259      esac
72260
72261      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72262
72263    cat >>Makefile.objects<<EOF
72264-include $ac_bdir$ac_obj.dep
72265$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72266	$ac_comp
72267EOF
72268  done
72269
72270
72271    EXT_STATIC="$EXT_STATIC soap;$ext_dir"
72272    if test "$ext_shared" != "nocli"; then
72273      EXT_CLI_STATIC="$EXT_CLI_STATIC soap;$ext_dir"
72274    fi
72275  else
72276    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
72277      PHP_SOAP_SHARED=yes
72278
72279  case $ext_dir in
72280  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72281  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72282  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72283  esac
72284
72285
72286
72287  b_c_pre=$shared_c_pre
72288  b_cxx_pre=$shared_cxx_pre
72289  b_c_meta=$shared_c_meta
72290  b_cxx_meta=$shared_cxx_meta
72291  b_c_post=$shared_c_post
72292  b_cxx_post=$shared_cxx_post
72293  b_lo=$shared_lo
72294
72295
72296  old_IFS=$IFS
72297  for ac_src in soap.c php_encoding.c php_http.c php_packet_soap.c php_schema.c php_sdl.c php_xml.c; do
72298
72299      IFS=.
72300      set $ac_src
72301      ac_obj=$1
72302      IFS=$old_IFS
72303
72304      shared_objects_soap="$shared_objects_soap $ac_bdir$ac_obj.lo"
72305
72306      case $ac_src in
72307        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72308        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72309        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72310        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72311      esac
72312
72313      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72314
72315    cat >>Makefile.objects<<EOF
72316-include $ac_bdir$ac_obj.dep
72317$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72318	$ac_comp
72319EOF
72320  done
72321
72322
72323  install_modules="install-modules"
72324  suffix=la
72325
72326  case $host_alias in
72327    *aix*)
72328      additional_flags="-Wl,-G"
72329      ;;
72330  esac
72331
72332  if test "x" = "xyes"; then
72333    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/soap.$suffix"
72334  else
72335    PHP_MODULES="$PHP_MODULES \$(phplibdir)/soap.$suffix"
72336  fi
72337
72338  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_soap"
72339
72340  cat >>Makefile.objects<<EOF
72341\$(phplibdir)/soap.$suffix: $ext_builddir/soap.$suffix
72342	\$(LIBTOOL) --mode=install cp $ext_builddir/soap.$suffix \$(phplibdir)
72343
72344$ext_builddir/soap.$suffix: \$(shared_objects_soap) \$(SOAP_SHARED_DEPENDENCIES)
72345	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_soap) \$(SOAP_SHARED_LIBADD)
72346
72347EOF
72348
72349
72350printf "%s\n" "#define COMPILE_DL_SOAP 1" >>confdefs.h
72351
72352    fi
72353  fi
72354
72355  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
72356    PHP_SOAP_SHARED=no
72357    case "$PHP_SAPI" in
72358      cgi|embed|phpdbg)
72359
72360
72361  case $ext_dir in
72362  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72363  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72364  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72365  esac
72366
72367
72368
72369  b_c_pre=$php_c_pre
72370  b_cxx_pre=$php_cxx_pre
72371  b_c_meta=$php_c_meta
72372  b_cxx_meta=$php_cxx_meta
72373  b_c_post=$php_c_post
72374  b_cxx_post=$php_cxx_post
72375  b_lo=$php_lo
72376
72377
72378  old_IFS=$IFS
72379  for ac_src in soap.c php_encoding.c php_http.c php_packet_soap.c php_schema.c php_sdl.c php_xml.c; do
72380
72381      IFS=.
72382      set $ac_src
72383      ac_obj=$1
72384      IFS=$old_IFS
72385
72386      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72387
72388      case $ac_src in
72389        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72390        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72391        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72392        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72393      esac
72394
72395      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72396
72397    cat >>Makefile.objects<<EOF
72398-include $ac_bdir$ac_obj.dep
72399$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72400	$ac_comp
72401EOF
72402  done
72403
72404
72405        EXT_STATIC="$EXT_STATIC soap;$ext_dir"
72406        ;;
72407      *)
72408
72409
72410  case $ext_dir in
72411  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72412  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72413  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72414  esac
72415
72416
72417
72418  b_c_pre=$php_c_pre
72419  b_cxx_pre=$php_cxx_pre
72420  b_c_meta=$php_c_meta
72421  b_cxx_meta=$php_cxx_meta
72422  b_c_post=$php_c_post
72423  b_cxx_post=$php_cxx_post
72424  b_lo=$php_lo
72425
72426
72427  old_IFS=$IFS
72428  for ac_src in soap.c php_encoding.c php_http.c php_packet_soap.c php_schema.c php_sdl.c php_xml.c; do
72429
72430      IFS=.
72431      set $ac_src
72432      ac_obj=$1
72433      IFS=$old_IFS
72434
72435      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72436
72437      case $ac_src in
72438        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72439        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72440        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72441        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72442      esac
72443
72444      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72445
72446    cat >>Makefile.objects<<EOF
72447-include $ac_bdir$ac_obj.dep
72448$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72449	$ac_comp
72450EOF
72451  done
72452
72453
72454        ;;
72455    esac
72456    EXT_CLI_STATIC="$EXT_CLI_STATIC soap;$ext_dir"
72457  fi
72458
72459
72460    BUILD_DIR="$BUILD_DIR $ext_builddir"
72461
72462
72463
72464  if test "$ext_builddir" = "."; then
72465    PHP_PECL_EXTENSION=soap
72466
72467  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
72468
72469  fi
72470
72471
72472  PHP_VAR_SUBST="$PHP_VAR_SUBST SOAP_SHARED_LIBADD"
72473
72474
72475
72476fi
72477
72478
72479
72480
72481
72482php_enable_sockets=no
72483
72484{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable sockets support" >&5
72485printf %s "checking whether to enable sockets support... " >&6; }
72486# Check whether --enable-sockets was given.
72487if test ${enable_sockets+y}
72488then :
72489  enableval=$enable_sockets; PHP_SOCKETS=$enableval
72490else $as_nop
72491
72492  PHP_SOCKETS=no
72493  test "$PHP_ENABLE_ALL" && PHP_SOCKETS=$PHP_ENABLE_ALL
72494
72495fi
72496
72497
72498
72499ext_output="yes, shared"
72500ext_shared=yes
72501case $PHP_SOCKETS in
72502shared,*)
72503  PHP_SOCKETS=`echo "$PHP_SOCKETS"|$SED 's/^shared,//'`
72504  ;;
72505shared)
72506  PHP_SOCKETS=yes
72507  ;;
72508no)
72509  ext_output=no
72510  ext_shared=no
72511  ;;
72512*)
72513  ext_output=yes
72514  ext_shared=no
72515  ;;
72516esac
72517
72518
72519
72520{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
72521printf "%s\n" "$ext_output" >&6; }
72522
72523
72524
72525
72526if test "$PHP_SOCKETS" != "no"; then
72527  ac_fn_c_check_func "$LINENO" "hstrerror" "ac_cv_func_hstrerror"
72528if test "x$ac_cv_func_hstrerror" = xyes
72529then :
72530  printf "%s\n" "#define HAVE_HSTRERROR 1" >>confdefs.h
72531
72532fi
72533ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex"
72534if test "x$ac_cv_func_if_nametoindex" = xyes
72535then :
72536  printf "%s\n" "#define HAVE_IF_NAMETOINDEX 1" >>confdefs.h
72537
72538fi
72539ac_fn_c_check_func "$LINENO" "if_indextoname" "ac_cv_func_if_indextoname"
72540if test "x$ac_cv_func_if_indextoname" = xyes
72541then :
72542  printf "%s\n" "#define HAVE_IF_INDEXTONAME 1" >>confdefs.h
72543
72544fi
72545
72546  ac_fn_c_check_header_compile "$LINENO" "netinet/tcp.h" "ac_cv_header_netinet_tcp_h" "$ac_includes_default"
72547if test "x$ac_cv_header_netinet_tcp_h" = xyes
72548then :
72549  printf "%s\n" "#define HAVE_NETINET_TCP_H 1" >>confdefs.h
72550
72551fi
72552ac_fn_c_check_header_compile "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
72553if test "x$ac_cv_header_sys_un_h" = xyes
72554then :
72555  printf "%s\n" "#define HAVE_SYS_UN_H 1" >>confdefs.h
72556
72557fi
72558ac_fn_c_check_header_compile "$LINENO" "sys/sockio.h" "ac_cv_header_sys_sockio_h" "$ac_includes_default"
72559if test "x$ac_cv_header_sys_sockio_h" = xyes
72560then :
72561  printf "%s\n" "#define HAVE_SYS_SOCKIO_H 1" >>confdefs.h
72562
72563fi
72564
72565
72566printf "%s\n" "#define HAVE_SOCKETS 1" >>confdefs.h
72567
72568
72569    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for field ss_family in struct sockaddr_storage" >&5
72570printf %s "checking for field ss_family in struct sockaddr_storage... " >&6; }
72571if test ${ac_cv_ss_family+y}
72572then :
72573  printf %s "(cached) " >&6
72574else $as_nop
72575
72576    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
72577/* end confdefs.h.  */
72578
72579#include <sys/socket.h>
72580#include <sys/types.h>
72581#include <netdb.h>
72582
72583int
72584main (void)
72585{
72586struct sockaddr_storage sa_store; sa_store.ss_family = AF_INET6;
72587  ;
72588  return 0;
72589}
72590_ACEOF
72591if ac_fn_c_try_compile "$LINENO"
72592then :
72593  ac_cv_ss_family=yes
72594else $as_nop
72595  ac_cv_ss_family=no
72596fi
72597rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
72598
72599fi
72600{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_ss_family" >&5
72601printf "%s\n" "$ac_cv_ss_family" >&6; }
72602
72603  if test "$ac_cv_ss_family" = yes; then
72604
72605printf "%s\n" "#define HAVE_SA_SS_FAMILY 1" >>confdefs.h
72606
72607  fi
72608
72609    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo supports AI_V4MAPPED" >&5
72610printf %s "checking if getaddrinfo supports AI_V4MAPPED... " >&6; }
72611if test ${ac_cv_gai_ai_v4mapped+y}
72612then :
72613  printf %s "(cached) " >&6
72614else $as_nop
72615
72616    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
72617/* end confdefs.h.  */
72618
72619#include <netdb.h>
72620
72621int
72622main (void)
72623{
72624int flag = AI_V4MAPPED;
72625  ;
72626  return 0;
72627}
72628_ACEOF
72629if ac_fn_c_try_compile "$LINENO"
72630then :
72631  ac_cv_gai_ai_v4mapped=yes
72632else $as_nop
72633  ac_cv_gai_ai_v4mapped=no
72634fi
72635rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
72636
72637fi
72638{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gai_ai_v4mapped" >&5
72639printf "%s\n" "$ac_cv_gai_ai_v4mapped" >&6; }
72640
72641  if test "$ac_cv_gai_ai_v4mapped" = yes; then
72642
72643printf "%s\n" "#define HAVE_AI_V4MAPPED 1" >>confdefs.h
72644
72645  fi
72646
72647    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo supports AI_ALL" >&5
72648printf %s "checking if getaddrinfo supports AI_ALL... " >&6; }
72649if test ${ac_cv_gai_ai_all+y}
72650then :
72651  printf %s "(cached) " >&6
72652else $as_nop
72653
72654    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
72655/* end confdefs.h.  */
72656
72657#include <netdb.h>
72658
72659int
72660main (void)
72661{
72662int flag = AI_ALL;
72663  ;
72664  return 0;
72665}
72666_ACEOF
72667if ac_fn_c_try_compile "$LINENO"
72668then :
72669  ac_cv_gai_ai_all=yes
72670else $as_nop
72671  ac_cv_gai_ai_all=no
72672fi
72673rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
72674
72675fi
72676{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gai_ai_all" >&5
72677printf "%s\n" "$ac_cv_gai_ai_all" >&6; }
72678
72679  if test "$ac_cv_gai_ai_all" = yes; then
72680
72681printf "%s\n" "#define HAVE_AI_ALL 1" >>confdefs.h
72682
72683  fi
72684
72685    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo supports AI_IDN" >&5
72686printf %s "checking if getaddrinfo supports AI_IDN... " >&6; }
72687if test ${ac_cv_gai_ai_idn+y}
72688then :
72689  printf %s "(cached) " >&6
72690else $as_nop
72691
72692    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
72693/* end confdefs.h.  */
72694
72695#include <netdb.h>
72696
72697int
72698main (void)
72699{
72700int flag = AI_IDN;
72701  ;
72702  return 0;
72703}
72704_ACEOF
72705if ac_fn_c_try_compile "$LINENO"
72706then :
72707  ac_cv_gai_ai_idn=yes
72708else $as_nop
72709  ac_cv_gai_ai_idn=no
72710fi
72711rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
72712
72713fi
72714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gai_ai_idn" >&5
72715printf "%s\n" "$ac_cv_gai_ai_idn" >&6; }
72716
72717  if test "$ac_cv_gai_ai_idn" = yes; then
72718
72719printf "%s\n" "#define HAVE_AI_IDN 1" >>confdefs.h
72720
72721  fi
72722
72723  PHP_SOCKETS_CFLAGS=-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1
72724  case $host_alias in
72725  *darwin*) PHP_SOCKETS_CFLAGS="$PHP_SOCKETS_CFLAGS -D__APPLE_USE_RFC_3542"
72726  esac
72727
72728  ext_builddir=ext/sockets
72729  ext_srcdir=$abs_srcdir/ext/sockets
72730  ext_dir=ext/sockets
72731
72732  ac_extra=`echo "$PHP_SOCKETS_CFLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
72733
72734  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
72735    PHP_SOCKETS_SHARED=no
72736
72737
72738  case $ext_dir in
72739  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72740  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72741  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72742  esac
72743
72744
72745
72746  b_c_pre=$php_c_pre
72747  b_cxx_pre=$php_cxx_pre
72748  b_c_meta=$php_c_meta
72749  b_cxx_meta=$php_cxx_meta
72750  b_c_post=$php_c_post
72751  b_cxx_post=$php_cxx_post
72752  b_lo=$php_lo
72753
72754
72755  old_IFS=$IFS
72756  for ac_src in sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c; do
72757
72758      IFS=.
72759      set $ac_src
72760      ac_obj=$1
72761      IFS=$old_IFS
72762
72763      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72764
72765      case $ac_src in
72766        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72767        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72768        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72769        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72770      esac
72771
72772      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72773
72774    cat >>Makefile.objects<<EOF
72775-include $ac_bdir$ac_obj.dep
72776$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72777	$ac_comp
72778EOF
72779  done
72780
72781
72782    EXT_STATIC="$EXT_STATIC sockets;$ext_dir"
72783    if test "$ext_shared" != "nocli"; then
72784      EXT_CLI_STATIC="$EXT_CLI_STATIC sockets;$ext_dir"
72785    fi
72786  else
72787    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
72788      PHP_SOCKETS_SHARED=yes
72789
72790  case $ext_dir in
72791  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72792  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72793  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72794  esac
72795
72796
72797
72798  b_c_pre=$shared_c_pre
72799  b_cxx_pre=$shared_cxx_pre
72800  b_c_meta=$shared_c_meta
72801  b_cxx_meta=$shared_cxx_meta
72802  b_c_post=$shared_c_post
72803  b_cxx_post=$shared_cxx_post
72804  b_lo=$shared_lo
72805
72806
72807  old_IFS=$IFS
72808  for ac_src in sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c; do
72809
72810      IFS=.
72811      set $ac_src
72812      ac_obj=$1
72813      IFS=$old_IFS
72814
72815      shared_objects_sockets="$shared_objects_sockets $ac_bdir$ac_obj.lo"
72816
72817      case $ac_src in
72818        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72819        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72820        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72821        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72822      esac
72823
72824      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72825
72826    cat >>Makefile.objects<<EOF
72827-include $ac_bdir$ac_obj.dep
72828$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72829	$ac_comp
72830EOF
72831  done
72832
72833
72834  install_modules="install-modules"
72835  suffix=la
72836
72837  case $host_alias in
72838    *aix*)
72839      additional_flags="-Wl,-G"
72840      ;;
72841  esac
72842
72843  if test "x" = "xyes"; then
72844    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sockets.$suffix"
72845  else
72846    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sockets.$suffix"
72847  fi
72848
72849  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sockets"
72850
72851  cat >>Makefile.objects<<EOF
72852\$(phplibdir)/sockets.$suffix: $ext_builddir/sockets.$suffix
72853	\$(LIBTOOL) --mode=install cp $ext_builddir/sockets.$suffix \$(phplibdir)
72854
72855$ext_builddir/sockets.$suffix: \$(shared_objects_sockets) \$(SOCKETS_SHARED_DEPENDENCIES)
72856	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sockets) \$(SOCKETS_SHARED_LIBADD)
72857
72858EOF
72859
72860
72861printf "%s\n" "#define COMPILE_DL_SOCKETS 1" >>confdefs.h
72862
72863    fi
72864  fi
72865
72866  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
72867    PHP_SOCKETS_SHARED=no
72868    case "$PHP_SAPI" in
72869      cgi|embed|phpdbg)
72870
72871
72872  case $ext_dir in
72873  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72874  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72875  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72876  esac
72877
72878
72879
72880  b_c_pre=$php_c_pre
72881  b_cxx_pre=$php_cxx_pre
72882  b_c_meta=$php_c_meta
72883  b_cxx_meta=$php_cxx_meta
72884  b_c_post=$php_c_post
72885  b_cxx_post=$php_cxx_post
72886  b_lo=$php_lo
72887
72888
72889  old_IFS=$IFS
72890  for ac_src in sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c; do
72891
72892      IFS=.
72893      set $ac_src
72894      ac_obj=$1
72895      IFS=$old_IFS
72896
72897      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72898
72899      case $ac_src in
72900        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72901        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72902        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72903        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72904      esac
72905
72906      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72907
72908    cat >>Makefile.objects<<EOF
72909-include $ac_bdir$ac_obj.dep
72910$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72911	$ac_comp
72912EOF
72913  done
72914
72915
72916        EXT_STATIC="$EXT_STATIC sockets;$ext_dir"
72917        ;;
72918      *)
72919
72920
72921  case $ext_dir in
72922  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
72923  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
72924  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
72925  esac
72926
72927
72928
72929  b_c_pre=$php_c_pre
72930  b_cxx_pre=$php_cxx_pre
72931  b_c_meta=$php_c_meta
72932  b_cxx_meta=$php_cxx_meta
72933  b_c_post=$php_c_post
72934  b_cxx_post=$php_cxx_post
72935  b_lo=$php_lo
72936
72937
72938  old_IFS=$IFS
72939  for ac_src in sockets.c multicast.c conversions.c sockaddr_conv.c sendrecvmsg.c; do
72940
72941      IFS=.
72942      set $ac_src
72943      ac_obj=$1
72944      IFS=$old_IFS
72945
72946      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
72947
72948      case $ac_src in
72949        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72950        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72951        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
72952        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
72953      esac
72954
72955      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
72956
72957    cat >>Makefile.objects<<EOF
72958-include $ac_bdir$ac_obj.dep
72959$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
72960	$ac_comp
72961EOF
72962  done
72963
72964
72965        ;;
72966    esac
72967    EXT_CLI_STATIC="$EXT_CLI_STATIC sockets;$ext_dir"
72968  fi
72969
72970
72971    BUILD_DIR="$BUILD_DIR $ext_builddir"
72972
72973
72974
72975  if test "$ext_builddir" = "."; then
72976    PHP_PECL_EXTENSION=sockets
72977
72978  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
72979
72980  fi
72981
72982
72983
72984    header_path=ext/sockets/
72985    for header_file in php_sockets.h; do
72986      hp_hf="$header_path/$header_file"
72987
72988
72989  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
72990
72991  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
72992  if test -n "$unique" && test "`eval $cmd`" = "" ; then
72993    eval "INSTALLHEADERS$unique=set"
72994
72995        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
72996
72997  fi
72998
72999    done
73000
73001
73002fi
73003
73004
73005
73006
73007
73008php_with_sodium=no
73009
73010{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sodium support" >&5
73011printf %s "checking for sodium support... " >&6; }
73012
73013# Check whether --with-sodium was given.
73014if test ${with_sodium+y}
73015then :
73016  withval=$with_sodium; PHP_SODIUM=$withval
73017else $as_nop
73018
73019  PHP_SODIUM=no
73020  test "$PHP_ENABLE_ALL" && PHP_SODIUM=$PHP_ENABLE_ALL
73021
73022fi
73023
73024
73025
73026ext_output="yes, shared"
73027ext_shared=yes
73028case $PHP_SODIUM in
73029shared,*)
73030  PHP_SODIUM=`echo "$PHP_SODIUM"|$SED 's/^shared,//'`
73031  ;;
73032shared)
73033  PHP_SODIUM=yes
73034  ;;
73035no)
73036  ext_output=no
73037  ext_shared=no
73038  ;;
73039*)
73040  ext_output=yes
73041  ext_shared=no
73042  ;;
73043esac
73044
73045
73046
73047{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
73048printf "%s\n" "$ext_output" >&6; }
73049
73050
73051
73052
73053if test "$PHP_SODIUM" != "no"; then
73054
73055pkg_failed=no
73056{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libsodium >= 1.0.8" >&5
73057printf %s "checking for libsodium >= 1.0.8... " >&6; }
73058
73059if test -n "$LIBSODIUM_CFLAGS"; then
73060    pkg_cv_LIBSODIUM_CFLAGS="$LIBSODIUM_CFLAGS"
73061 elif test -n "$PKG_CONFIG"; then
73062    if test -n "$PKG_CONFIG" && \
73063    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsodium >= 1.0.8\""; } >&5
73064  ($PKG_CONFIG --exists --print-errors "libsodium >= 1.0.8") 2>&5
73065  ac_status=$?
73066  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
73067  test $ac_status = 0; }; then
73068  pkg_cv_LIBSODIUM_CFLAGS=`$PKG_CONFIG --cflags "libsodium >= 1.0.8" 2>/dev/null`
73069		      test "x$?" != "x0" && pkg_failed=yes
73070else
73071  pkg_failed=yes
73072fi
73073 else
73074    pkg_failed=untried
73075fi
73076if test -n "$LIBSODIUM_LIBS"; then
73077    pkg_cv_LIBSODIUM_LIBS="$LIBSODIUM_LIBS"
73078 elif test -n "$PKG_CONFIG"; then
73079    if test -n "$PKG_CONFIG" && \
73080    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsodium >= 1.0.8\""; } >&5
73081  ($PKG_CONFIG --exists --print-errors "libsodium >= 1.0.8") 2>&5
73082  ac_status=$?
73083  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
73084  test $ac_status = 0; }; then
73085  pkg_cv_LIBSODIUM_LIBS=`$PKG_CONFIG --libs "libsodium >= 1.0.8" 2>/dev/null`
73086		      test "x$?" != "x0" && pkg_failed=yes
73087else
73088  pkg_failed=yes
73089fi
73090 else
73091    pkg_failed=untried
73092fi
73093
73094
73095
73096if test $pkg_failed = yes; then
73097        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
73098printf "%s\n" "no" >&6; }
73099
73100if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
73101        _pkg_short_errors_supported=yes
73102else
73103        _pkg_short_errors_supported=no
73104fi
73105        if test $_pkg_short_errors_supported = yes; then
73106	        LIBSODIUM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsodium >= 1.0.8" 2>&1`
73107        else
73108	        LIBSODIUM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsodium >= 1.0.8" 2>&1`
73109        fi
73110	# Put the nasty error message in config.log where it belongs
73111	echo "$LIBSODIUM_PKG_ERRORS" >&5
73112
73113	as_fn_error $? "Package requirements (libsodium >= 1.0.8) were not met:
73114
73115$LIBSODIUM_PKG_ERRORS
73116
73117Consider adjusting the PKG_CONFIG_PATH environment variable if you
73118installed software in a non-standard prefix.
73119
73120Alternatively, you may set the environment variables LIBSODIUM_CFLAGS
73121and LIBSODIUM_LIBS to avoid the need to call pkg-config.
73122See the pkg-config man page for more details." "$LINENO" 5
73123elif test $pkg_failed = untried; then
73124        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
73125printf "%s\n" "no" >&6; }
73126	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
73127printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
73128as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
73129is in your PATH or set the PKG_CONFIG environment variable to the full
73130path to pkg-config.
73131
73132Alternatively, you may set the environment variables LIBSODIUM_CFLAGS
73133and LIBSODIUM_LIBS to avoid the need to call pkg-config.
73134See the pkg-config man page for more details.
73135
73136To get pkg-config, see <http://pkg-config.freedesktop.org/>.
73137See \`config.log' for more details" "$LINENO" 5; }
73138else
73139	LIBSODIUM_CFLAGS=$pkg_cv_LIBSODIUM_CFLAGS
73140	LIBSODIUM_LIBS=$pkg_cv_LIBSODIUM_LIBS
73141        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
73142printf "%s\n" "yes" >&6; }
73143
73144fi
73145
73146
73147  for ac_i in $LIBSODIUM_CFLAGS; do
73148    case $ac_i in
73149    -I*)
73150      ac_ii=`echo $ac_i|cut -c 3-`
73151
73152  if test "$ac_ii" != "/usr/include"; then
73153
73154  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
73155    ai_p=$ac_ii
73156  else
73157
73158    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
73159
73160    ep_realdir=`(cd "$ep_dir" && pwd)`
73161    ai_p="$ep_realdir"/`basename "$ac_ii"`
73162  fi
73163
73164
73165
73166  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
73167
73168  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
73169  if test -n "$unique" && test "`eval $cmd`" = "" ; then
73170    eval "INCLUDEPATH$unique=set"
73171
73172      if test ""; then
73173        INCLUDES="-I$ai_p $INCLUDES"
73174      else
73175        INCLUDES="$INCLUDES -I$ai_p"
73176      fi
73177
73178  fi
73179
73180  fi
73181
73182    ;;
73183    esac
73184  done
73185
73186
73187  for ac_i in $LIBSODIUM_LIBS; do
73188    case $ac_i in
73189    -pthread)
73190      if test "$ext_shared" = "yes"; then
73191        SODIUM_SHARED_LIBADD="$SODIUM_SHARED_LIBADD -pthread"
73192      else
73193
73194
73195  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
73196
73197  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
73198  if test -n "$unique" && test "`eval $cmd`" = "" ; then
73199    eval "EXTRA_LDFLAGS$unique=set"
73200    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
73201  fi
73202
73203
73204
73205  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
73206
73207  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
73208  if test -n "$unique" && test "`eval $cmd`" = "" ; then
73209    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
73210    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
73211  fi
73212
73213      fi
73214    ;;
73215    -l*)
73216      ac_ii=`echo $ac_i|cut -c 3-`
73217
73218
73219  case $ac_ii in
73220  c|c_r) ;;
73221  *)
73222    if test "$ext_shared" = "yes"; then
73223        SODIUM_SHARED_LIBADD="$SODIUM_SHARED_LIBADD -l$ac_ii"
73224    else
73225
73226
73227  case $ac_ii in
73228  c|c_r) ;;
73229  *)
73230      LIBS="$LIBS -l$ac_ii"
73231   ;;
73232  esac
73233
73234
73235    fi
73236   ;;
73237  esac
73238
73239
73240    ;;
73241    -L*)
73242      ac_ii=`echo $ac_i|cut -c 3-`
73243
73244  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
73245
73246  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
73247    ai_p=$ac_ii
73248  else
73249
73250    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
73251
73252    ep_realdir=`(cd "$ep_dir" && pwd)`
73253    ai_p="$ep_realdir"/`basename "$ac_ii"`
73254  fi
73255
73256
73257      if test "$ext_shared" = "yes"; then
73258        SODIUM_SHARED_LIBADD="-L$ai_p $SODIUM_SHARED_LIBADD"
73259        test -n "$ld_runpath_switch" && SODIUM_SHARED_LIBADD="$ld_runpath_switch$ai_p $SODIUM_SHARED_LIBADD"
73260      else
73261
73262
73263
73264  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
73265
73266  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
73267  if test -n "$unique" && test "`eval $cmd`" = "" ; then
73268    eval "LIBPATH$unique=set"
73269
73270    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
73271    LDFLAGS="$LDFLAGS -L$ai_p"
73272    PHP_RPATHS="$PHP_RPATHS $ai_p"
73273
73274  fi
73275
73276
73277      fi
73278
73279  fi
73280
73281    ;;
73282    esac
73283  done
73284
73285
73286
73287printf "%s\n" "#define HAVE_LIBSODIUMLIB 1" >>confdefs.h
73288
73289
73290    SODIUM_COMPILER_FLAGS="$LIBSODIUM_CFLAGS -Wno-type-limits"
73291  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wno-logical-op" >&5
73292printf %s "checking whether C compiler accepts -Wno-logical-op... " >&6; }
73293if test ${ax_cv_check_cflags__Werror__Wno_logical_op+y}
73294then :
73295  printf %s "(cached) " >&6
73296else $as_nop
73297
73298  ax_check_save_flags=$CFLAGS
73299  CFLAGS="$CFLAGS -Werror -Wno-logical-op"
73300  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73301/* end confdefs.h.  */
73302
73303int
73304main (void)
73305{
73306
73307  ;
73308  return 0;
73309}
73310_ACEOF
73311if ac_fn_c_try_compile "$LINENO"
73312then :
73313  ax_cv_check_cflags__Werror__Wno_logical_op=yes
73314else $as_nop
73315  ax_cv_check_cflags__Werror__Wno_logical_op=no
73316fi
73317rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
73318  CFLAGS=$ax_check_save_flags
73319fi
73320{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wno_logical_op" >&5
73321printf "%s\n" "$ax_cv_check_cflags__Werror__Wno_logical_op" >&6; }
73322if test "x$ax_cv_check_cflags__Werror__Wno_logical_op" = xyes
73323then :
73324  SODIUM_COMPILER_FLAGS="$SODIUM_COMPILER_FLAGS -Wno-logical-op"
73325else $as_nop
73326  :
73327fi
73328
73329
73330  ext_builddir=ext/sodium
73331  ext_srcdir=$abs_srcdir/ext/sodium
73332  ext_dir=ext/sodium
73333
73334  ac_extra=`echo "$SODIUM_COMPILER_FLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
73335
73336  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
73337    PHP_SODIUM_SHARED=no
73338
73339
73340  case $ext_dir in
73341  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73342  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73343  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73344  esac
73345
73346
73347
73348  b_c_pre=$php_c_pre
73349  b_cxx_pre=$php_cxx_pre
73350  b_c_meta=$php_c_meta
73351  b_cxx_meta=$php_cxx_meta
73352  b_c_post=$php_c_post
73353  b_cxx_post=$php_cxx_post
73354  b_lo=$php_lo
73355
73356
73357  old_IFS=$IFS
73358  for ac_src in libsodium.c sodium_pwhash.c; do
73359
73360      IFS=.
73361      set $ac_src
73362      ac_obj=$1
73363      IFS=$old_IFS
73364
73365      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73366
73367      case $ac_src in
73368        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73369        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73370        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73371        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73372      esac
73373
73374      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73375
73376    cat >>Makefile.objects<<EOF
73377-include $ac_bdir$ac_obj.dep
73378$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73379	$ac_comp
73380EOF
73381  done
73382
73383
73384    EXT_STATIC="$EXT_STATIC sodium;$ext_dir"
73385    if test "$ext_shared" != "nocli"; then
73386      EXT_CLI_STATIC="$EXT_CLI_STATIC sodium;$ext_dir"
73387    fi
73388  else
73389    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
73390      PHP_SODIUM_SHARED=yes
73391
73392  case $ext_dir in
73393  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73394  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73395  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73396  esac
73397
73398
73399
73400  b_c_pre=$shared_c_pre
73401  b_cxx_pre=$shared_cxx_pre
73402  b_c_meta=$shared_c_meta
73403  b_cxx_meta=$shared_cxx_meta
73404  b_c_post=$shared_c_post
73405  b_cxx_post=$shared_cxx_post
73406  b_lo=$shared_lo
73407
73408
73409  old_IFS=$IFS
73410  for ac_src in libsodium.c sodium_pwhash.c; do
73411
73412      IFS=.
73413      set $ac_src
73414      ac_obj=$1
73415      IFS=$old_IFS
73416
73417      shared_objects_sodium="$shared_objects_sodium $ac_bdir$ac_obj.lo"
73418
73419      case $ac_src in
73420        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73421        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73422        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73423        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73424      esac
73425
73426      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73427
73428    cat >>Makefile.objects<<EOF
73429-include $ac_bdir$ac_obj.dep
73430$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73431	$ac_comp
73432EOF
73433  done
73434
73435
73436  install_modules="install-modules"
73437  suffix=la
73438
73439  case $host_alias in
73440    *aix*)
73441      additional_flags="-Wl,-G"
73442      ;;
73443  esac
73444
73445  if test "x" = "xyes"; then
73446    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sodium.$suffix"
73447  else
73448    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sodium.$suffix"
73449  fi
73450
73451  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sodium"
73452
73453  cat >>Makefile.objects<<EOF
73454\$(phplibdir)/sodium.$suffix: $ext_builddir/sodium.$suffix
73455	\$(LIBTOOL) --mode=install cp $ext_builddir/sodium.$suffix \$(phplibdir)
73456
73457$ext_builddir/sodium.$suffix: \$(shared_objects_sodium) \$(SODIUM_SHARED_DEPENDENCIES)
73458	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sodium) \$(SODIUM_SHARED_LIBADD)
73459
73460EOF
73461
73462
73463printf "%s\n" "#define COMPILE_DL_SODIUM 1" >>confdefs.h
73464
73465    fi
73466  fi
73467
73468  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
73469    PHP_SODIUM_SHARED=no
73470    case "$PHP_SAPI" in
73471      cgi|embed|phpdbg)
73472
73473
73474  case $ext_dir in
73475  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73476  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73477  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73478  esac
73479
73480
73481
73482  b_c_pre=$php_c_pre
73483  b_cxx_pre=$php_cxx_pre
73484  b_c_meta=$php_c_meta
73485  b_cxx_meta=$php_cxx_meta
73486  b_c_post=$php_c_post
73487  b_cxx_post=$php_cxx_post
73488  b_lo=$php_lo
73489
73490
73491  old_IFS=$IFS
73492  for ac_src in libsodium.c sodium_pwhash.c; do
73493
73494      IFS=.
73495      set $ac_src
73496      ac_obj=$1
73497      IFS=$old_IFS
73498
73499      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73500
73501      case $ac_src in
73502        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73503        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73504        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73505        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73506      esac
73507
73508      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73509
73510    cat >>Makefile.objects<<EOF
73511-include $ac_bdir$ac_obj.dep
73512$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73513	$ac_comp
73514EOF
73515  done
73516
73517
73518        EXT_STATIC="$EXT_STATIC sodium;$ext_dir"
73519        ;;
73520      *)
73521
73522
73523  case $ext_dir in
73524  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73525  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73526  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73527  esac
73528
73529
73530
73531  b_c_pre=$php_c_pre
73532  b_cxx_pre=$php_cxx_pre
73533  b_c_meta=$php_c_meta
73534  b_cxx_meta=$php_cxx_meta
73535  b_c_post=$php_c_post
73536  b_cxx_post=$php_cxx_post
73537  b_lo=$php_lo
73538
73539
73540  old_IFS=$IFS
73541  for ac_src in libsodium.c sodium_pwhash.c; do
73542
73543      IFS=.
73544      set $ac_src
73545      ac_obj=$1
73546      IFS=$old_IFS
73547
73548      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73549
73550      case $ac_src in
73551        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73552        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73553        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73554        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73555      esac
73556
73557      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73558
73559    cat >>Makefile.objects<<EOF
73560-include $ac_bdir$ac_obj.dep
73561$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73562	$ac_comp
73563EOF
73564  done
73565
73566
73567        ;;
73568    esac
73569    EXT_CLI_STATIC="$EXT_CLI_STATIC sodium;$ext_dir"
73570  fi
73571
73572
73573    BUILD_DIR="$BUILD_DIR $ext_builddir"
73574
73575
73576
73577  if test "$ext_builddir" = "."; then
73578    PHP_PECL_EXTENSION=sodium
73579
73580  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
73581
73582  fi
73583
73584
73585  PHP_VAR_SUBST="$PHP_VAR_SUBST SODIUM_SHARED_LIBADD"
73586
73587fi
73588
73589
73590
73591
73592
73593  ext_builddir=ext/spl
73594  ext_srcdir=$abs_srcdir/ext/spl
73595  ext_dir=ext/spl
73596
73597  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
73598
73599  if test "no" != "shared" && test "no" != "yes" && test "" != "cli"; then
73600    PHP_SPL_SHARED=no
73601
73602
73603  case $ext_dir in
73604  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73605  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73606  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73607  esac
73608
73609
73610
73611  b_c_pre=$php_c_pre
73612  b_cxx_pre=$php_cxx_pre
73613  b_c_meta=$php_c_meta
73614  b_cxx_meta=$php_cxx_meta
73615  b_c_post=$php_c_post
73616  b_cxx_post=$php_cxx_post
73617  b_lo=$php_lo
73618
73619
73620  old_IFS=$IFS
73621  for ac_src in php_spl.c spl_functions.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c; do
73622
73623      IFS=.
73624      set $ac_src
73625      ac_obj=$1
73626      IFS=$old_IFS
73627
73628      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73629
73630      case $ac_src in
73631        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73632        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73633        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73634        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73635      esac
73636
73637      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73638
73639    cat >>Makefile.objects<<EOF
73640-include $ac_bdir$ac_obj.dep
73641$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73642	$ac_comp
73643EOF
73644  done
73645
73646
73647    EXT_STATIC="$EXT_STATIC spl;$ext_dir"
73648    if test "no" != "nocli"; then
73649      EXT_CLI_STATIC="$EXT_CLI_STATIC spl;$ext_dir"
73650    fi
73651  else
73652    if test "no" = "shared" || test "no" = "yes"; then
73653      PHP_SPL_SHARED=yes
73654
73655  case $ext_dir in
73656  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73657  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73658  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73659  esac
73660
73661
73662
73663  b_c_pre=$shared_c_pre
73664  b_cxx_pre=$shared_cxx_pre
73665  b_c_meta=$shared_c_meta
73666  b_cxx_meta=$shared_cxx_meta
73667  b_c_post=$shared_c_post
73668  b_cxx_post=$shared_cxx_post
73669  b_lo=$shared_lo
73670
73671
73672  old_IFS=$IFS
73673  for ac_src in php_spl.c spl_functions.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c; do
73674
73675      IFS=.
73676      set $ac_src
73677      ac_obj=$1
73678      IFS=$old_IFS
73679
73680      shared_objects_spl="$shared_objects_spl $ac_bdir$ac_obj.lo"
73681
73682      case $ac_src in
73683        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73684        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73685        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73686        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73687      esac
73688
73689      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73690
73691    cat >>Makefile.objects<<EOF
73692-include $ac_bdir$ac_obj.dep
73693$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73694	$ac_comp
73695EOF
73696  done
73697
73698
73699  install_modules="install-modules"
73700  suffix=la
73701
73702  case $host_alias in
73703    *aix*)
73704      additional_flags="-Wl,-G"
73705      ;;
73706  esac
73707
73708  if test "x" = "xyes"; then
73709    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/spl.$suffix"
73710  else
73711    PHP_MODULES="$PHP_MODULES \$(phplibdir)/spl.$suffix"
73712  fi
73713
73714  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_spl"
73715
73716  cat >>Makefile.objects<<EOF
73717\$(phplibdir)/spl.$suffix: $ext_builddir/spl.$suffix
73718	\$(LIBTOOL) --mode=install cp $ext_builddir/spl.$suffix \$(phplibdir)
73719
73720$ext_builddir/spl.$suffix: \$(shared_objects_spl) \$(SPL_SHARED_DEPENDENCIES)
73721	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_spl) \$(SPL_SHARED_LIBADD)
73722
73723EOF
73724
73725
73726printf "%s\n" "#define COMPILE_DL_SPL 1" >>confdefs.h
73727
73728    fi
73729  fi
73730
73731  if test "no" != "shared" && test "no" != "yes" && test "" = "cli"; then
73732    PHP_SPL_SHARED=no
73733    case "$PHP_SAPI" in
73734      cgi|embed|phpdbg)
73735
73736
73737  case $ext_dir in
73738  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73739  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73740  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73741  esac
73742
73743
73744
73745  b_c_pre=$php_c_pre
73746  b_cxx_pre=$php_cxx_pre
73747  b_c_meta=$php_c_meta
73748  b_cxx_meta=$php_cxx_meta
73749  b_c_post=$php_c_post
73750  b_cxx_post=$php_cxx_post
73751  b_lo=$php_lo
73752
73753
73754  old_IFS=$IFS
73755  for ac_src in php_spl.c spl_functions.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c; do
73756
73757      IFS=.
73758      set $ac_src
73759      ac_obj=$1
73760      IFS=$old_IFS
73761
73762      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73763
73764      case $ac_src in
73765        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73766        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73767        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73768        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73769      esac
73770
73771      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73772
73773    cat >>Makefile.objects<<EOF
73774-include $ac_bdir$ac_obj.dep
73775$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73776	$ac_comp
73777EOF
73778  done
73779
73780
73781        EXT_STATIC="$EXT_STATIC spl;$ext_dir"
73782        ;;
73783      *)
73784
73785
73786  case $ext_dir in
73787  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
73788  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
73789  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
73790  esac
73791
73792
73793
73794  b_c_pre=$php_c_pre
73795  b_cxx_pre=$php_cxx_pre
73796  b_c_meta=$php_c_meta
73797  b_cxx_meta=$php_cxx_meta
73798  b_c_post=$php_c_post
73799  b_cxx_post=$php_cxx_post
73800  b_lo=$php_lo
73801
73802
73803  old_IFS=$IFS
73804  for ac_src in php_spl.c spl_functions.c spl_iterators.c spl_array.c spl_directory.c spl_exceptions.c spl_observer.c spl_dllist.c spl_heap.c spl_fixedarray.c; do
73805
73806      IFS=.
73807      set $ac_src
73808      ac_obj=$1
73809      IFS=$old_IFS
73810
73811      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
73812
73813      case $ac_src in
73814        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73815        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73816        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
73817        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
73818      esac
73819
73820      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
73821
73822    cat >>Makefile.objects<<EOF
73823-include $ac_bdir$ac_obj.dep
73824$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
73825	$ac_comp
73826EOF
73827  done
73828
73829
73830        ;;
73831    esac
73832    EXT_CLI_STATIC="$EXT_CLI_STATIC spl;$ext_dir"
73833  fi
73834
73835
73836    BUILD_DIR="$BUILD_DIR $ext_builddir"
73837
73838
73839
73840  if test "$ext_builddir" = "."; then
73841    PHP_PECL_EXTENSION=spl
73842
73843  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
73844
73845  fi
73846
73847
73848
73849    header_path=ext/spl
73850    for header_file in php_spl.h spl_array.h spl_directory.h spl_engine.h spl_exceptions.h spl_functions.h spl_iterators.h spl_observer.h spl_dllist.h spl_heap.h spl_fixedarray.h; do
73851      hp_hf="$header_path/$header_file"
73852
73853
73854  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
73855
73856  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
73857  if test -n "$unique" && test "`eval $cmd`" = "" ; then
73858    eval "INSTALLHEADERS$unique=set"
73859
73860        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
73861
73862  fi
73863
73864    done
73865
73866
73867
73868  am_i_shared=$PHP_SPL_SHARED
73869  is_it_shared=$PHP_PCRE_SHARED
73870  is_it_enabled=$PHP_PCRE
73871  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
73872    as_fn_error $? "
73873You've configured extension spl to build statically, but it
73874depends on extension pcre, which you've configured to build shared.
73875You either need to build spl shared or build pcre statically for the
73876build to be successful.
73877" "$LINENO" 5
73878  fi
73879  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
73880    as_fn_error $? "
73881You've configured extension spl, which depends on extension pcre,
73882but you've either not enabled pcre, or have disabled it.
73883" "$LINENO" 5
73884  fi
73885
73886
73887  am_i_shared=$PHP_SPL_SHARED
73888  is_it_shared=$PHP_STANDARD_SHARED
73889  is_it_enabled=$PHP_STANDARD
73890  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
73891    as_fn_error $? "
73892You've configured extension spl to build statically, but it
73893depends on extension standard, which you've configured to build shared.
73894You either need to build spl shared or build standard statically for the
73895build to be successful.
73896" "$LINENO" 5
73897  fi
73898  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
73899    as_fn_error $? "
73900You've configured extension spl, which depends on extension standard,
73901but you've either not enabled standard, or have disabled it.
73902" "$LINENO" 5
73903  fi
73904
73905
73906  am_i_shared=$PHP_SPL_SHARED
73907  is_it_shared=$PHP_JSON_SHARED
73908  is_it_enabled=$PHP_JSON
73909  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
73910    as_fn_error $? "
73911You've configured extension spl to build statically, but it
73912depends on extension json, which you've configured to build shared.
73913You either need to build spl shared or build json statically for the
73914build to be successful.
73915" "$LINENO" 5
73916  fi
73917  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
73918    as_fn_error $? "
73919You've configured extension spl, which depends on extension json,
73920but you've either not enabled json, or have disabled it.
73921" "$LINENO" 5
73922  fi
73923
73924
73925
73926
73927
73928{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether flush should be called explicitly after a buffered io" >&5
73929printf %s "checking whether flush should be called explicitly after a buffered io... " >&6; }
73930if test ${ac_cv_flush_io+y}
73931then :
73932  printf %s "(cached) " >&6
73933else $as_nop
73934
73935if test "$cross_compiling" = yes
73936then :
73937
73938  ac_cv_flush_io=no
73939
73940else $as_nop
73941  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73942/* end confdefs.h.  */
73943
73944#include <stdio.h>
73945#include <stdlib.h>
73946#ifdef HAVE_UNISTD_H
73947#include <unistd.h>
73948#endif
73949#include <string.h>
73950
73951int main(int argc, char **argv)
73952{
73953	char *filename = tmpnam(NULL);
73954	char buffer[64];
73955	int result = 0;
73956
73957	FILE *fp = fopen(filename, "wb");
73958	if (NULL == fp)
73959		return 0;
73960	fputs("line 1\n", fp);
73961	fputs("line 2\n", fp);
73962	fclose(fp);
73963
73964	fp = fopen(filename, "rb+");
73965	if (NULL == fp)
73966		return 0;
73967	fgets(buffer, sizeof(buffer), fp);
73968	fputs("line 3\n", fp);
73969	rewind(fp);
73970	fgets(buffer, sizeof(buffer), fp);
73971	if (0 != strcmp(buffer, "line 1\n"))
73972		result = 1;
73973	fgets(buffer, sizeof(buffer), fp);
73974	if (0 != strcmp(buffer, "line 3\n"))
73975		result = 1;
73976	fclose(fp);
73977	unlink(filename);
73978
73979	exit(result);
73980}
73981
73982_ACEOF
73983if ac_fn_c_try_run "$LINENO"
73984then :
73985
73986  ac_cv_flush_io=no
73987
73988else $as_nop
73989
73990  ac_cv_flush_io=yes
73991
73992fi
73993rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
73994  conftest.$ac_objext conftest.beam conftest.$ac_ext
73995fi
73996
73997fi
73998{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_flush_io" >&5
73999printf "%s\n" "$ac_cv_flush_io" >&6; }
74000if test "$ac_cv_flush_io" = "yes"; then
74001
74002printf "%s\n" "#define HAVE_FLUSHIO 1" >>confdefs.h
74003
74004fi
74005
74006
74007  unset ac_cv_func_crypt
74008  unset ac_cv_func___crypt
74009  unset found
74010
74011  ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
74012if test "x$ac_cv_func_crypt" = xyes
74013then :
74014  found=yes
74015else $as_nop
74016   ac_fn_c_check_func "$LINENO" "__crypt" "ac_cv_func___crypt"
74017if test "x$ac_cv_func___crypt" = xyes
74018then :
74019  found=yes
74020else $as_nop
74021  found=no
74022fi
74023
74024fi
74025
74026
74027  case $found in
74028  yes)
74029
74030printf "%s\n" "#define HAVE_CRYPT 1" >>confdefs.h
74031
74032    ac_cv_func_crypt=yes
74033  ;;
74034
74035    *)
74036
74037  unset ac_cv_lib_crypt_crypt
74038  unset ac_cv_lib_crypt___crypt
74039  unset found
74040  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5
74041printf %s "checking for crypt in -lcrypt... " >&6; }
74042if test ${ac_cv_lib_crypt_crypt+y}
74043then :
74044  printf %s "(cached) " >&6
74045else $as_nop
74046  ac_check_lib_save_LIBS=$LIBS
74047LIBS="-lcrypt  $LIBS"
74048cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74049/* end confdefs.h.  */
74050
74051/* Override any GCC internal prototype to avoid an error.
74052   Use char because int might match the return type of a GCC
74053   builtin and then its argument prototype would still apply.  */
74054char crypt ();
74055int
74056main (void)
74057{
74058return crypt ();
74059  ;
74060  return 0;
74061}
74062_ACEOF
74063if ac_fn_c_try_link "$LINENO"
74064then :
74065  ac_cv_lib_crypt_crypt=yes
74066else $as_nop
74067  ac_cv_lib_crypt_crypt=no
74068fi
74069rm -f core conftest.err conftest.$ac_objext conftest.beam \
74070    conftest$ac_exeext conftest.$ac_ext
74071LIBS=$ac_check_lib_save_LIBS
74072fi
74073{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
74074printf "%s\n" "$ac_cv_lib_crypt_crypt" >&6; }
74075if test "x$ac_cv_lib_crypt_crypt" = xyes
74076then :
74077  found=yes
74078else $as_nop
74079
74080    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __crypt in -lcrypt" >&5
74081printf %s "checking for __crypt in -lcrypt... " >&6; }
74082if test ${ac_cv_lib_crypt___crypt+y}
74083then :
74084  printf %s "(cached) " >&6
74085else $as_nop
74086  ac_check_lib_save_LIBS=$LIBS
74087LIBS="-lcrypt  $LIBS"
74088cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74089/* end confdefs.h.  */
74090
74091/* Override any GCC internal prototype to avoid an error.
74092   Use char because int might match the return type of a GCC
74093   builtin and then its argument prototype would still apply.  */
74094char __crypt ();
74095int
74096main (void)
74097{
74098return __crypt ();
74099  ;
74100  return 0;
74101}
74102_ACEOF
74103if ac_fn_c_try_link "$LINENO"
74104then :
74105  ac_cv_lib_crypt___crypt=yes
74106else $as_nop
74107  ac_cv_lib_crypt___crypt=no
74108fi
74109rm -f core conftest.err conftest.$ac_objext conftest.beam \
74110    conftest$ac_exeext conftest.$ac_ext
74111LIBS=$ac_check_lib_save_LIBS
74112fi
74113{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt___crypt" >&5
74114printf "%s\n" "$ac_cv_lib_crypt___crypt" >&6; }
74115if test "x$ac_cv_lib_crypt___crypt" = xyes
74116then :
74117  found=yes
74118else $as_nop
74119  found=no
74120fi
74121
74122
74123fi
74124
74125
74126  if test "$found" = "yes"; then
74127    ac_libs=$LIBS
74128    LIBS="$LIBS -lcrypt"
74129    if test "$cross_compiling" = yes
74130then :
74131
74132            found=yes
74133
74134else $as_nop
74135  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74136/* end confdefs.h.  */
74137int main() { return (0); }
74138_ACEOF
74139if ac_fn_c_try_run "$LINENO"
74140then :
74141  found=yes
74142else $as_nop
74143  found=no
74144fi
74145rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74146  conftest.$ac_objext conftest.beam conftest.$ac_ext
74147fi
74148
74149    LIBS=$ac_libs
74150  fi
74151
74152  if test "$found" = "yes"; then
74153
74154
74155  case crypt in
74156  c|c_r) ;;
74157  *)
74158      LIBS="-lcrypt $LIBS"
74159   ;;
74160  esac
74161
74162
74163
74164printf "%s\n" "#define HAVE_CRYPT 1" >>confdefs.h
74165
74166
74167printf "%s\n" "#define HAVE_LIBCRYPT 1" >>confdefs.h
74168
74169    ac_cv_func_crypt=yes
74170  else
74171
74172  :
74173
74174  fi
74175
74176 ;;
74177
74178  esac
74179
74180
74181  unset ac_cv_func_crypt_r
74182  unset ac_cv_func___crypt_r
74183  unset found
74184
74185  ac_fn_c_check_func "$LINENO" "crypt_r" "ac_cv_func_crypt_r"
74186if test "x$ac_cv_func_crypt_r" = xyes
74187then :
74188  found=yes
74189else $as_nop
74190   ac_fn_c_check_func "$LINENO" "__crypt_r" "ac_cv_func___crypt_r"
74191if test "x$ac_cv_func___crypt_r" = xyes
74192then :
74193  found=yes
74194else $as_nop
74195  found=no
74196fi
74197
74198fi
74199
74200
74201  case $found in
74202  yes)
74203
74204printf "%s\n" "#define HAVE_CRYPT_R 1" >>confdefs.h
74205
74206    ac_cv_func_crypt_r=yes
74207  ;;
74208
74209    *)
74210
74211  unset ac_cv_lib_crypt_crypt_r
74212  unset ac_cv_lib_crypt___crypt_r
74213  unset found
74214  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for crypt_r in -lcrypt" >&5
74215printf %s "checking for crypt_r in -lcrypt... " >&6; }
74216if test ${ac_cv_lib_crypt_crypt_r+y}
74217then :
74218  printf %s "(cached) " >&6
74219else $as_nop
74220  ac_check_lib_save_LIBS=$LIBS
74221LIBS="-lcrypt  $LIBS"
74222cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74223/* end confdefs.h.  */
74224
74225/* Override any GCC internal prototype to avoid an error.
74226   Use char because int might match the return type of a GCC
74227   builtin and then its argument prototype would still apply.  */
74228char crypt_r ();
74229int
74230main (void)
74231{
74232return crypt_r ();
74233  ;
74234  return 0;
74235}
74236_ACEOF
74237if ac_fn_c_try_link "$LINENO"
74238then :
74239  ac_cv_lib_crypt_crypt_r=yes
74240else $as_nop
74241  ac_cv_lib_crypt_crypt_r=no
74242fi
74243rm -f core conftest.err conftest.$ac_objext conftest.beam \
74244    conftest$ac_exeext conftest.$ac_ext
74245LIBS=$ac_check_lib_save_LIBS
74246fi
74247{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt_r" >&5
74248printf "%s\n" "$ac_cv_lib_crypt_crypt_r" >&6; }
74249if test "x$ac_cv_lib_crypt_crypt_r" = xyes
74250then :
74251  found=yes
74252else $as_nop
74253
74254    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __crypt_r in -lcrypt" >&5
74255printf %s "checking for __crypt_r in -lcrypt... " >&6; }
74256if test ${ac_cv_lib_crypt___crypt_r+y}
74257then :
74258  printf %s "(cached) " >&6
74259else $as_nop
74260  ac_check_lib_save_LIBS=$LIBS
74261LIBS="-lcrypt  $LIBS"
74262cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74263/* end confdefs.h.  */
74264
74265/* Override any GCC internal prototype to avoid an error.
74266   Use char because int might match the return type of a GCC
74267   builtin and then its argument prototype would still apply.  */
74268char __crypt_r ();
74269int
74270main (void)
74271{
74272return __crypt_r ();
74273  ;
74274  return 0;
74275}
74276_ACEOF
74277if ac_fn_c_try_link "$LINENO"
74278then :
74279  ac_cv_lib_crypt___crypt_r=yes
74280else $as_nop
74281  ac_cv_lib_crypt___crypt_r=no
74282fi
74283rm -f core conftest.err conftest.$ac_objext conftest.beam \
74284    conftest$ac_exeext conftest.$ac_ext
74285LIBS=$ac_check_lib_save_LIBS
74286fi
74287{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt___crypt_r" >&5
74288printf "%s\n" "$ac_cv_lib_crypt___crypt_r" >&6; }
74289if test "x$ac_cv_lib_crypt___crypt_r" = xyes
74290then :
74291  found=yes
74292else $as_nop
74293  found=no
74294fi
74295
74296
74297fi
74298
74299
74300  if test "$found" = "yes"; then
74301    ac_libs=$LIBS
74302    LIBS="$LIBS -lcrypt"
74303    if test "$cross_compiling" = yes
74304then :
74305
74306            found=yes
74307
74308else $as_nop
74309  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74310/* end confdefs.h.  */
74311int main() { return (0); }
74312_ACEOF
74313if ac_fn_c_try_run "$LINENO"
74314then :
74315  found=yes
74316else $as_nop
74317  found=no
74318fi
74319rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74320  conftest.$ac_objext conftest.beam conftest.$ac_ext
74321fi
74322
74323    LIBS=$ac_libs
74324  fi
74325
74326  if test "$found" = "yes"; then
74327
74328
74329  case crypt in
74330  c|c_r) ;;
74331  *)
74332      LIBS="-lcrypt $LIBS"
74333   ;;
74334  esac
74335
74336
74337
74338printf "%s\n" "#define HAVE_CRYPT_R 1" >>confdefs.h
74339
74340
74341printf "%s\n" "#define HAVE_LIBCRYPT 1" >>confdefs.h
74342
74343    ac_cv_func_crypt_r=yes
74344  else
74345
74346  :
74347
74348  fi
74349
74350 ;;
74351
74352  esac
74353
74354if test "$ac_cv_func_crypt_r" = "yes"; then
74355
74356  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which data struct is used by crypt_r" >&5
74357printf %s "checking which data struct is used by crypt_r... " >&6; }
74358if test ${php_cv_crypt_r_style+y}
74359then :
74360  printf %s "(cached) " >&6
74361else $as_nop
74362
74363    php_cv_crypt_r_style=none
74364    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74365/* end confdefs.h.  */
74366
74367#define _REENTRANT 1
74368#include <crypt.h>
74369
74370int
74371main (void)
74372{
74373
74374CRYPTD buffer;
74375crypt_r("passwd", "hash", &buffer);
74376
74377  ;
74378  return 0;
74379}
74380_ACEOF
74381if ac_fn_c_try_compile "$LINENO"
74382then :
74383  php_cv_crypt_r_style=cryptd
74384fi
74385rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
74386
74387    if test "$php_cv_crypt_r_style" = "none"; then
74388      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74389/* end confdefs.h.  */
74390
74391#define _REENTRANT 1
74392#include <crypt.h>
74393
74394int
74395main (void)
74396{
74397
74398struct crypt_data buffer;
74399crypt_r("passwd", "hash", &buffer);
74400
74401  ;
74402  return 0;
74403}
74404_ACEOF
74405if ac_fn_c_try_compile "$LINENO"
74406then :
74407  php_cv_crypt_r_style=struct_crypt_data
74408fi
74409rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
74410    fi
74411
74412    if test "$php_cv_crypt_r_style" = "none"; then
74413      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74414/* end confdefs.h.  */
74415
74416#define _REENTRANT 1
74417#define _GNU_SOURCE
74418#include <crypt.h>
74419
74420int
74421main (void)
74422{
74423
74424struct crypt_data buffer;
74425crypt_r("passwd", "hash", &buffer);
74426
74427  ;
74428  return 0;
74429}
74430_ACEOF
74431if ac_fn_c_try_compile "$LINENO"
74432then :
74433  php_cv_crypt_r_style=struct_crypt_data_gnu_source
74434fi
74435rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
74436    fi
74437
74438    if test "$php_cv_crypt_r_style" = "none"; then
74439      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74440/* end confdefs.h.  */
74441
74442#include <stdlib.h>
74443#include <unistd.h>
74444
74445int
74446main (void)
74447{
74448
74449struct crypt_data buffer;
74450crypt_r("passwd", "hash", &buffer);
74451
74452  ;
74453  return 0;
74454}
74455_ACEOF
74456if ac_fn_c_try_compile "$LINENO"
74457then :
74458  php_cv_crypt_r_style=struct_crypt_data
74459fi
74460rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
74461    fi
74462
74463fi
74464{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_crypt_r_style" >&5
74465printf "%s\n" "$php_cv_crypt_r_style" >&6; }
74466
74467  if test "$php_cv_crypt_r_style" = "cryptd"; then
74468
74469printf "%s\n" "#define CRYPT_R_CRYPTD 1" >>confdefs.h
74470
74471  fi
74472  if test "$php_cv_crypt_r_style" = "struct_crypt_data" -o "$php_cv_crypt_r_style" = "struct_crypt_data_gnu_source"; then
74473
74474printf "%s\n" "#define CRYPT_R_STRUCT_CRYPT_DATA 1" >>confdefs.h
74475
74476  fi
74477  if test "$php_cv_crypt_r_style" = "struct_crypt_data_gnu_source"; then
74478
74479printf "%s\n" "#define CRYPT_R_GNU_SOURCE 1" >>confdefs.h
74480
74481  fi
74482  if test "$php_cv_crypt_r_style" = "none"; then
74483    as_fn_error $? "Unable to detect data struct used by crypt_r" "$LINENO" 5
74484  fi
74485
74486fi
74487
74488{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for standard DES crypt" >&5
74489printf %s "checking for standard DES crypt... " >&6; }
74490if test ${ac_cv_crypt_des+y}
74491then :
74492  printf %s "(cached) " >&6
74493else $as_nop
74494
74495  if test "$cross_compiling" = yes
74496then :
74497
74498  ac_cv_crypt_des=yes
74499
74500else $as_nop
74501  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74502/* end confdefs.h.  */
74503
74504#include <string.h>
74505
74506#if HAVE_UNISTD_H
74507#include <unistd.h>
74508#endif
74509
74510#if HAVE_CRYPT_H
74511#include <crypt.h>
74512#endif
74513
74514#include <stdlib.h>
74515#include <string.h>
74516
74517int main() {
74518#if HAVE_CRYPT
74519	char *encrypted = crypt("rasmuslerdorf","rl");
74520	return !encrypted || strcmp(encrypted,"rl.3StKT.4T8M");
74521#else
74522	return 1;
74523#endif
74524}
74525_ACEOF
74526if ac_fn_c_try_run "$LINENO"
74527then :
74528
74529  ac_cv_crypt_des=yes
74530
74531else $as_nop
74532
74533  ac_cv_crypt_des=no
74534
74535fi
74536rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74537  conftest.$ac_objext conftest.beam conftest.$ac_ext
74538fi
74539
74540fi
74541{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_des" >&5
74542printf "%s\n" "$ac_cv_crypt_des" >&6; }
74543
74544{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for extended DES crypt" >&5
74545printf %s "checking for extended DES crypt... " >&6; }
74546if test ${ac_cv_crypt_ext_des+y}
74547then :
74548  printf %s "(cached) " >&6
74549else $as_nop
74550
74551  if test "$cross_compiling" = yes
74552then :
74553
74554  ac_cv_crypt_ext_des=no
74555
74556else $as_nop
74557  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74558/* end confdefs.h.  */
74559
74560#include <string.h>
74561
74562#if HAVE_UNISTD_H
74563#include <unistd.h>
74564#endif
74565
74566#if HAVE_CRYPT_H
74567#include <crypt.h>
74568#endif
74569
74570#include <stdlib.h>
74571#include <string.h>
74572
74573int main() {
74574#if HAVE_CRYPT
74575	char *encrypted = crypt("rasmuslerdorf","_J9..rasm");
74576	return !encrypted || strcmp(encrypted,"_J9..rasmBYk8r9AiWNc");
74577#else
74578	return 1;
74579#endif
74580}
74581_ACEOF
74582if ac_fn_c_try_run "$LINENO"
74583then :
74584
74585  ac_cv_crypt_ext_des=yes
74586
74587else $as_nop
74588
74589  ac_cv_crypt_ext_des=no
74590
74591fi
74592rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74593  conftest.$ac_objext conftest.beam conftest.$ac_ext
74594fi
74595
74596fi
74597{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_ext_des" >&5
74598printf "%s\n" "$ac_cv_crypt_ext_des" >&6; }
74599
74600{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MD5 crypt" >&5
74601printf %s "checking for MD5 crypt... " >&6; }
74602if test ${ac_cv_crypt_md5+y}
74603then :
74604  printf %s "(cached) " >&6
74605else $as_nop
74606
74607if test "$cross_compiling" = yes
74608then :
74609
74610  ac_cv_crypt_md5=no
74611
74612else $as_nop
74613  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74614/* end confdefs.h.  */
74615
74616#include <string.h>
74617
74618#if HAVE_UNISTD_H
74619#include <unistd.h>
74620#endif
74621
74622#if HAVE_CRYPT_H
74623#include <crypt.h>
74624#endif
74625
74626#include <stdlib.h>
74627#include <string.h>
74628
74629int main() {
74630#if HAVE_CRYPT
74631	char salt[15], answer[40];
74632	char *encrypted;
74633
74634	salt[0]='$'; salt[1]='1'; salt[2]='$';
74635	salt[3]='r'; salt[4]='a'; salt[5]='s';
74636	salt[6]='m'; salt[7]='u'; salt[8]='s';
74637	salt[9]='l'; salt[10]='e'; salt[11]='$';
74638	salt[12]='\0';
74639	strcpy(answer,salt);
74640	strcat(answer,"rISCgZzpwk3UhDidwXvin0");
74641	encrypted = crypt("rasmuslerdorf",salt);
74642	return !encrypted || strcmp(encrypted,answer);
74643#else
74644	return 1;
74645#endif
74646}
74647_ACEOF
74648if ac_fn_c_try_run "$LINENO"
74649then :
74650
74651  ac_cv_crypt_md5=yes
74652
74653else $as_nop
74654
74655  ac_cv_crypt_md5=no
74656
74657fi
74658rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74659  conftest.$ac_objext conftest.beam conftest.$ac_ext
74660fi
74661
74662fi
74663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_md5" >&5
74664printf "%s\n" "$ac_cv_crypt_md5" >&6; }
74665
74666{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Blowfish crypt" >&5
74667printf %s "checking for Blowfish crypt... " >&6; }
74668if test ${ac_cv_crypt_blowfish+y}
74669then :
74670  printf %s "(cached) " >&6
74671else $as_nop
74672
74673if test "$cross_compiling" = yes
74674then :
74675
74676  ac_cv_crypt_blowfish=no
74677
74678else $as_nop
74679  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74680/* end confdefs.h.  */
74681
74682#include <string.h>
74683
74684#if HAVE_UNISTD_H
74685#include <unistd.h>
74686#endif
74687
74688#if HAVE_CRYPT_H
74689#include <crypt.h>
74690#endif
74691
74692#include <stdlib.h>
74693#include <string.h>
74694
74695int main() {
74696#if HAVE_CRYPT
74697	char salt[30], answer[70];
74698	char *encrypted;
74699
74700	salt[0]='$'; salt[1]='2'; salt[2]='a'; salt[3]='$'; salt[4]='0'; salt[5]='7'; salt[6]='$'; salt[7]='\0';
74701	strcat(salt,"rasmuslerd............");
74702	strcpy(answer,salt);
74703	strcpy(&answer[29],"nIdrcHdxcUxWomQX9j6kvERCFjTg7Ra");
74704	encrypted = crypt("rasmuslerdorf",salt);
74705	return !encrypted || strcmp(encrypted,answer);
74706#else
74707	return 1;
74708#endif
74709}
74710_ACEOF
74711if ac_fn_c_try_run "$LINENO"
74712then :
74713
74714  ac_cv_crypt_blowfish=yes
74715
74716else $as_nop
74717
74718  ac_cv_crypt_blowfish=no
74719
74720fi
74721rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74722  conftest.$ac_objext conftest.beam conftest.$ac_ext
74723fi
74724
74725fi
74726{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_blowfish" >&5
74727printf "%s\n" "$ac_cv_crypt_blowfish" >&6; }
74728
74729{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SHA512 crypt" >&5
74730printf %s "checking for SHA512 crypt... " >&6; }
74731if test ${ac_cv_crypt_sha512+y}
74732then :
74733  printf %s "(cached) " >&6
74734else $as_nop
74735
74736if test "$cross_compiling" = yes
74737then :
74738
74739  ac_cv_crypt_sha512=no
74740
74741else $as_nop
74742  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74743/* end confdefs.h.  */
74744
74745#include <string.h>
74746
74747#if HAVE_UNISTD_H
74748#include <unistd.h>
74749#endif
74750
74751#if HAVE_CRYPT_H
74752#include <crypt.h>
74753#endif
74754
74755#include <stdlib.h>
74756#include <string.h>
74757
74758int main() {
74759#if HAVE_CRYPT
74760	char salt[21], answer[21+86];
74761	char *encrypted;
74762
74763	strcpy(salt,"\$6\$rasmuslerdorf\$");
74764	strcpy(answer, salt);
74765	strcat(answer, "EeHCRjm0bljalWuALHSTs1NB9ipEiLEXLhYeXdOpx22gmlmVejnVXFhd84cEKbYxCo.XuUTrW.RLraeEnsvWs/");
74766	encrypted = crypt("rasmuslerdorf",salt);
74767	return !encrypted || strcmp(encrypted,answer);
74768#else
74769	return 1;
74770#endif
74771}
74772_ACEOF
74773if ac_fn_c_try_run "$LINENO"
74774then :
74775
74776  ac_cv_crypt_sha512=yes
74777
74778else $as_nop
74779
74780  ac_cv_crypt_sha512=no
74781
74782fi
74783rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74784  conftest.$ac_objext conftest.beam conftest.$ac_ext
74785fi
74786
74787fi
74788{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_sha512" >&5
74789printf "%s\n" "$ac_cv_crypt_sha512" >&6; }
74790
74791{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SHA256 crypt" >&5
74792printf %s "checking for SHA256 crypt... " >&6; }
74793if test ${ac_cv_crypt_sha256+y}
74794then :
74795  printf %s "(cached) " >&6
74796else $as_nop
74797
74798if test "$cross_compiling" = yes
74799then :
74800
74801  ac_cv_crypt_sha256=no
74802
74803else $as_nop
74804  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74805/* end confdefs.h.  */
74806
74807#include <string.h>
74808
74809#if HAVE_UNISTD_H
74810#include <unistd.h>
74811#endif
74812
74813#if HAVE_CRYPT_H
74814#include <crypt.h>
74815#endif
74816
74817#include <stdlib.h>
74818#include <string.h>
74819
74820int main() {
74821#if HAVE_CRYPT
74822	char salt[21], answer[21+43];
74823	char *encrypted;
74824
74825	strcpy(salt,"\$5\$rasmuslerdorf\$");
74826	strcpy(answer, salt);
74827	strcat(answer, "cFAm2puLCujQ9t.0CxiFIIvFi4JyQx5UncCt/xRIX23");
74828	encrypted = crypt("rasmuslerdorf",salt);
74829	return !encrypted || strcmp(encrypted,answer);
74830#else
74831	return 1;
74832#endif
74833}
74834_ACEOF
74835if ac_fn_c_try_run "$LINENO"
74836then :
74837
74838  ac_cv_crypt_sha256=yes
74839
74840else $as_nop
74841
74842  ac_cv_crypt_sha256=no
74843
74844fi
74845rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
74846  conftest.$ac_objext conftest.beam conftest.$ac_ext
74847fi
74848
74849fi
74850{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_crypt_sha256" >&5
74851printf "%s\n" "$ac_cv_crypt_sha256" >&6; }
74852
74853
74854
74855php_with_external_libcrypt=no
74856
74857{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for external libcrypt or libxcrypt" >&5
74858printf %s "checking for external libcrypt or libxcrypt... " >&6; }
74859
74860# Check whether --with-external-libcrypt was given.
74861if test ${with_external_libcrypt+y}
74862then :
74863  withval=$with_external_libcrypt; PHP_EXTERNAL_LIBCRYPT=$withval
74864else $as_nop
74865
74866  PHP_EXTERNAL_LIBCRYPT=no
74867
74868
74869fi
74870
74871
74872ext_output=$PHP_EXTERNAL_LIBCRYPT
74873{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
74874printf "%s\n" "$ext_output" >&6; }
74875
74876
74877
74878
74879if test "$ac_cv_crypt_blowfish" = "no" || test "$ac_cv_crypt_des" = "no" || test "$ac_cv_crypt_ext_des" = "no" || test "$ac_cv_crypt_md5" = "no" || test "$ac_cv_crypt_sha512" = "no" || test "$ac_cv_crypt_sha256" = "no" || test "$ac_cv_func_crypt_r" != "yes" || test "$PHP_EXTERNAL_LIBCRYPT" = "no"; then
74880  if test "$PHP_EXTERNAL_LIBCRYPT" = "no"; then
74881
74882printf "%s\n" "#define PHP_USE_PHP_CRYPT_R 1" >>confdefs.h
74883
74884
74885
74886
74887  case ext/standard in
74888  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
74889  /*) ac_srcdir=`echo "ext/standard"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
74890  *) ac_srcdir="$abs_srcdir/ext/standard/"; ac_bdir="ext/standard/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
74891  esac
74892
74893
74894
74895  b_c_pre=$php_c_pre
74896  b_cxx_pre=$php_cxx_pre
74897  b_c_meta=$php_c_meta
74898  b_cxx_meta=$php_cxx_meta
74899  b_c_post=$php_c_post
74900  b_cxx_post=$php_cxx_post
74901  b_lo=$php_lo
74902
74903
74904  old_IFS=$IFS
74905  for ac_src in crypt_freesec.c crypt_blowfish.c crypt_sha512.c crypt_sha256.c php_crypt_r.c; do
74906
74907      IFS=.
74908      set $ac_src
74909      ac_obj=$1
74910      IFS=$old_IFS
74911
74912      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
74913
74914      case $ac_src in
74915        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
74916        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
74917        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
74918        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
74919      esac
74920
74921      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
74922
74923    cat >>Makefile.objects<<EOF
74924-include $ac_bdir$ac_obj.dep
74925$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
74926	$ac_comp
74927EOF
74928  done
74929
74930
74931   else
74932    as_fn_error $? "Cannot use external libcrypt as some algo are missing" "$LINENO" 5
74933   fi
74934else
74935
74936printf "%s\n" "#define PHP_USE_PHP_CRYPT_R 0" >>confdefs.h
74937
74938fi
74939
74940{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports aligned attribute" >&5
74941printf %s "checking whether the compiler supports aligned attribute... " >&6; }
74942if test ${ac_cv_attribute_aligned+y}
74943then :
74944  printf %s "(cached) " >&6
74945else $as_nop
74946
74947cat confdefs.h - <<_ACEOF >conftest.$ac_ext
74948/* end confdefs.h.  */
74949
74950
74951int
74952main (void)
74953{
74954
74955  unsigned char test[32] __attribute__ ((__aligned__ (__alignof__ (int))));
74956
74957  ;
74958  return 0;
74959}
74960_ACEOF
74961if ac_fn_c_try_compile "$LINENO"
74962then :
74963
74964  ac_cv_attribute_aligned=yes
74965
74966else $as_nop
74967
74968  ac_cv_attribute_aligned=no
74969
74970fi
74971rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
74972fi
74973{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_attribute_aligned" >&5
74974printf "%s\n" "$ac_cv_attribute_aligned" >&6; }
74975if test "$ac_cv_attribute_aligned" = "yes"; then
74976
74977printf "%s\n" "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h
74978
74979fi
74980
74981if test "$cross_compiling" = yes ; then
74982  case $host_alias in
74983    *linux*)
74984
74985printf "%s\n" "#define HAVE_FNMATCH 1" >>confdefs.h
74986
74987      ;;
74988  esac
74989else
74990  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working POSIX fnmatch" >&5
74991printf %s "checking for working POSIX fnmatch... " >&6; }
74992if test ${ac_cv_func_fnmatch_works+y}
74993then :
74994  printf %s "(cached) " >&6
74995else $as_nop
74996  # Some versions of Solaris, SCO, and the GNU C Library
74997   # have a broken or incompatible fnmatch.
74998   # So we run a test program.  If we are cross-compiling, take no chance.
74999   # Thanks to John Oleynick, Franc,ois Pinard, and Paul Eggert for this test.
75000   if test "$cross_compiling" = yes
75001then :
75002  ac_cv_func_fnmatch_works=cross
75003else $as_nop
75004  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75005/* end confdefs.h.  */
75006#include <fnmatch.h>
75007#	   define y(a, b, c) (fnmatch (a, b, c) == 0)
75008#	   define n(a, b, c) (fnmatch (a, b, c) == FNM_NOMATCH)
75009
75010int
75011main (void)
75012{
75013return
75014	   (!(y ("a*", "abc", 0)
75015	      && n ("d*/*1", "d/s/1", FNM_PATHNAME)
75016	      && y ("a\\\\bc", "abc", 0)
75017	      && n ("a\\\\bc", "abc", FNM_NOESCAPE)
75018	      && y ("*x", ".x", 0)
75019	      && n ("*x", ".x", FNM_PERIOD)
75020	      && 1));
75021  ;
75022  return 0;
75023}
75024_ACEOF
75025if ac_fn_c_try_run "$LINENO"
75026then :
75027  ac_cv_func_fnmatch_works=yes
75028else $as_nop
75029  ac_cv_func_fnmatch_works=no
75030fi
75031rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75032  conftest.$ac_objext conftest.beam conftest.$ac_ext
75033fi
75034
75035fi
75036{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fnmatch_works" >&5
75037printf "%s\n" "$ac_cv_func_fnmatch_works" >&6; }
75038if test $ac_cv_func_fnmatch_works = yes
75039then :
75040
75041printf "%s\n" "#define HAVE_FNMATCH 1" >>confdefs.h
75042
75043fi
75044
75045
75046fi
75047
75048
75049  for ac_func in fork CreateProcess
75050do :
75051  as_ac_var=`printf "%s\n" "ac_cv_func_$ac_func" | $as_tr_sh`
75052ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
75053if eval test \"x\$"$as_ac_var"\" = x"yes"
75054then :
75055  cat >>confdefs.h <<_ACEOF
75056#define `printf "%s\n" "HAVE_$ac_func" | $as_tr_cpp` 1
75057_ACEOF
75058
75059  php_can_support_proc_open=yes
75060  break
75061
75062else $as_nop
75063
75064  php_can_support_proc_open=no
75065
75066fi
75067
75068done
75069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your OS can spawn processes with inherited handles" >&5
75070printf %s "checking if your OS can spawn processes with inherited handles... " >&6; }
75071if test "$php_can_support_proc_open" = "yes"; then
75072  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
75073printf "%s\n" "yes" >&6; }
75074
75075printf "%s\n" "#define PHP_CAN_SUPPORT_PROC_OPEN 1" >>confdefs.h
75076
75077else
75078  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
75079printf "%s\n" "no" >&6; }
75080fi
75081
75082PHP_ENABLE_CHROOT_FUNC=no
75083case "$PHP_SAPI" in
75084  embed)
75085    PHP_ENABLE_CHROOT_FUNC=yes
75086  ;;
75087
75088  none)
75089    for PROG in $PHP_BINARIES; do
75090      case "$PROG" in
75091        cgi|cli|phpdbg)
75092          PHP_ENABLE_CHROOT_FUNC=yes
75093        ;;
75094
75095        *)
75096          PHP_ENABLE_CHROOT_FUNC=no
75097          break
75098        ;;
75099      esac
75100   done
75101  ;;
75102esac
75103
75104if test "$PHP_ENABLE_CHROOT_FUNC" = "yes"; then
75105
75106printf "%s\n" "#define ENABLE_CHROOT_FUNC 1" >>confdefs.h
75107
75108fi
75109
75110
75111  unset ac_cv_func_res_nsearch
75112  unset ac_cv_func___res_nsearch
75113  unset found
75114
75115  ac_fn_c_check_func "$LINENO" "res_nsearch" "ac_cv_func_res_nsearch"
75116if test "x$ac_cv_func_res_nsearch" = xyes
75117then :
75118  found=yes
75119else $as_nop
75120   ac_fn_c_check_func "$LINENO" "__res_nsearch" "ac_cv_func___res_nsearch"
75121if test "x$ac_cv_func___res_nsearch" = xyes
75122then :
75123  found=yes
75124else $as_nop
75125  found=no
75126fi
75127
75128fi
75129
75130
75131  case $found in
75132  yes)
75133
75134printf "%s\n" "#define HAVE_RES_NSEARCH 1" >>confdefs.h
75135
75136    ac_cv_func_res_nsearch=yes
75137  ;;
75138
75139    *)
75140
75141  unset ac_cv_lib_resolv_res_nsearch
75142  unset ac_cv_lib_resolv___res_nsearch
75143  unset found
75144  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_nsearch in -lresolv" >&5
75145printf %s "checking for res_nsearch in -lresolv... " >&6; }
75146if test ${ac_cv_lib_resolv_res_nsearch+y}
75147then :
75148  printf %s "(cached) " >&6
75149else $as_nop
75150  ac_check_lib_save_LIBS=$LIBS
75151LIBS="-lresolv  $LIBS"
75152cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75153/* end confdefs.h.  */
75154
75155/* Override any GCC internal prototype to avoid an error.
75156   Use char because int might match the return type of a GCC
75157   builtin and then its argument prototype would still apply.  */
75158char res_nsearch ();
75159int
75160main (void)
75161{
75162return res_nsearch ();
75163  ;
75164  return 0;
75165}
75166_ACEOF
75167if ac_fn_c_try_link "$LINENO"
75168then :
75169  ac_cv_lib_resolv_res_nsearch=yes
75170else $as_nop
75171  ac_cv_lib_resolv_res_nsearch=no
75172fi
75173rm -f core conftest.err conftest.$ac_objext conftest.beam \
75174    conftest$ac_exeext conftest.$ac_ext
75175LIBS=$ac_check_lib_save_LIBS
75176fi
75177{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_nsearch" >&5
75178printf "%s\n" "$ac_cv_lib_resolv_res_nsearch" >&6; }
75179if test "x$ac_cv_lib_resolv_res_nsearch" = xyes
75180then :
75181  found=yes
75182else $as_nop
75183
75184    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_nsearch in -lresolv" >&5
75185printf %s "checking for __res_nsearch in -lresolv... " >&6; }
75186if test ${ac_cv_lib_resolv___res_nsearch+y}
75187then :
75188  printf %s "(cached) " >&6
75189else $as_nop
75190  ac_check_lib_save_LIBS=$LIBS
75191LIBS="-lresolv  $LIBS"
75192cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75193/* end confdefs.h.  */
75194
75195/* Override any GCC internal prototype to avoid an error.
75196   Use char because int might match the return type of a GCC
75197   builtin and then its argument prototype would still apply.  */
75198char __res_nsearch ();
75199int
75200main (void)
75201{
75202return __res_nsearch ();
75203  ;
75204  return 0;
75205}
75206_ACEOF
75207if ac_fn_c_try_link "$LINENO"
75208then :
75209  ac_cv_lib_resolv___res_nsearch=yes
75210else $as_nop
75211  ac_cv_lib_resolv___res_nsearch=no
75212fi
75213rm -f core conftest.err conftest.$ac_objext conftest.beam \
75214    conftest$ac_exeext conftest.$ac_ext
75215LIBS=$ac_check_lib_save_LIBS
75216fi
75217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_nsearch" >&5
75218printf "%s\n" "$ac_cv_lib_resolv___res_nsearch" >&6; }
75219if test "x$ac_cv_lib_resolv___res_nsearch" = xyes
75220then :
75221  found=yes
75222else $as_nop
75223  found=no
75224fi
75225
75226
75227fi
75228
75229
75230  if test "$found" = "yes"; then
75231    ac_libs=$LIBS
75232    LIBS="$LIBS -lresolv"
75233    if test "$cross_compiling" = yes
75234then :
75235
75236            found=yes
75237
75238else $as_nop
75239  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75240/* end confdefs.h.  */
75241int main() { return (0); }
75242_ACEOF
75243if ac_fn_c_try_run "$LINENO"
75244then :
75245  found=yes
75246else $as_nop
75247  found=no
75248fi
75249rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75250  conftest.$ac_objext conftest.beam conftest.$ac_ext
75251fi
75252
75253    LIBS=$ac_libs
75254  fi
75255
75256  if test "$found" = "yes"; then
75257
75258
75259  case resolv in
75260  c|c_r) ;;
75261  *)
75262      LIBS="-lresolv $LIBS"
75263   ;;
75264  esac
75265
75266
75267
75268printf "%s\n" "#define HAVE_RES_NSEARCH 1" >>confdefs.h
75269
75270
75271printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
75272
75273    ac_cv_func_res_nsearch=yes
75274  else
75275
75276
75277  unset ac_cv_lib_bind_res_nsearch
75278  unset ac_cv_lib_bind___res_nsearch
75279  unset found
75280  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_nsearch in -lbind" >&5
75281printf %s "checking for res_nsearch in -lbind... " >&6; }
75282if test ${ac_cv_lib_bind_res_nsearch+y}
75283then :
75284  printf %s "(cached) " >&6
75285else $as_nop
75286  ac_check_lib_save_LIBS=$LIBS
75287LIBS="-lbind  $LIBS"
75288cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75289/* end confdefs.h.  */
75290
75291/* Override any GCC internal prototype to avoid an error.
75292   Use char because int might match the return type of a GCC
75293   builtin and then its argument prototype would still apply.  */
75294char res_nsearch ();
75295int
75296main (void)
75297{
75298return res_nsearch ();
75299  ;
75300  return 0;
75301}
75302_ACEOF
75303if ac_fn_c_try_link "$LINENO"
75304then :
75305  ac_cv_lib_bind_res_nsearch=yes
75306else $as_nop
75307  ac_cv_lib_bind_res_nsearch=no
75308fi
75309rm -f core conftest.err conftest.$ac_objext conftest.beam \
75310    conftest$ac_exeext conftest.$ac_ext
75311LIBS=$ac_check_lib_save_LIBS
75312fi
75313{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_res_nsearch" >&5
75314printf "%s\n" "$ac_cv_lib_bind_res_nsearch" >&6; }
75315if test "x$ac_cv_lib_bind_res_nsearch" = xyes
75316then :
75317  found=yes
75318else $as_nop
75319
75320    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_nsearch in -lbind" >&5
75321printf %s "checking for __res_nsearch in -lbind... " >&6; }
75322if test ${ac_cv_lib_bind___res_nsearch+y}
75323then :
75324  printf %s "(cached) " >&6
75325else $as_nop
75326  ac_check_lib_save_LIBS=$LIBS
75327LIBS="-lbind  $LIBS"
75328cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75329/* end confdefs.h.  */
75330
75331/* Override any GCC internal prototype to avoid an error.
75332   Use char because int might match the return type of a GCC
75333   builtin and then its argument prototype would still apply.  */
75334char __res_nsearch ();
75335int
75336main (void)
75337{
75338return __res_nsearch ();
75339  ;
75340  return 0;
75341}
75342_ACEOF
75343if ac_fn_c_try_link "$LINENO"
75344then :
75345  ac_cv_lib_bind___res_nsearch=yes
75346else $as_nop
75347  ac_cv_lib_bind___res_nsearch=no
75348fi
75349rm -f core conftest.err conftest.$ac_objext conftest.beam \
75350    conftest$ac_exeext conftest.$ac_ext
75351LIBS=$ac_check_lib_save_LIBS
75352fi
75353{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___res_nsearch" >&5
75354printf "%s\n" "$ac_cv_lib_bind___res_nsearch" >&6; }
75355if test "x$ac_cv_lib_bind___res_nsearch" = xyes
75356then :
75357  found=yes
75358else $as_nop
75359  found=no
75360fi
75361
75362
75363fi
75364
75365
75366  if test "$found" = "yes"; then
75367    ac_libs=$LIBS
75368    LIBS="$LIBS -lbind"
75369    if test "$cross_compiling" = yes
75370then :
75371
75372            found=yes
75373
75374else $as_nop
75375  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75376/* end confdefs.h.  */
75377int main() { return (0); }
75378_ACEOF
75379if ac_fn_c_try_run "$LINENO"
75380then :
75381  found=yes
75382else $as_nop
75383  found=no
75384fi
75385rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75386  conftest.$ac_objext conftest.beam conftest.$ac_ext
75387fi
75388
75389    LIBS=$ac_libs
75390  fi
75391
75392  if test "$found" = "yes"; then
75393
75394
75395  case bind in
75396  c|c_r) ;;
75397  *)
75398      LIBS="-lbind $LIBS"
75399   ;;
75400  esac
75401
75402
75403
75404printf "%s\n" "#define HAVE_RES_NSEARCH 1" >>confdefs.h
75405
75406
75407printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
75408
75409    ac_cv_func_res_nsearch=yes
75410  else
75411
75412
75413  unset ac_cv_lib_socket_res_nsearch
75414  unset ac_cv_lib_socket___res_nsearch
75415  unset found
75416  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_nsearch in -lsocket" >&5
75417printf %s "checking for res_nsearch in -lsocket... " >&6; }
75418if test ${ac_cv_lib_socket_res_nsearch+y}
75419then :
75420  printf %s "(cached) " >&6
75421else $as_nop
75422  ac_check_lib_save_LIBS=$LIBS
75423LIBS="-lsocket  $LIBS"
75424cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75425/* end confdefs.h.  */
75426
75427/* Override any GCC internal prototype to avoid an error.
75428   Use char because int might match the return type of a GCC
75429   builtin and then its argument prototype would still apply.  */
75430char res_nsearch ();
75431int
75432main (void)
75433{
75434return res_nsearch ();
75435  ;
75436  return 0;
75437}
75438_ACEOF
75439if ac_fn_c_try_link "$LINENO"
75440then :
75441  ac_cv_lib_socket_res_nsearch=yes
75442else $as_nop
75443  ac_cv_lib_socket_res_nsearch=no
75444fi
75445rm -f core conftest.err conftest.$ac_objext conftest.beam \
75446    conftest$ac_exeext conftest.$ac_ext
75447LIBS=$ac_check_lib_save_LIBS
75448fi
75449{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_res_nsearch" >&5
75450printf "%s\n" "$ac_cv_lib_socket_res_nsearch" >&6; }
75451if test "x$ac_cv_lib_socket_res_nsearch" = xyes
75452then :
75453  found=yes
75454else $as_nop
75455
75456    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_nsearch in -lsocket" >&5
75457printf %s "checking for __res_nsearch in -lsocket... " >&6; }
75458if test ${ac_cv_lib_socket___res_nsearch+y}
75459then :
75460  printf %s "(cached) " >&6
75461else $as_nop
75462  ac_check_lib_save_LIBS=$LIBS
75463LIBS="-lsocket  $LIBS"
75464cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75465/* end confdefs.h.  */
75466
75467/* Override any GCC internal prototype to avoid an error.
75468   Use char because int might match the return type of a GCC
75469   builtin and then its argument prototype would still apply.  */
75470char __res_nsearch ();
75471int
75472main (void)
75473{
75474return __res_nsearch ();
75475  ;
75476  return 0;
75477}
75478_ACEOF
75479if ac_fn_c_try_link "$LINENO"
75480then :
75481  ac_cv_lib_socket___res_nsearch=yes
75482else $as_nop
75483  ac_cv_lib_socket___res_nsearch=no
75484fi
75485rm -f core conftest.err conftest.$ac_objext conftest.beam \
75486    conftest$ac_exeext conftest.$ac_ext
75487LIBS=$ac_check_lib_save_LIBS
75488fi
75489{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___res_nsearch" >&5
75490printf "%s\n" "$ac_cv_lib_socket___res_nsearch" >&6; }
75491if test "x$ac_cv_lib_socket___res_nsearch" = xyes
75492then :
75493  found=yes
75494else $as_nop
75495  found=no
75496fi
75497
75498
75499fi
75500
75501
75502  if test "$found" = "yes"; then
75503    ac_libs=$LIBS
75504    LIBS="$LIBS -lsocket"
75505    if test "$cross_compiling" = yes
75506then :
75507
75508            found=yes
75509
75510else $as_nop
75511  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75512/* end confdefs.h.  */
75513int main() { return (0); }
75514_ACEOF
75515if ac_fn_c_try_run "$LINENO"
75516then :
75517  found=yes
75518else $as_nop
75519  found=no
75520fi
75521rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75522  conftest.$ac_objext conftest.beam conftest.$ac_ext
75523fi
75524
75525    LIBS=$ac_libs
75526  fi
75527
75528  if test "$found" = "yes"; then
75529
75530
75531  case socket in
75532  c|c_r) ;;
75533  *)
75534      LIBS="-lsocket $LIBS"
75535   ;;
75536  esac
75537
75538
75539
75540printf "%s\n" "#define HAVE_RES_NSEARCH 1" >>confdefs.h
75541
75542
75543printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
75544
75545    ac_cv_func_res_nsearch=yes
75546  else
75547
75548  :
75549
75550  fi
75551
75552
75553  fi
75554
75555
75556  fi
75557
75558 ;;
75559
75560  esac
75561
75562
75563  unset ac_cv_func_res_ndestroy
75564  unset ac_cv_func___res_ndestroy
75565  unset found
75566
75567  ac_fn_c_check_func "$LINENO" "res_ndestroy" "ac_cv_func_res_ndestroy"
75568if test "x$ac_cv_func_res_ndestroy" = xyes
75569then :
75570  found=yes
75571else $as_nop
75572   ac_fn_c_check_func "$LINENO" "__res_ndestroy" "ac_cv_func___res_ndestroy"
75573if test "x$ac_cv_func___res_ndestroy" = xyes
75574then :
75575  found=yes
75576else $as_nop
75577  found=no
75578fi
75579
75580fi
75581
75582
75583  case $found in
75584  yes)
75585
75586printf "%s\n" "#define HAVE_RES_NDESTROY 1" >>confdefs.h
75587
75588    ac_cv_func_res_ndestroy=yes
75589  ;;
75590
75591    *)
75592
75593  unset ac_cv_lib_resolv_res_ndestroy
75594  unset ac_cv_lib_resolv___res_ndestroy
75595  unset found
75596  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_ndestroy in -lresolv" >&5
75597printf %s "checking for res_ndestroy in -lresolv... " >&6; }
75598if test ${ac_cv_lib_resolv_res_ndestroy+y}
75599then :
75600  printf %s "(cached) " >&6
75601else $as_nop
75602  ac_check_lib_save_LIBS=$LIBS
75603LIBS="-lresolv  $LIBS"
75604cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75605/* end confdefs.h.  */
75606
75607/* Override any GCC internal prototype to avoid an error.
75608   Use char because int might match the return type of a GCC
75609   builtin and then its argument prototype would still apply.  */
75610char res_ndestroy ();
75611int
75612main (void)
75613{
75614return res_ndestroy ();
75615  ;
75616  return 0;
75617}
75618_ACEOF
75619if ac_fn_c_try_link "$LINENO"
75620then :
75621  ac_cv_lib_resolv_res_ndestroy=yes
75622else $as_nop
75623  ac_cv_lib_resolv_res_ndestroy=no
75624fi
75625rm -f core conftest.err conftest.$ac_objext conftest.beam \
75626    conftest$ac_exeext conftest.$ac_ext
75627LIBS=$ac_check_lib_save_LIBS
75628fi
75629{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_ndestroy" >&5
75630printf "%s\n" "$ac_cv_lib_resolv_res_ndestroy" >&6; }
75631if test "x$ac_cv_lib_resolv_res_ndestroy" = xyes
75632then :
75633  found=yes
75634else $as_nop
75635
75636    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_ndestroy in -lresolv" >&5
75637printf %s "checking for __res_ndestroy in -lresolv... " >&6; }
75638if test ${ac_cv_lib_resolv___res_ndestroy+y}
75639then :
75640  printf %s "(cached) " >&6
75641else $as_nop
75642  ac_check_lib_save_LIBS=$LIBS
75643LIBS="-lresolv  $LIBS"
75644cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75645/* end confdefs.h.  */
75646
75647/* Override any GCC internal prototype to avoid an error.
75648   Use char because int might match the return type of a GCC
75649   builtin and then its argument prototype would still apply.  */
75650char __res_ndestroy ();
75651int
75652main (void)
75653{
75654return __res_ndestroy ();
75655  ;
75656  return 0;
75657}
75658_ACEOF
75659if ac_fn_c_try_link "$LINENO"
75660then :
75661  ac_cv_lib_resolv___res_ndestroy=yes
75662else $as_nop
75663  ac_cv_lib_resolv___res_ndestroy=no
75664fi
75665rm -f core conftest.err conftest.$ac_objext conftest.beam \
75666    conftest$ac_exeext conftest.$ac_ext
75667LIBS=$ac_check_lib_save_LIBS
75668fi
75669{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_ndestroy" >&5
75670printf "%s\n" "$ac_cv_lib_resolv___res_ndestroy" >&6; }
75671if test "x$ac_cv_lib_resolv___res_ndestroy" = xyes
75672then :
75673  found=yes
75674else $as_nop
75675  found=no
75676fi
75677
75678
75679fi
75680
75681
75682  if test "$found" = "yes"; then
75683    ac_libs=$LIBS
75684    LIBS="$LIBS -lresolv"
75685    if test "$cross_compiling" = yes
75686then :
75687
75688            found=yes
75689
75690else $as_nop
75691  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75692/* end confdefs.h.  */
75693int main() { return (0); }
75694_ACEOF
75695if ac_fn_c_try_run "$LINENO"
75696then :
75697  found=yes
75698else $as_nop
75699  found=no
75700fi
75701rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75702  conftest.$ac_objext conftest.beam conftest.$ac_ext
75703fi
75704
75705    LIBS=$ac_libs
75706  fi
75707
75708  if test "$found" = "yes"; then
75709
75710
75711  case resolv in
75712  c|c_r) ;;
75713  *)
75714      LIBS="-lresolv $LIBS"
75715   ;;
75716  esac
75717
75718
75719
75720printf "%s\n" "#define HAVE_RES_NDESTROY 1" >>confdefs.h
75721
75722
75723printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
75724
75725    ac_cv_func_res_ndestroy=yes
75726  else
75727
75728
75729  unset ac_cv_lib_bind_res_ndestroy
75730  unset ac_cv_lib_bind___res_ndestroy
75731  unset found
75732  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_ndestroy in -lbind" >&5
75733printf %s "checking for res_ndestroy in -lbind... " >&6; }
75734if test ${ac_cv_lib_bind_res_ndestroy+y}
75735then :
75736  printf %s "(cached) " >&6
75737else $as_nop
75738  ac_check_lib_save_LIBS=$LIBS
75739LIBS="-lbind  $LIBS"
75740cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75741/* end confdefs.h.  */
75742
75743/* Override any GCC internal prototype to avoid an error.
75744   Use char because int might match the return type of a GCC
75745   builtin and then its argument prototype would still apply.  */
75746char res_ndestroy ();
75747int
75748main (void)
75749{
75750return res_ndestroy ();
75751  ;
75752  return 0;
75753}
75754_ACEOF
75755if ac_fn_c_try_link "$LINENO"
75756then :
75757  ac_cv_lib_bind_res_ndestroy=yes
75758else $as_nop
75759  ac_cv_lib_bind_res_ndestroy=no
75760fi
75761rm -f core conftest.err conftest.$ac_objext conftest.beam \
75762    conftest$ac_exeext conftest.$ac_ext
75763LIBS=$ac_check_lib_save_LIBS
75764fi
75765{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_res_ndestroy" >&5
75766printf "%s\n" "$ac_cv_lib_bind_res_ndestroy" >&6; }
75767if test "x$ac_cv_lib_bind_res_ndestroy" = xyes
75768then :
75769  found=yes
75770else $as_nop
75771
75772    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_ndestroy in -lbind" >&5
75773printf %s "checking for __res_ndestroy in -lbind... " >&6; }
75774if test ${ac_cv_lib_bind___res_ndestroy+y}
75775then :
75776  printf %s "(cached) " >&6
75777else $as_nop
75778  ac_check_lib_save_LIBS=$LIBS
75779LIBS="-lbind  $LIBS"
75780cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75781/* end confdefs.h.  */
75782
75783/* Override any GCC internal prototype to avoid an error.
75784   Use char because int might match the return type of a GCC
75785   builtin and then its argument prototype would still apply.  */
75786char __res_ndestroy ();
75787int
75788main (void)
75789{
75790return __res_ndestroy ();
75791  ;
75792  return 0;
75793}
75794_ACEOF
75795if ac_fn_c_try_link "$LINENO"
75796then :
75797  ac_cv_lib_bind___res_ndestroy=yes
75798else $as_nop
75799  ac_cv_lib_bind___res_ndestroy=no
75800fi
75801rm -f core conftest.err conftest.$ac_objext conftest.beam \
75802    conftest$ac_exeext conftest.$ac_ext
75803LIBS=$ac_check_lib_save_LIBS
75804fi
75805{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___res_ndestroy" >&5
75806printf "%s\n" "$ac_cv_lib_bind___res_ndestroy" >&6; }
75807if test "x$ac_cv_lib_bind___res_ndestroy" = xyes
75808then :
75809  found=yes
75810else $as_nop
75811  found=no
75812fi
75813
75814
75815fi
75816
75817
75818  if test "$found" = "yes"; then
75819    ac_libs=$LIBS
75820    LIBS="$LIBS -lbind"
75821    if test "$cross_compiling" = yes
75822then :
75823
75824            found=yes
75825
75826else $as_nop
75827  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75828/* end confdefs.h.  */
75829int main() { return (0); }
75830_ACEOF
75831if ac_fn_c_try_run "$LINENO"
75832then :
75833  found=yes
75834else $as_nop
75835  found=no
75836fi
75837rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75838  conftest.$ac_objext conftest.beam conftest.$ac_ext
75839fi
75840
75841    LIBS=$ac_libs
75842  fi
75843
75844  if test "$found" = "yes"; then
75845
75846
75847  case bind in
75848  c|c_r) ;;
75849  *)
75850      LIBS="-lbind $LIBS"
75851   ;;
75852  esac
75853
75854
75855
75856printf "%s\n" "#define HAVE_RES_NDESTROY 1" >>confdefs.h
75857
75858
75859printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
75860
75861    ac_cv_func_res_ndestroy=yes
75862  else
75863
75864
75865  unset ac_cv_lib_socket_res_ndestroy
75866  unset ac_cv_lib_socket___res_ndestroy
75867  unset found
75868  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_ndestroy in -lsocket" >&5
75869printf %s "checking for res_ndestroy in -lsocket... " >&6; }
75870if test ${ac_cv_lib_socket_res_ndestroy+y}
75871then :
75872  printf %s "(cached) " >&6
75873else $as_nop
75874  ac_check_lib_save_LIBS=$LIBS
75875LIBS="-lsocket  $LIBS"
75876cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75877/* end confdefs.h.  */
75878
75879/* Override any GCC internal prototype to avoid an error.
75880   Use char because int might match the return type of a GCC
75881   builtin and then its argument prototype would still apply.  */
75882char res_ndestroy ();
75883int
75884main (void)
75885{
75886return res_ndestroy ();
75887  ;
75888  return 0;
75889}
75890_ACEOF
75891if ac_fn_c_try_link "$LINENO"
75892then :
75893  ac_cv_lib_socket_res_ndestroy=yes
75894else $as_nop
75895  ac_cv_lib_socket_res_ndestroy=no
75896fi
75897rm -f core conftest.err conftest.$ac_objext conftest.beam \
75898    conftest$ac_exeext conftest.$ac_ext
75899LIBS=$ac_check_lib_save_LIBS
75900fi
75901{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_res_ndestroy" >&5
75902printf "%s\n" "$ac_cv_lib_socket_res_ndestroy" >&6; }
75903if test "x$ac_cv_lib_socket_res_ndestroy" = xyes
75904then :
75905  found=yes
75906else $as_nop
75907
75908    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_ndestroy in -lsocket" >&5
75909printf %s "checking for __res_ndestroy in -lsocket... " >&6; }
75910if test ${ac_cv_lib_socket___res_ndestroy+y}
75911then :
75912  printf %s "(cached) " >&6
75913else $as_nop
75914  ac_check_lib_save_LIBS=$LIBS
75915LIBS="-lsocket  $LIBS"
75916cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75917/* end confdefs.h.  */
75918
75919/* Override any GCC internal prototype to avoid an error.
75920   Use char because int might match the return type of a GCC
75921   builtin and then its argument prototype would still apply.  */
75922char __res_ndestroy ();
75923int
75924main (void)
75925{
75926return __res_ndestroy ();
75927  ;
75928  return 0;
75929}
75930_ACEOF
75931if ac_fn_c_try_link "$LINENO"
75932then :
75933  ac_cv_lib_socket___res_ndestroy=yes
75934else $as_nop
75935  ac_cv_lib_socket___res_ndestroy=no
75936fi
75937rm -f core conftest.err conftest.$ac_objext conftest.beam \
75938    conftest$ac_exeext conftest.$ac_ext
75939LIBS=$ac_check_lib_save_LIBS
75940fi
75941{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___res_ndestroy" >&5
75942printf "%s\n" "$ac_cv_lib_socket___res_ndestroy" >&6; }
75943if test "x$ac_cv_lib_socket___res_ndestroy" = xyes
75944then :
75945  found=yes
75946else $as_nop
75947  found=no
75948fi
75949
75950
75951fi
75952
75953
75954  if test "$found" = "yes"; then
75955    ac_libs=$LIBS
75956    LIBS="$LIBS -lsocket"
75957    if test "$cross_compiling" = yes
75958then :
75959
75960            found=yes
75961
75962else $as_nop
75963  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
75964/* end confdefs.h.  */
75965int main() { return (0); }
75966_ACEOF
75967if ac_fn_c_try_run "$LINENO"
75968then :
75969  found=yes
75970else $as_nop
75971  found=no
75972fi
75973rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
75974  conftest.$ac_objext conftest.beam conftest.$ac_ext
75975fi
75976
75977    LIBS=$ac_libs
75978  fi
75979
75980  if test "$found" = "yes"; then
75981
75982
75983  case socket in
75984  c|c_r) ;;
75985  *)
75986      LIBS="-lsocket $LIBS"
75987   ;;
75988  esac
75989
75990
75991
75992printf "%s\n" "#define HAVE_RES_NDESTROY 1" >>confdefs.h
75993
75994
75995printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
75996
75997    ac_cv_func_res_ndestroy=yes
75998  else
75999
76000  :
76001
76002  fi
76003
76004
76005  fi
76006
76007
76008  fi
76009
76010 ;;
76011
76012  esac
76013
76014
76015  unset ac_cv_func_dns_search
76016  unset ac_cv_func___dns_search
76017  unset found
76018
76019  ac_fn_c_check_func "$LINENO" "dns_search" "ac_cv_func_dns_search"
76020if test "x$ac_cv_func_dns_search" = xyes
76021then :
76022  found=yes
76023else $as_nop
76024   ac_fn_c_check_func "$LINENO" "__dns_search" "ac_cv_func___dns_search"
76025if test "x$ac_cv_func___dns_search" = xyes
76026then :
76027  found=yes
76028else $as_nop
76029  found=no
76030fi
76031
76032fi
76033
76034
76035  case $found in
76036  yes)
76037
76038printf "%s\n" "#define HAVE_DNS_SEARCH 1" >>confdefs.h
76039
76040    ac_cv_func_dns_search=yes
76041  ;;
76042
76043    *)
76044
76045  unset ac_cv_lib_resolv_dns_search
76046  unset ac_cv_lib_resolv___dns_search
76047  unset found
76048  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dns_search in -lresolv" >&5
76049printf %s "checking for dns_search in -lresolv... " >&6; }
76050if test ${ac_cv_lib_resolv_dns_search+y}
76051then :
76052  printf %s "(cached) " >&6
76053else $as_nop
76054  ac_check_lib_save_LIBS=$LIBS
76055LIBS="-lresolv  $LIBS"
76056cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76057/* end confdefs.h.  */
76058
76059/* Override any GCC internal prototype to avoid an error.
76060   Use char because int might match the return type of a GCC
76061   builtin and then its argument prototype would still apply.  */
76062char dns_search ();
76063int
76064main (void)
76065{
76066return dns_search ();
76067  ;
76068  return 0;
76069}
76070_ACEOF
76071if ac_fn_c_try_link "$LINENO"
76072then :
76073  ac_cv_lib_resolv_dns_search=yes
76074else $as_nop
76075  ac_cv_lib_resolv_dns_search=no
76076fi
76077rm -f core conftest.err conftest.$ac_objext conftest.beam \
76078    conftest$ac_exeext conftest.$ac_ext
76079LIBS=$ac_check_lib_save_LIBS
76080fi
76081{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_dns_search" >&5
76082printf "%s\n" "$ac_cv_lib_resolv_dns_search" >&6; }
76083if test "x$ac_cv_lib_resolv_dns_search" = xyes
76084then :
76085  found=yes
76086else $as_nop
76087
76088    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dns_search in -lresolv" >&5
76089printf %s "checking for __dns_search in -lresolv... " >&6; }
76090if test ${ac_cv_lib_resolv___dns_search+y}
76091then :
76092  printf %s "(cached) " >&6
76093else $as_nop
76094  ac_check_lib_save_LIBS=$LIBS
76095LIBS="-lresolv  $LIBS"
76096cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76097/* end confdefs.h.  */
76098
76099/* Override any GCC internal prototype to avoid an error.
76100   Use char because int might match the return type of a GCC
76101   builtin and then its argument prototype would still apply.  */
76102char __dns_search ();
76103int
76104main (void)
76105{
76106return __dns_search ();
76107  ;
76108  return 0;
76109}
76110_ACEOF
76111if ac_fn_c_try_link "$LINENO"
76112then :
76113  ac_cv_lib_resolv___dns_search=yes
76114else $as_nop
76115  ac_cv_lib_resolv___dns_search=no
76116fi
76117rm -f core conftest.err conftest.$ac_objext conftest.beam \
76118    conftest$ac_exeext conftest.$ac_ext
76119LIBS=$ac_check_lib_save_LIBS
76120fi
76121{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___dns_search" >&5
76122printf "%s\n" "$ac_cv_lib_resolv___dns_search" >&6; }
76123if test "x$ac_cv_lib_resolv___dns_search" = xyes
76124then :
76125  found=yes
76126else $as_nop
76127  found=no
76128fi
76129
76130
76131fi
76132
76133
76134  if test "$found" = "yes"; then
76135    ac_libs=$LIBS
76136    LIBS="$LIBS -lresolv"
76137    if test "$cross_compiling" = yes
76138then :
76139
76140            found=yes
76141
76142else $as_nop
76143  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76144/* end confdefs.h.  */
76145int main() { return (0); }
76146_ACEOF
76147if ac_fn_c_try_run "$LINENO"
76148then :
76149  found=yes
76150else $as_nop
76151  found=no
76152fi
76153rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76154  conftest.$ac_objext conftest.beam conftest.$ac_ext
76155fi
76156
76157    LIBS=$ac_libs
76158  fi
76159
76160  if test "$found" = "yes"; then
76161
76162
76163  case resolv in
76164  c|c_r) ;;
76165  *)
76166      LIBS="-lresolv $LIBS"
76167   ;;
76168  esac
76169
76170
76171
76172printf "%s\n" "#define HAVE_DNS_SEARCH 1" >>confdefs.h
76173
76174
76175printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
76176
76177    ac_cv_func_dns_search=yes
76178  else
76179
76180
76181  unset ac_cv_lib_bind_dns_search
76182  unset ac_cv_lib_bind___dns_search
76183  unset found
76184  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dns_search in -lbind" >&5
76185printf %s "checking for dns_search in -lbind... " >&6; }
76186if test ${ac_cv_lib_bind_dns_search+y}
76187then :
76188  printf %s "(cached) " >&6
76189else $as_nop
76190  ac_check_lib_save_LIBS=$LIBS
76191LIBS="-lbind  $LIBS"
76192cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76193/* end confdefs.h.  */
76194
76195/* Override any GCC internal prototype to avoid an error.
76196   Use char because int might match the return type of a GCC
76197   builtin and then its argument prototype would still apply.  */
76198char dns_search ();
76199int
76200main (void)
76201{
76202return dns_search ();
76203  ;
76204  return 0;
76205}
76206_ACEOF
76207if ac_fn_c_try_link "$LINENO"
76208then :
76209  ac_cv_lib_bind_dns_search=yes
76210else $as_nop
76211  ac_cv_lib_bind_dns_search=no
76212fi
76213rm -f core conftest.err conftest.$ac_objext conftest.beam \
76214    conftest$ac_exeext conftest.$ac_ext
76215LIBS=$ac_check_lib_save_LIBS
76216fi
76217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_dns_search" >&5
76218printf "%s\n" "$ac_cv_lib_bind_dns_search" >&6; }
76219if test "x$ac_cv_lib_bind_dns_search" = xyes
76220then :
76221  found=yes
76222else $as_nop
76223
76224    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dns_search in -lbind" >&5
76225printf %s "checking for __dns_search in -lbind... " >&6; }
76226if test ${ac_cv_lib_bind___dns_search+y}
76227then :
76228  printf %s "(cached) " >&6
76229else $as_nop
76230  ac_check_lib_save_LIBS=$LIBS
76231LIBS="-lbind  $LIBS"
76232cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76233/* end confdefs.h.  */
76234
76235/* Override any GCC internal prototype to avoid an error.
76236   Use char because int might match the return type of a GCC
76237   builtin and then its argument prototype would still apply.  */
76238char __dns_search ();
76239int
76240main (void)
76241{
76242return __dns_search ();
76243  ;
76244  return 0;
76245}
76246_ACEOF
76247if ac_fn_c_try_link "$LINENO"
76248then :
76249  ac_cv_lib_bind___dns_search=yes
76250else $as_nop
76251  ac_cv_lib_bind___dns_search=no
76252fi
76253rm -f core conftest.err conftest.$ac_objext conftest.beam \
76254    conftest$ac_exeext conftest.$ac_ext
76255LIBS=$ac_check_lib_save_LIBS
76256fi
76257{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___dns_search" >&5
76258printf "%s\n" "$ac_cv_lib_bind___dns_search" >&6; }
76259if test "x$ac_cv_lib_bind___dns_search" = xyes
76260then :
76261  found=yes
76262else $as_nop
76263  found=no
76264fi
76265
76266
76267fi
76268
76269
76270  if test "$found" = "yes"; then
76271    ac_libs=$LIBS
76272    LIBS="$LIBS -lbind"
76273    if test "$cross_compiling" = yes
76274then :
76275
76276            found=yes
76277
76278else $as_nop
76279  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76280/* end confdefs.h.  */
76281int main() { return (0); }
76282_ACEOF
76283if ac_fn_c_try_run "$LINENO"
76284then :
76285  found=yes
76286else $as_nop
76287  found=no
76288fi
76289rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76290  conftest.$ac_objext conftest.beam conftest.$ac_ext
76291fi
76292
76293    LIBS=$ac_libs
76294  fi
76295
76296  if test "$found" = "yes"; then
76297
76298
76299  case bind in
76300  c|c_r) ;;
76301  *)
76302      LIBS="-lbind $LIBS"
76303   ;;
76304  esac
76305
76306
76307
76308printf "%s\n" "#define HAVE_DNS_SEARCH 1" >>confdefs.h
76309
76310
76311printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
76312
76313    ac_cv_func_dns_search=yes
76314  else
76315
76316
76317  unset ac_cv_lib_socket_dns_search
76318  unset ac_cv_lib_socket___dns_search
76319  unset found
76320  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dns_search in -lsocket" >&5
76321printf %s "checking for dns_search in -lsocket... " >&6; }
76322if test ${ac_cv_lib_socket_dns_search+y}
76323then :
76324  printf %s "(cached) " >&6
76325else $as_nop
76326  ac_check_lib_save_LIBS=$LIBS
76327LIBS="-lsocket  $LIBS"
76328cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76329/* end confdefs.h.  */
76330
76331/* Override any GCC internal prototype to avoid an error.
76332   Use char because int might match the return type of a GCC
76333   builtin and then its argument prototype would still apply.  */
76334char dns_search ();
76335int
76336main (void)
76337{
76338return dns_search ();
76339  ;
76340  return 0;
76341}
76342_ACEOF
76343if ac_fn_c_try_link "$LINENO"
76344then :
76345  ac_cv_lib_socket_dns_search=yes
76346else $as_nop
76347  ac_cv_lib_socket_dns_search=no
76348fi
76349rm -f core conftest.err conftest.$ac_objext conftest.beam \
76350    conftest$ac_exeext conftest.$ac_ext
76351LIBS=$ac_check_lib_save_LIBS
76352fi
76353{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_dns_search" >&5
76354printf "%s\n" "$ac_cv_lib_socket_dns_search" >&6; }
76355if test "x$ac_cv_lib_socket_dns_search" = xyes
76356then :
76357  found=yes
76358else $as_nop
76359
76360    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dns_search in -lsocket" >&5
76361printf %s "checking for __dns_search in -lsocket... " >&6; }
76362if test ${ac_cv_lib_socket___dns_search+y}
76363then :
76364  printf %s "(cached) " >&6
76365else $as_nop
76366  ac_check_lib_save_LIBS=$LIBS
76367LIBS="-lsocket  $LIBS"
76368cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76369/* end confdefs.h.  */
76370
76371/* Override any GCC internal prototype to avoid an error.
76372   Use char because int might match the return type of a GCC
76373   builtin and then its argument prototype would still apply.  */
76374char __dns_search ();
76375int
76376main (void)
76377{
76378return __dns_search ();
76379  ;
76380  return 0;
76381}
76382_ACEOF
76383if ac_fn_c_try_link "$LINENO"
76384then :
76385  ac_cv_lib_socket___dns_search=yes
76386else $as_nop
76387  ac_cv_lib_socket___dns_search=no
76388fi
76389rm -f core conftest.err conftest.$ac_objext conftest.beam \
76390    conftest$ac_exeext conftest.$ac_ext
76391LIBS=$ac_check_lib_save_LIBS
76392fi
76393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___dns_search" >&5
76394printf "%s\n" "$ac_cv_lib_socket___dns_search" >&6; }
76395if test "x$ac_cv_lib_socket___dns_search" = xyes
76396then :
76397  found=yes
76398else $as_nop
76399  found=no
76400fi
76401
76402
76403fi
76404
76405
76406  if test "$found" = "yes"; then
76407    ac_libs=$LIBS
76408    LIBS="$LIBS -lsocket"
76409    if test "$cross_compiling" = yes
76410then :
76411
76412            found=yes
76413
76414else $as_nop
76415  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76416/* end confdefs.h.  */
76417int main() { return (0); }
76418_ACEOF
76419if ac_fn_c_try_run "$LINENO"
76420then :
76421  found=yes
76422else $as_nop
76423  found=no
76424fi
76425rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76426  conftest.$ac_objext conftest.beam conftest.$ac_ext
76427fi
76428
76429    LIBS=$ac_libs
76430  fi
76431
76432  if test "$found" = "yes"; then
76433
76434
76435  case socket in
76436  c|c_r) ;;
76437  *)
76438      LIBS="-lsocket $LIBS"
76439   ;;
76440  esac
76441
76442
76443
76444printf "%s\n" "#define HAVE_DNS_SEARCH 1" >>confdefs.h
76445
76446
76447printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
76448
76449    ac_cv_func_dns_search=yes
76450  else
76451
76452  :
76453
76454  fi
76455
76456
76457  fi
76458
76459
76460  fi
76461
76462 ;;
76463
76464  esac
76465
76466
76467  unset ac_cv_func_dn_expand
76468  unset ac_cv_func___dn_expand
76469  unset found
76470
76471  ac_fn_c_check_func "$LINENO" "dn_expand" "ac_cv_func_dn_expand"
76472if test "x$ac_cv_func_dn_expand" = xyes
76473then :
76474  found=yes
76475else $as_nop
76476   ac_fn_c_check_func "$LINENO" "__dn_expand" "ac_cv_func___dn_expand"
76477if test "x$ac_cv_func___dn_expand" = xyes
76478then :
76479  found=yes
76480else $as_nop
76481  found=no
76482fi
76483
76484fi
76485
76486
76487  case $found in
76488  yes)
76489
76490printf "%s\n" "#define HAVE_DN_EXPAND 1" >>confdefs.h
76491
76492    ac_cv_func_dn_expand=yes
76493  ;;
76494
76495    *)
76496
76497  unset ac_cv_lib_resolv_dn_expand
76498  unset ac_cv_lib_resolv___dn_expand
76499  unset found
76500  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_expand in -lresolv" >&5
76501printf %s "checking for dn_expand in -lresolv... " >&6; }
76502if test ${ac_cv_lib_resolv_dn_expand+y}
76503then :
76504  printf %s "(cached) " >&6
76505else $as_nop
76506  ac_check_lib_save_LIBS=$LIBS
76507LIBS="-lresolv  $LIBS"
76508cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76509/* end confdefs.h.  */
76510
76511/* Override any GCC internal prototype to avoid an error.
76512   Use char because int might match the return type of a GCC
76513   builtin and then its argument prototype would still apply.  */
76514char dn_expand ();
76515int
76516main (void)
76517{
76518return dn_expand ();
76519  ;
76520  return 0;
76521}
76522_ACEOF
76523if ac_fn_c_try_link "$LINENO"
76524then :
76525  ac_cv_lib_resolv_dn_expand=yes
76526else $as_nop
76527  ac_cv_lib_resolv_dn_expand=no
76528fi
76529rm -f core conftest.err conftest.$ac_objext conftest.beam \
76530    conftest$ac_exeext conftest.$ac_ext
76531LIBS=$ac_check_lib_save_LIBS
76532fi
76533{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_dn_expand" >&5
76534printf "%s\n" "$ac_cv_lib_resolv_dn_expand" >&6; }
76535if test "x$ac_cv_lib_resolv_dn_expand" = xyes
76536then :
76537  found=yes
76538else $as_nop
76539
76540    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_expand in -lresolv" >&5
76541printf %s "checking for __dn_expand in -lresolv... " >&6; }
76542if test ${ac_cv_lib_resolv___dn_expand+y}
76543then :
76544  printf %s "(cached) " >&6
76545else $as_nop
76546  ac_check_lib_save_LIBS=$LIBS
76547LIBS="-lresolv  $LIBS"
76548cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76549/* end confdefs.h.  */
76550
76551/* Override any GCC internal prototype to avoid an error.
76552   Use char because int might match the return type of a GCC
76553   builtin and then its argument prototype would still apply.  */
76554char __dn_expand ();
76555int
76556main (void)
76557{
76558return __dn_expand ();
76559  ;
76560  return 0;
76561}
76562_ACEOF
76563if ac_fn_c_try_link "$LINENO"
76564then :
76565  ac_cv_lib_resolv___dn_expand=yes
76566else $as_nop
76567  ac_cv_lib_resolv___dn_expand=no
76568fi
76569rm -f core conftest.err conftest.$ac_objext conftest.beam \
76570    conftest$ac_exeext conftest.$ac_ext
76571LIBS=$ac_check_lib_save_LIBS
76572fi
76573{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___dn_expand" >&5
76574printf "%s\n" "$ac_cv_lib_resolv___dn_expand" >&6; }
76575if test "x$ac_cv_lib_resolv___dn_expand" = xyes
76576then :
76577  found=yes
76578else $as_nop
76579  found=no
76580fi
76581
76582
76583fi
76584
76585
76586  if test "$found" = "yes"; then
76587    ac_libs=$LIBS
76588    LIBS="$LIBS -lresolv"
76589    if test "$cross_compiling" = yes
76590then :
76591
76592            found=yes
76593
76594else $as_nop
76595  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76596/* end confdefs.h.  */
76597int main() { return (0); }
76598_ACEOF
76599if ac_fn_c_try_run "$LINENO"
76600then :
76601  found=yes
76602else $as_nop
76603  found=no
76604fi
76605rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76606  conftest.$ac_objext conftest.beam conftest.$ac_ext
76607fi
76608
76609    LIBS=$ac_libs
76610  fi
76611
76612  if test "$found" = "yes"; then
76613
76614
76615  case resolv in
76616  c|c_r) ;;
76617  *)
76618      LIBS="-lresolv $LIBS"
76619   ;;
76620  esac
76621
76622
76623
76624printf "%s\n" "#define HAVE_DN_EXPAND 1" >>confdefs.h
76625
76626
76627printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
76628
76629    ac_cv_func_dn_expand=yes
76630  else
76631
76632
76633  unset ac_cv_lib_bind_dn_expand
76634  unset ac_cv_lib_bind___dn_expand
76635  unset found
76636  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_expand in -lbind" >&5
76637printf %s "checking for dn_expand in -lbind... " >&6; }
76638if test ${ac_cv_lib_bind_dn_expand+y}
76639then :
76640  printf %s "(cached) " >&6
76641else $as_nop
76642  ac_check_lib_save_LIBS=$LIBS
76643LIBS="-lbind  $LIBS"
76644cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76645/* end confdefs.h.  */
76646
76647/* Override any GCC internal prototype to avoid an error.
76648   Use char because int might match the return type of a GCC
76649   builtin and then its argument prototype would still apply.  */
76650char dn_expand ();
76651int
76652main (void)
76653{
76654return dn_expand ();
76655  ;
76656  return 0;
76657}
76658_ACEOF
76659if ac_fn_c_try_link "$LINENO"
76660then :
76661  ac_cv_lib_bind_dn_expand=yes
76662else $as_nop
76663  ac_cv_lib_bind_dn_expand=no
76664fi
76665rm -f core conftest.err conftest.$ac_objext conftest.beam \
76666    conftest$ac_exeext conftest.$ac_ext
76667LIBS=$ac_check_lib_save_LIBS
76668fi
76669{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_dn_expand" >&5
76670printf "%s\n" "$ac_cv_lib_bind_dn_expand" >&6; }
76671if test "x$ac_cv_lib_bind_dn_expand" = xyes
76672then :
76673  found=yes
76674else $as_nop
76675
76676    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_expand in -lbind" >&5
76677printf %s "checking for __dn_expand in -lbind... " >&6; }
76678if test ${ac_cv_lib_bind___dn_expand+y}
76679then :
76680  printf %s "(cached) " >&6
76681else $as_nop
76682  ac_check_lib_save_LIBS=$LIBS
76683LIBS="-lbind  $LIBS"
76684cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76685/* end confdefs.h.  */
76686
76687/* Override any GCC internal prototype to avoid an error.
76688   Use char because int might match the return type of a GCC
76689   builtin and then its argument prototype would still apply.  */
76690char __dn_expand ();
76691int
76692main (void)
76693{
76694return __dn_expand ();
76695  ;
76696  return 0;
76697}
76698_ACEOF
76699if ac_fn_c_try_link "$LINENO"
76700then :
76701  ac_cv_lib_bind___dn_expand=yes
76702else $as_nop
76703  ac_cv_lib_bind___dn_expand=no
76704fi
76705rm -f core conftest.err conftest.$ac_objext conftest.beam \
76706    conftest$ac_exeext conftest.$ac_ext
76707LIBS=$ac_check_lib_save_LIBS
76708fi
76709{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___dn_expand" >&5
76710printf "%s\n" "$ac_cv_lib_bind___dn_expand" >&6; }
76711if test "x$ac_cv_lib_bind___dn_expand" = xyes
76712then :
76713  found=yes
76714else $as_nop
76715  found=no
76716fi
76717
76718
76719fi
76720
76721
76722  if test "$found" = "yes"; then
76723    ac_libs=$LIBS
76724    LIBS="$LIBS -lbind"
76725    if test "$cross_compiling" = yes
76726then :
76727
76728            found=yes
76729
76730else $as_nop
76731  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76732/* end confdefs.h.  */
76733int main() { return (0); }
76734_ACEOF
76735if ac_fn_c_try_run "$LINENO"
76736then :
76737  found=yes
76738else $as_nop
76739  found=no
76740fi
76741rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76742  conftest.$ac_objext conftest.beam conftest.$ac_ext
76743fi
76744
76745    LIBS=$ac_libs
76746  fi
76747
76748  if test "$found" = "yes"; then
76749
76750
76751  case bind in
76752  c|c_r) ;;
76753  *)
76754      LIBS="-lbind $LIBS"
76755   ;;
76756  esac
76757
76758
76759
76760printf "%s\n" "#define HAVE_DN_EXPAND 1" >>confdefs.h
76761
76762
76763printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
76764
76765    ac_cv_func_dn_expand=yes
76766  else
76767
76768
76769  unset ac_cv_lib_socket_dn_expand
76770  unset ac_cv_lib_socket___dn_expand
76771  unset found
76772  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_expand in -lsocket" >&5
76773printf %s "checking for dn_expand in -lsocket... " >&6; }
76774if test ${ac_cv_lib_socket_dn_expand+y}
76775then :
76776  printf %s "(cached) " >&6
76777else $as_nop
76778  ac_check_lib_save_LIBS=$LIBS
76779LIBS="-lsocket  $LIBS"
76780cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76781/* end confdefs.h.  */
76782
76783/* Override any GCC internal prototype to avoid an error.
76784   Use char because int might match the return type of a GCC
76785   builtin and then its argument prototype would still apply.  */
76786char dn_expand ();
76787int
76788main (void)
76789{
76790return dn_expand ();
76791  ;
76792  return 0;
76793}
76794_ACEOF
76795if ac_fn_c_try_link "$LINENO"
76796then :
76797  ac_cv_lib_socket_dn_expand=yes
76798else $as_nop
76799  ac_cv_lib_socket_dn_expand=no
76800fi
76801rm -f core conftest.err conftest.$ac_objext conftest.beam \
76802    conftest$ac_exeext conftest.$ac_ext
76803LIBS=$ac_check_lib_save_LIBS
76804fi
76805{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_dn_expand" >&5
76806printf "%s\n" "$ac_cv_lib_socket_dn_expand" >&6; }
76807if test "x$ac_cv_lib_socket_dn_expand" = xyes
76808then :
76809  found=yes
76810else $as_nop
76811
76812    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_expand in -lsocket" >&5
76813printf %s "checking for __dn_expand in -lsocket... " >&6; }
76814if test ${ac_cv_lib_socket___dn_expand+y}
76815then :
76816  printf %s "(cached) " >&6
76817else $as_nop
76818  ac_check_lib_save_LIBS=$LIBS
76819LIBS="-lsocket  $LIBS"
76820cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76821/* end confdefs.h.  */
76822
76823/* Override any GCC internal prototype to avoid an error.
76824   Use char because int might match the return type of a GCC
76825   builtin and then its argument prototype would still apply.  */
76826char __dn_expand ();
76827int
76828main (void)
76829{
76830return __dn_expand ();
76831  ;
76832  return 0;
76833}
76834_ACEOF
76835if ac_fn_c_try_link "$LINENO"
76836then :
76837  ac_cv_lib_socket___dn_expand=yes
76838else $as_nop
76839  ac_cv_lib_socket___dn_expand=no
76840fi
76841rm -f core conftest.err conftest.$ac_objext conftest.beam \
76842    conftest$ac_exeext conftest.$ac_ext
76843LIBS=$ac_check_lib_save_LIBS
76844fi
76845{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___dn_expand" >&5
76846printf "%s\n" "$ac_cv_lib_socket___dn_expand" >&6; }
76847if test "x$ac_cv_lib_socket___dn_expand" = xyes
76848then :
76849  found=yes
76850else $as_nop
76851  found=no
76852fi
76853
76854
76855fi
76856
76857
76858  if test "$found" = "yes"; then
76859    ac_libs=$LIBS
76860    LIBS="$LIBS -lsocket"
76861    if test "$cross_compiling" = yes
76862then :
76863
76864            found=yes
76865
76866else $as_nop
76867  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76868/* end confdefs.h.  */
76869int main() { return (0); }
76870_ACEOF
76871if ac_fn_c_try_run "$LINENO"
76872then :
76873  found=yes
76874else $as_nop
76875  found=no
76876fi
76877rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
76878  conftest.$ac_objext conftest.beam conftest.$ac_ext
76879fi
76880
76881    LIBS=$ac_libs
76882  fi
76883
76884  if test "$found" = "yes"; then
76885
76886
76887  case socket in
76888  c|c_r) ;;
76889  *)
76890      LIBS="-lsocket $LIBS"
76891   ;;
76892  esac
76893
76894
76895
76896printf "%s\n" "#define HAVE_DN_EXPAND 1" >>confdefs.h
76897
76898
76899printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
76900
76901    ac_cv_func_dn_expand=yes
76902  else
76903
76904  :
76905
76906  fi
76907
76908
76909  fi
76910
76911
76912  fi
76913
76914 ;;
76915
76916  esac
76917
76918
76919  unset ac_cv_func_dn_skipname
76920  unset ac_cv_func___dn_skipname
76921  unset found
76922
76923  ac_fn_c_check_func "$LINENO" "dn_skipname" "ac_cv_func_dn_skipname"
76924if test "x$ac_cv_func_dn_skipname" = xyes
76925then :
76926  found=yes
76927else $as_nop
76928   ac_fn_c_check_func "$LINENO" "__dn_skipname" "ac_cv_func___dn_skipname"
76929if test "x$ac_cv_func___dn_skipname" = xyes
76930then :
76931  found=yes
76932else $as_nop
76933  found=no
76934fi
76935
76936fi
76937
76938
76939  case $found in
76940  yes)
76941
76942printf "%s\n" "#define HAVE_DN_SKIPNAME 1" >>confdefs.h
76943
76944    ac_cv_func_dn_skipname=yes
76945  ;;
76946
76947    *)
76948
76949  unset ac_cv_lib_resolv_dn_skipname
76950  unset ac_cv_lib_resolv___dn_skipname
76951  unset found
76952  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_skipname in -lresolv" >&5
76953printf %s "checking for dn_skipname in -lresolv... " >&6; }
76954if test ${ac_cv_lib_resolv_dn_skipname+y}
76955then :
76956  printf %s "(cached) " >&6
76957else $as_nop
76958  ac_check_lib_save_LIBS=$LIBS
76959LIBS="-lresolv  $LIBS"
76960cat confdefs.h - <<_ACEOF >conftest.$ac_ext
76961/* end confdefs.h.  */
76962
76963/* Override any GCC internal prototype to avoid an error.
76964   Use char because int might match the return type of a GCC
76965   builtin and then its argument prototype would still apply.  */
76966char dn_skipname ();
76967int
76968main (void)
76969{
76970return dn_skipname ();
76971  ;
76972  return 0;
76973}
76974_ACEOF
76975if ac_fn_c_try_link "$LINENO"
76976then :
76977  ac_cv_lib_resolv_dn_skipname=yes
76978else $as_nop
76979  ac_cv_lib_resolv_dn_skipname=no
76980fi
76981rm -f core conftest.err conftest.$ac_objext conftest.beam \
76982    conftest$ac_exeext conftest.$ac_ext
76983LIBS=$ac_check_lib_save_LIBS
76984fi
76985{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_dn_skipname" >&5
76986printf "%s\n" "$ac_cv_lib_resolv_dn_skipname" >&6; }
76987if test "x$ac_cv_lib_resolv_dn_skipname" = xyes
76988then :
76989  found=yes
76990else $as_nop
76991
76992    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_skipname in -lresolv" >&5
76993printf %s "checking for __dn_skipname in -lresolv... " >&6; }
76994if test ${ac_cv_lib_resolv___dn_skipname+y}
76995then :
76996  printf %s "(cached) " >&6
76997else $as_nop
76998  ac_check_lib_save_LIBS=$LIBS
76999LIBS="-lresolv  $LIBS"
77000cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77001/* end confdefs.h.  */
77002
77003/* Override any GCC internal prototype to avoid an error.
77004   Use char because int might match the return type of a GCC
77005   builtin and then its argument prototype would still apply.  */
77006char __dn_skipname ();
77007int
77008main (void)
77009{
77010return __dn_skipname ();
77011  ;
77012  return 0;
77013}
77014_ACEOF
77015if ac_fn_c_try_link "$LINENO"
77016then :
77017  ac_cv_lib_resolv___dn_skipname=yes
77018else $as_nop
77019  ac_cv_lib_resolv___dn_skipname=no
77020fi
77021rm -f core conftest.err conftest.$ac_objext conftest.beam \
77022    conftest$ac_exeext conftest.$ac_ext
77023LIBS=$ac_check_lib_save_LIBS
77024fi
77025{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___dn_skipname" >&5
77026printf "%s\n" "$ac_cv_lib_resolv___dn_skipname" >&6; }
77027if test "x$ac_cv_lib_resolv___dn_skipname" = xyes
77028then :
77029  found=yes
77030else $as_nop
77031  found=no
77032fi
77033
77034
77035fi
77036
77037
77038  if test "$found" = "yes"; then
77039    ac_libs=$LIBS
77040    LIBS="$LIBS -lresolv"
77041    if test "$cross_compiling" = yes
77042then :
77043
77044            found=yes
77045
77046else $as_nop
77047  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77048/* end confdefs.h.  */
77049int main() { return (0); }
77050_ACEOF
77051if ac_fn_c_try_run "$LINENO"
77052then :
77053  found=yes
77054else $as_nop
77055  found=no
77056fi
77057rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77058  conftest.$ac_objext conftest.beam conftest.$ac_ext
77059fi
77060
77061    LIBS=$ac_libs
77062  fi
77063
77064  if test "$found" = "yes"; then
77065
77066
77067  case resolv in
77068  c|c_r) ;;
77069  *)
77070      LIBS="-lresolv $LIBS"
77071   ;;
77072  esac
77073
77074
77075
77076printf "%s\n" "#define HAVE_DN_SKIPNAME 1" >>confdefs.h
77077
77078
77079printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
77080
77081    ac_cv_func_dn_skipname=yes
77082  else
77083
77084
77085  unset ac_cv_lib_bind_dn_skipname
77086  unset ac_cv_lib_bind___dn_skipname
77087  unset found
77088  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_skipname in -lbind" >&5
77089printf %s "checking for dn_skipname in -lbind... " >&6; }
77090if test ${ac_cv_lib_bind_dn_skipname+y}
77091then :
77092  printf %s "(cached) " >&6
77093else $as_nop
77094  ac_check_lib_save_LIBS=$LIBS
77095LIBS="-lbind  $LIBS"
77096cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77097/* end confdefs.h.  */
77098
77099/* Override any GCC internal prototype to avoid an error.
77100   Use char because int might match the return type of a GCC
77101   builtin and then its argument prototype would still apply.  */
77102char dn_skipname ();
77103int
77104main (void)
77105{
77106return dn_skipname ();
77107  ;
77108  return 0;
77109}
77110_ACEOF
77111if ac_fn_c_try_link "$LINENO"
77112then :
77113  ac_cv_lib_bind_dn_skipname=yes
77114else $as_nop
77115  ac_cv_lib_bind_dn_skipname=no
77116fi
77117rm -f core conftest.err conftest.$ac_objext conftest.beam \
77118    conftest$ac_exeext conftest.$ac_ext
77119LIBS=$ac_check_lib_save_LIBS
77120fi
77121{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_dn_skipname" >&5
77122printf "%s\n" "$ac_cv_lib_bind_dn_skipname" >&6; }
77123if test "x$ac_cv_lib_bind_dn_skipname" = xyes
77124then :
77125  found=yes
77126else $as_nop
77127
77128    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_skipname in -lbind" >&5
77129printf %s "checking for __dn_skipname in -lbind... " >&6; }
77130if test ${ac_cv_lib_bind___dn_skipname+y}
77131then :
77132  printf %s "(cached) " >&6
77133else $as_nop
77134  ac_check_lib_save_LIBS=$LIBS
77135LIBS="-lbind  $LIBS"
77136cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77137/* end confdefs.h.  */
77138
77139/* Override any GCC internal prototype to avoid an error.
77140   Use char because int might match the return type of a GCC
77141   builtin and then its argument prototype would still apply.  */
77142char __dn_skipname ();
77143int
77144main (void)
77145{
77146return __dn_skipname ();
77147  ;
77148  return 0;
77149}
77150_ACEOF
77151if ac_fn_c_try_link "$LINENO"
77152then :
77153  ac_cv_lib_bind___dn_skipname=yes
77154else $as_nop
77155  ac_cv_lib_bind___dn_skipname=no
77156fi
77157rm -f core conftest.err conftest.$ac_objext conftest.beam \
77158    conftest$ac_exeext conftest.$ac_ext
77159LIBS=$ac_check_lib_save_LIBS
77160fi
77161{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___dn_skipname" >&5
77162printf "%s\n" "$ac_cv_lib_bind___dn_skipname" >&6; }
77163if test "x$ac_cv_lib_bind___dn_skipname" = xyes
77164then :
77165  found=yes
77166else $as_nop
77167  found=no
77168fi
77169
77170
77171fi
77172
77173
77174  if test "$found" = "yes"; then
77175    ac_libs=$LIBS
77176    LIBS="$LIBS -lbind"
77177    if test "$cross_compiling" = yes
77178then :
77179
77180            found=yes
77181
77182else $as_nop
77183  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77184/* end confdefs.h.  */
77185int main() { return (0); }
77186_ACEOF
77187if ac_fn_c_try_run "$LINENO"
77188then :
77189  found=yes
77190else $as_nop
77191  found=no
77192fi
77193rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77194  conftest.$ac_objext conftest.beam conftest.$ac_ext
77195fi
77196
77197    LIBS=$ac_libs
77198  fi
77199
77200  if test "$found" = "yes"; then
77201
77202
77203  case bind in
77204  c|c_r) ;;
77205  *)
77206      LIBS="-lbind $LIBS"
77207   ;;
77208  esac
77209
77210
77211
77212printf "%s\n" "#define HAVE_DN_SKIPNAME 1" >>confdefs.h
77213
77214
77215printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
77216
77217    ac_cv_func_dn_skipname=yes
77218  else
77219
77220
77221  unset ac_cv_lib_socket_dn_skipname
77222  unset ac_cv_lib_socket___dn_skipname
77223  unset found
77224  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dn_skipname in -lsocket" >&5
77225printf %s "checking for dn_skipname in -lsocket... " >&6; }
77226if test ${ac_cv_lib_socket_dn_skipname+y}
77227then :
77228  printf %s "(cached) " >&6
77229else $as_nop
77230  ac_check_lib_save_LIBS=$LIBS
77231LIBS="-lsocket  $LIBS"
77232cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77233/* end confdefs.h.  */
77234
77235/* Override any GCC internal prototype to avoid an error.
77236   Use char because int might match the return type of a GCC
77237   builtin and then its argument prototype would still apply.  */
77238char dn_skipname ();
77239int
77240main (void)
77241{
77242return dn_skipname ();
77243  ;
77244  return 0;
77245}
77246_ACEOF
77247if ac_fn_c_try_link "$LINENO"
77248then :
77249  ac_cv_lib_socket_dn_skipname=yes
77250else $as_nop
77251  ac_cv_lib_socket_dn_skipname=no
77252fi
77253rm -f core conftest.err conftest.$ac_objext conftest.beam \
77254    conftest$ac_exeext conftest.$ac_ext
77255LIBS=$ac_check_lib_save_LIBS
77256fi
77257{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_dn_skipname" >&5
77258printf "%s\n" "$ac_cv_lib_socket_dn_skipname" >&6; }
77259if test "x$ac_cv_lib_socket_dn_skipname" = xyes
77260then :
77261  found=yes
77262else $as_nop
77263
77264    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __dn_skipname in -lsocket" >&5
77265printf %s "checking for __dn_skipname in -lsocket... " >&6; }
77266if test ${ac_cv_lib_socket___dn_skipname+y}
77267then :
77268  printf %s "(cached) " >&6
77269else $as_nop
77270  ac_check_lib_save_LIBS=$LIBS
77271LIBS="-lsocket  $LIBS"
77272cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77273/* end confdefs.h.  */
77274
77275/* Override any GCC internal prototype to avoid an error.
77276   Use char because int might match the return type of a GCC
77277   builtin and then its argument prototype would still apply.  */
77278char __dn_skipname ();
77279int
77280main (void)
77281{
77282return __dn_skipname ();
77283  ;
77284  return 0;
77285}
77286_ACEOF
77287if ac_fn_c_try_link "$LINENO"
77288then :
77289  ac_cv_lib_socket___dn_skipname=yes
77290else $as_nop
77291  ac_cv_lib_socket___dn_skipname=no
77292fi
77293rm -f core conftest.err conftest.$ac_objext conftest.beam \
77294    conftest$ac_exeext conftest.$ac_ext
77295LIBS=$ac_check_lib_save_LIBS
77296fi
77297{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___dn_skipname" >&5
77298printf "%s\n" "$ac_cv_lib_socket___dn_skipname" >&6; }
77299if test "x$ac_cv_lib_socket___dn_skipname" = xyes
77300then :
77301  found=yes
77302else $as_nop
77303  found=no
77304fi
77305
77306
77307fi
77308
77309
77310  if test "$found" = "yes"; then
77311    ac_libs=$LIBS
77312    LIBS="$LIBS -lsocket"
77313    if test "$cross_compiling" = yes
77314then :
77315
77316            found=yes
77317
77318else $as_nop
77319  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77320/* end confdefs.h.  */
77321int main() { return (0); }
77322_ACEOF
77323if ac_fn_c_try_run "$LINENO"
77324then :
77325  found=yes
77326else $as_nop
77327  found=no
77328fi
77329rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77330  conftest.$ac_objext conftest.beam conftest.$ac_ext
77331fi
77332
77333    LIBS=$ac_libs
77334  fi
77335
77336  if test "$found" = "yes"; then
77337
77338
77339  case socket in
77340  c|c_r) ;;
77341  *)
77342      LIBS="-lsocket $LIBS"
77343   ;;
77344  esac
77345
77346
77347
77348printf "%s\n" "#define HAVE_DN_SKIPNAME 1" >>confdefs.h
77349
77350
77351printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
77352
77353    ac_cv_func_dn_skipname=yes
77354  else
77355
77356  :
77357
77358  fi
77359
77360
77361  fi
77362
77363
77364  fi
77365
77366 ;;
77367
77368  esac
77369
77370
77371
77372
77373  unset ac_cv_func_res_search
77374  unset ac_cv_func___res_search
77375  unset found
77376
77377  ac_fn_c_check_func "$LINENO" "res_search" "ac_cv_func_res_search"
77378if test "x$ac_cv_func_res_search" = xyes
77379then :
77380  found=yes
77381else $as_nop
77382   ac_fn_c_check_func "$LINENO" "__res_search" "ac_cv_func___res_search"
77383if test "x$ac_cv_func___res_search" = xyes
77384then :
77385  found=yes
77386else $as_nop
77387  found=no
77388fi
77389
77390fi
77391
77392
77393  case $found in
77394  yes)
77395
77396printf "%s\n" "#define HAVE_RES_SEARCH 1" >>confdefs.h
77397
77398    ac_cv_func_res_search=yes
77399  ;;
77400
77401    *)
77402
77403  unset ac_cv_lib_resolv_res_search
77404  unset ac_cv_lib_resolv___res_search
77405  unset found
77406  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_search in -lresolv" >&5
77407printf %s "checking for res_search in -lresolv... " >&6; }
77408if test ${ac_cv_lib_resolv_res_search+y}
77409then :
77410  printf %s "(cached) " >&6
77411else $as_nop
77412  ac_check_lib_save_LIBS=$LIBS
77413LIBS="-lresolv  $LIBS"
77414cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77415/* end confdefs.h.  */
77416
77417/* Override any GCC internal prototype to avoid an error.
77418   Use char because int might match the return type of a GCC
77419   builtin and then its argument prototype would still apply.  */
77420char res_search ();
77421int
77422main (void)
77423{
77424return res_search ();
77425  ;
77426  return 0;
77427}
77428_ACEOF
77429if ac_fn_c_try_link "$LINENO"
77430then :
77431  ac_cv_lib_resolv_res_search=yes
77432else $as_nop
77433  ac_cv_lib_resolv_res_search=no
77434fi
77435rm -f core conftest.err conftest.$ac_objext conftest.beam \
77436    conftest$ac_exeext conftest.$ac_ext
77437LIBS=$ac_check_lib_save_LIBS
77438fi
77439{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_search" >&5
77440printf "%s\n" "$ac_cv_lib_resolv_res_search" >&6; }
77441if test "x$ac_cv_lib_resolv_res_search" = xyes
77442then :
77443  found=yes
77444else $as_nop
77445
77446    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_search in -lresolv" >&5
77447printf %s "checking for __res_search in -lresolv... " >&6; }
77448if test ${ac_cv_lib_resolv___res_search+y}
77449then :
77450  printf %s "(cached) " >&6
77451else $as_nop
77452  ac_check_lib_save_LIBS=$LIBS
77453LIBS="-lresolv  $LIBS"
77454cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77455/* end confdefs.h.  */
77456
77457/* Override any GCC internal prototype to avoid an error.
77458   Use char because int might match the return type of a GCC
77459   builtin and then its argument prototype would still apply.  */
77460char __res_search ();
77461int
77462main (void)
77463{
77464return __res_search ();
77465  ;
77466  return 0;
77467}
77468_ACEOF
77469if ac_fn_c_try_link "$LINENO"
77470then :
77471  ac_cv_lib_resolv___res_search=yes
77472else $as_nop
77473  ac_cv_lib_resolv___res_search=no
77474fi
77475rm -f core conftest.err conftest.$ac_objext conftest.beam \
77476    conftest$ac_exeext conftest.$ac_ext
77477LIBS=$ac_check_lib_save_LIBS
77478fi
77479{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_search" >&5
77480printf "%s\n" "$ac_cv_lib_resolv___res_search" >&6; }
77481if test "x$ac_cv_lib_resolv___res_search" = xyes
77482then :
77483  found=yes
77484else $as_nop
77485  found=no
77486fi
77487
77488
77489fi
77490
77491
77492  if test "$found" = "yes"; then
77493    ac_libs=$LIBS
77494    LIBS="$LIBS -lresolv"
77495    if test "$cross_compiling" = yes
77496then :
77497
77498            found=yes
77499
77500else $as_nop
77501  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77502/* end confdefs.h.  */
77503int main() { return (0); }
77504_ACEOF
77505if ac_fn_c_try_run "$LINENO"
77506then :
77507  found=yes
77508else $as_nop
77509  found=no
77510fi
77511rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77512  conftest.$ac_objext conftest.beam conftest.$ac_ext
77513fi
77514
77515    LIBS=$ac_libs
77516  fi
77517
77518  if test "$found" = "yes"; then
77519
77520
77521  case resolv in
77522  c|c_r) ;;
77523  *)
77524      LIBS="-lresolv $LIBS"
77525   ;;
77526  esac
77527
77528
77529
77530printf "%s\n" "#define HAVE_RES_SEARCH 1" >>confdefs.h
77531
77532
77533printf "%s\n" "#define HAVE_LIBRESOLV 1" >>confdefs.h
77534
77535    ac_cv_func_res_search=yes
77536  else
77537
77538
77539  unset ac_cv_lib_bind_res_search
77540  unset ac_cv_lib_bind___res_search
77541  unset found
77542  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_search in -lbind" >&5
77543printf %s "checking for res_search in -lbind... " >&6; }
77544if test ${ac_cv_lib_bind_res_search+y}
77545then :
77546  printf %s "(cached) " >&6
77547else $as_nop
77548  ac_check_lib_save_LIBS=$LIBS
77549LIBS="-lbind  $LIBS"
77550cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77551/* end confdefs.h.  */
77552
77553/* Override any GCC internal prototype to avoid an error.
77554   Use char because int might match the return type of a GCC
77555   builtin and then its argument prototype would still apply.  */
77556char res_search ();
77557int
77558main (void)
77559{
77560return res_search ();
77561  ;
77562  return 0;
77563}
77564_ACEOF
77565if ac_fn_c_try_link "$LINENO"
77566then :
77567  ac_cv_lib_bind_res_search=yes
77568else $as_nop
77569  ac_cv_lib_bind_res_search=no
77570fi
77571rm -f core conftest.err conftest.$ac_objext conftest.beam \
77572    conftest$ac_exeext conftest.$ac_ext
77573LIBS=$ac_check_lib_save_LIBS
77574fi
77575{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_res_search" >&5
77576printf "%s\n" "$ac_cv_lib_bind_res_search" >&6; }
77577if test "x$ac_cv_lib_bind_res_search" = xyes
77578then :
77579  found=yes
77580else $as_nop
77581
77582    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_search in -lbind" >&5
77583printf %s "checking for __res_search in -lbind... " >&6; }
77584if test ${ac_cv_lib_bind___res_search+y}
77585then :
77586  printf %s "(cached) " >&6
77587else $as_nop
77588  ac_check_lib_save_LIBS=$LIBS
77589LIBS="-lbind  $LIBS"
77590cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77591/* end confdefs.h.  */
77592
77593/* Override any GCC internal prototype to avoid an error.
77594   Use char because int might match the return type of a GCC
77595   builtin and then its argument prototype would still apply.  */
77596char __res_search ();
77597int
77598main (void)
77599{
77600return __res_search ();
77601  ;
77602  return 0;
77603}
77604_ACEOF
77605if ac_fn_c_try_link "$LINENO"
77606then :
77607  ac_cv_lib_bind___res_search=yes
77608else $as_nop
77609  ac_cv_lib_bind___res_search=no
77610fi
77611rm -f core conftest.err conftest.$ac_objext conftest.beam \
77612    conftest$ac_exeext conftest.$ac_ext
77613LIBS=$ac_check_lib_save_LIBS
77614fi
77615{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind___res_search" >&5
77616printf "%s\n" "$ac_cv_lib_bind___res_search" >&6; }
77617if test "x$ac_cv_lib_bind___res_search" = xyes
77618then :
77619  found=yes
77620else $as_nop
77621  found=no
77622fi
77623
77624
77625fi
77626
77627
77628  if test "$found" = "yes"; then
77629    ac_libs=$LIBS
77630    LIBS="$LIBS -lbind"
77631    if test "$cross_compiling" = yes
77632then :
77633
77634            found=yes
77635
77636else $as_nop
77637  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77638/* end confdefs.h.  */
77639int main() { return (0); }
77640_ACEOF
77641if ac_fn_c_try_run "$LINENO"
77642then :
77643  found=yes
77644else $as_nop
77645  found=no
77646fi
77647rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77648  conftest.$ac_objext conftest.beam conftest.$ac_ext
77649fi
77650
77651    LIBS=$ac_libs
77652  fi
77653
77654  if test "$found" = "yes"; then
77655
77656
77657  case bind in
77658  c|c_r) ;;
77659  *)
77660      LIBS="-lbind $LIBS"
77661   ;;
77662  esac
77663
77664
77665
77666printf "%s\n" "#define HAVE_RES_SEARCH 1" >>confdefs.h
77667
77668
77669printf "%s\n" "#define HAVE_LIBBIND 1" >>confdefs.h
77670
77671    ac_cv_func_res_search=yes
77672  else
77673
77674
77675  unset ac_cv_lib_socket_res_search
77676  unset ac_cv_lib_socket___res_search
77677  unset found
77678  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_search in -lsocket" >&5
77679printf %s "checking for res_search in -lsocket... " >&6; }
77680if test ${ac_cv_lib_socket_res_search+y}
77681then :
77682  printf %s "(cached) " >&6
77683else $as_nop
77684  ac_check_lib_save_LIBS=$LIBS
77685LIBS="-lsocket  $LIBS"
77686cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77687/* end confdefs.h.  */
77688
77689/* Override any GCC internal prototype to avoid an error.
77690   Use char because int might match the return type of a GCC
77691   builtin and then its argument prototype would still apply.  */
77692char res_search ();
77693int
77694main (void)
77695{
77696return res_search ();
77697  ;
77698  return 0;
77699}
77700_ACEOF
77701if ac_fn_c_try_link "$LINENO"
77702then :
77703  ac_cv_lib_socket_res_search=yes
77704else $as_nop
77705  ac_cv_lib_socket_res_search=no
77706fi
77707rm -f core conftest.err conftest.$ac_objext conftest.beam \
77708    conftest$ac_exeext conftest.$ac_ext
77709LIBS=$ac_check_lib_save_LIBS
77710fi
77711{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_res_search" >&5
77712printf "%s\n" "$ac_cv_lib_socket_res_search" >&6; }
77713if test "x$ac_cv_lib_socket_res_search" = xyes
77714then :
77715  found=yes
77716else $as_nop
77717
77718    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __res_search in -lsocket" >&5
77719printf %s "checking for __res_search in -lsocket... " >&6; }
77720if test ${ac_cv_lib_socket___res_search+y}
77721then :
77722  printf %s "(cached) " >&6
77723else $as_nop
77724  ac_check_lib_save_LIBS=$LIBS
77725LIBS="-lsocket  $LIBS"
77726cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77727/* end confdefs.h.  */
77728
77729/* Override any GCC internal prototype to avoid an error.
77730   Use char because int might match the return type of a GCC
77731   builtin and then its argument prototype would still apply.  */
77732char __res_search ();
77733int
77734main (void)
77735{
77736return __res_search ();
77737  ;
77738  return 0;
77739}
77740_ACEOF
77741if ac_fn_c_try_link "$LINENO"
77742then :
77743  ac_cv_lib_socket___res_search=yes
77744else $as_nop
77745  ac_cv_lib_socket___res_search=no
77746fi
77747rm -f core conftest.err conftest.$ac_objext conftest.beam \
77748    conftest$ac_exeext conftest.$ac_ext
77749LIBS=$ac_check_lib_save_LIBS
77750fi
77751{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket___res_search" >&5
77752printf "%s\n" "$ac_cv_lib_socket___res_search" >&6; }
77753if test "x$ac_cv_lib_socket___res_search" = xyes
77754then :
77755  found=yes
77756else $as_nop
77757  found=no
77758fi
77759
77760
77761fi
77762
77763
77764  if test "$found" = "yes"; then
77765    ac_libs=$LIBS
77766    LIBS="$LIBS -lsocket"
77767    if test "$cross_compiling" = yes
77768then :
77769
77770            found=yes
77771
77772else $as_nop
77773  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77774/* end confdefs.h.  */
77775int main() { return (0); }
77776_ACEOF
77777if ac_fn_c_try_run "$LINENO"
77778then :
77779  found=yes
77780else $as_nop
77781  found=no
77782fi
77783rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
77784  conftest.$ac_objext conftest.beam conftest.$ac_ext
77785fi
77786
77787    LIBS=$ac_libs
77788  fi
77789
77790  if test "$found" = "yes"; then
77791
77792
77793  case socket in
77794  c|c_r) ;;
77795  *)
77796      LIBS="-lsocket $LIBS"
77797   ;;
77798  esac
77799
77800
77801
77802printf "%s\n" "#define HAVE_RES_SEARCH 1" >>confdefs.h
77803
77804
77805printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
77806
77807    ac_cv_func_res_search=yes
77808  else
77809
77810  :
77811
77812  fi
77813
77814
77815  fi
77816
77817
77818  fi
77819
77820 ;;
77821
77822  esac
77823
77824
77825{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether strptime() declaration fails" >&5
77826printf %s "checking whether strptime() declaration fails... " >&6; }
77827if test ${ac_cv_strptime_decl_fails+y}
77828then :
77829  printf %s "(cached) " >&6
77830else $as_nop
77831
77832cat confdefs.h - <<_ACEOF >conftest.$ac_ext
77833/* end confdefs.h.  */
77834
77835#include <time.h>
77836
77837int
77838main (void)
77839{
77840
77841#ifndef HAVE_STRPTIME
77842#error no strptime() on this platform
77843#else
77844/* use invalid strptime() declaration to see if it fails to compile */
77845int strptime(const char *s, const char *format, struct tm *tm);
77846#endif
77847
77848  ;
77849  return 0;
77850}
77851_ACEOF
77852if ac_fn_c_try_compile "$LINENO"
77853then :
77854
77855  ac_cv_strptime_decl_fails=no
77856
77857else $as_nop
77858
77859  ac_cv_strptime_decl_fails=yes
77860
77861fi
77862rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
77863fi
77864{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_strptime_decl_fails" >&5
77865printf "%s\n" "$ac_cv_strptime_decl_fails" >&6; }
77866if test "$ac_cv_strptime_decl_fails" = "yes"; then
77867
77868printf "%s\n" "#define HAVE_STRPTIME_DECL_FAILS 1" >>confdefs.h
77869
77870fi
77871
77872ac_fn_check_decl "$LINENO" "arc4random_buf" "ac_cv_have_decl_arc4random_buf" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
77873if test "x$ac_cv_have_decl_arc4random_buf" = xyes
77874then :
77875  ac_have_decl=1
77876else $as_nop
77877  ac_have_decl=0
77878fi
77879printf "%s\n" "#define HAVE_DECL_ARC4RANDOM_BUF $ac_have_decl" >>confdefs.h
77880
77881
77882
77883php_with_password_argon2=no
77884
77885{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Argon2 support" >&5
77886printf %s "checking for Argon2 support... " >&6; }
77887
77888# Check whether --with-password-argon2 was given.
77889if test ${with_password_argon2+y}
77890then :
77891  withval=$with_password_argon2; PHP_PASSWORD_ARGON2=$withval
77892else $as_nop
77893
77894  PHP_PASSWORD_ARGON2=no
77895  test "$PHP_ENABLE_ALL" && PHP_PASSWORD_ARGON2=$PHP_ENABLE_ALL
77896
77897fi
77898
77899
77900
77901ext_output="yes, shared"
77902ext_shared=yes
77903case $PHP_PASSWORD_ARGON2 in
77904shared,*)
77905  PHP_PASSWORD_ARGON2=`echo "$PHP_PASSWORD_ARGON2"|$SED 's/^shared,//'`
77906  ;;
77907shared)
77908  PHP_PASSWORD_ARGON2=yes
77909  ;;
77910no)
77911  ext_output=no
77912  ext_shared=no
77913  ;;
77914*)
77915  ext_output=yes
77916  ext_shared=no
77917  ;;
77918esac
77919
77920
77921
77922{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
77923printf "%s\n" "$ext_output" >&6; }
77924
77925
77926
77927
77928if test "$PHP_PASSWORD_ARGON2" != "no"; then
77929
77930pkg_failed=no
77931{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libargon2" >&5
77932printf %s "checking for libargon2... " >&6; }
77933
77934if test -n "$ARGON2_CFLAGS"; then
77935    pkg_cv_ARGON2_CFLAGS="$ARGON2_CFLAGS"
77936 elif test -n "$PKG_CONFIG"; then
77937    if test -n "$PKG_CONFIG" && \
77938    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libargon2\""; } >&5
77939  ($PKG_CONFIG --exists --print-errors "libargon2") 2>&5
77940  ac_status=$?
77941  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
77942  test $ac_status = 0; }; then
77943  pkg_cv_ARGON2_CFLAGS=`$PKG_CONFIG --cflags "libargon2" 2>/dev/null`
77944		      test "x$?" != "x0" && pkg_failed=yes
77945else
77946  pkg_failed=yes
77947fi
77948 else
77949    pkg_failed=untried
77950fi
77951if test -n "$ARGON2_LIBS"; then
77952    pkg_cv_ARGON2_LIBS="$ARGON2_LIBS"
77953 elif test -n "$PKG_CONFIG"; then
77954    if test -n "$PKG_CONFIG" && \
77955    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libargon2\""; } >&5
77956  ($PKG_CONFIG --exists --print-errors "libargon2") 2>&5
77957  ac_status=$?
77958  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
77959  test $ac_status = 0; }; then
77960  pkg_cv_ARGON2_LIBS=`$PKG_CONFIG --libs "libargon2" 2>/dev/null`
77961		      test "x$?" != "x0" && pkg_failed=yes
77962else
77963  pkg_failed=yes
77964fi
77965 else
77966    pkg_failed=untried
77967fi
77968
77969
77970
77971if test $pkg_failed = yes; then
77972        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
77973printf "%s\n" "no" >&6; }
77974
77975if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
77976        _pkg_short_errors_supported=yes
77977else
77978        _pkg_short_errors_supported=no
77979fi
77980        if test $_pkg_short_errors_supported = yes; then
77981	        ARGON2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libargon2" 2>&1`
77982        else
77983	        ARGON2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libargon2" 2>&1`
77984        fi
77985	# Put the nasty error message in config.log where it belongs
77986	echo "$ARGON2_PKG_ERRORS" >&5
77987
77988	as_fn_error $? "Package requirements (libargon2) were not met:
77989
77990$ARGON2_PKG_ERRORS
77991
77992Consider adjusting the PKG_CONFIG_PATH environment variable if you
77993installed software in a non-standard prefix.
77994
77995Alternatively, you may set the environment variables ARGON2_CFLAGS
77996and ARGON2_LIBS to avoid the need to call pkg-config.
77997See the pkg-config man page for more details." "$LINENO" 5
77998elif test $pkg_failed = untried; then
77999        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
78000printf "%s\n" "no" >&6; }
78001	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
78002printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
78003as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
78004is in your PATH or set the PKG_CONFIG environment variable to the full
78005path to pkg-config.
78006
78007Alternatively, you may set the environment variables ARGON2_CFLAGS
78008and ARGON2_LIBS to avoid the need to call pkg-config.
78009See the pkg-config man page for more details.
78010
78011To get pkg-config, see <http://pkg-config.freedesktop.org/>.
78012See \`config.log' for more details" "$LINENO" 5; }
78013else
78014	ARGON2_CFLAGS=$pkg_cv_ARGON2_CFLAGS
78015	ARGON2_LIBS=$pkg_cv_ARGON2_LIBS
78016        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
78017printf "%s\n" "yes" >&6; }
78018
78019fi
78020
78021  for ac_i in $ARGON2_CFLAGS; do
78022    case $ac_i in
78023    -I*)
78024      ac_ii=`echo $ac_i|cut -c 3-`
78025
78026  if test "$ac_ii" != "/usr/include"; then
78027
78028  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
78029    ai_p=$ac_ii
78030  else
78031
78032    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
78033
78034    ep_realdir=`(cd "$ep_dir" && pwd)`
78035    ai_p="$ep_realdir"/`basename "$ac_ii"`
78036  fi
78037
78038
78039
78040  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
78041
78042  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
78043  if test -n "$unique" && test "`eval $cmd`" = "" ; then
78044    eval "INCLUDEPATH$unique=set"
78045
78046      if test ""; then
78047        INCLUDES="-I$ai_p $INCLUDES"
78048      else
78049        INCLUDES="$INCLUDES -I$ai_p"
78050      fi
78051
78052  fi
78053
78054  fi
78055
78056    ;;
78057    esac
78058  done
78059
78060
78061  for ac_i in $ARGON2_LIBS; do
78062    case $ac_i in
78063    -pthread)
78064      if test "$ext_shared" = "yes"; then
78065        ="$ -pthread"
78066      else
78067
78068
78069  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
78070
78071  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
78072  if test -n "$unique" && test "`eval $cmd`" = "" ; then
78073    eval "EXTRA_LDFLAGS$unique=set"
78074    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
78075  fi
78076
78077
78078
78079  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
78080
78081  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
78082  if test -n "$unique" && test "`eval $cmd`" = "" ; then
78083    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
78084    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
78085  fi
78086
78087      fi
78088    ;;
78089    -l*)
78090      ac_ii=`echo $ac_i|cut -c 3-`
78091
78092
78093  case $ac_ii in
78094  c|c_r) ;;
78095  *)
78096      LIBS="$LIBS -l$ac_ii"
78097   ;;
78098  esac
78099
78100
78101    ;;
78102    -L*)
78103      ac_ii=`echo $ac_i|cut -c 3-`
78104
78105  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
78106
78107  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
78108    ai_p=$ac_ii
78109  else
78110
78111    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
78112
78113    ep_realdir=`(cd "$ep_dir" && pwd)`
78114    ai_p="$ep_realdir"/`basename "$ac_ii"`
78115  fi
78116
78117
78118
78119
78120
78121  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
78122
78123  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
78124  if test -n "$unique" && test "`eval $cmd`" = "" ; then
78125    eval "LIBPATH$unique=set"
78126
78127    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
78128    LDFLAGS="$LDFLAGS -L$ai_p"
78129    PHP_RPATHS="$PHP_RPATHS $ai_p"
78130
78131  fi
78132
78133
78134
78135  fi
78136
78137    ;;
78138    esac
78139  done
78140
78141
78142
78143printf "%s\n" "#define HAVE_ARGON2LIB 1" >>confdefs.h
78144
78145fi
78146
78147ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
78148  #ifdef HAVE_SYS_SOCKET_H
78149  #include <sys/socket.h>
78150  #endif
78151  #include <net/if.h>
78152
78153"
78154if test "x$ac_cv_header_net_if_h" = xyes
78155then :
78156  printf "%s\n" "#define HAVE_NET_IF_H 1" >>confdefs.h
78157
78158fi
78159
78160{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable getifaddrs" >&5
78161printf %s "checking for usable getifaddrs... " >&6; }
78162cat confdefs.h - <<_ACEOF >conftest.$ac_ext
78163/* end confdefs.h.  */
78164
78165  #include <sys/types.h>
78166  #include <ifaddrs.h>
78167
78168int
78169main (void)
78170{
78171
78172  struct ifaddrs *interfaces;
78173  if (!getifaddrs(&interfaces)) {
78174      freeifaddrs(interfaces);
78175  }
78176
78177  ;
78178  return 0;
78179}
78180_ACEOF
78181if ac_fn_c_try_link "$LINENO"
78182then :
78183  ac_have_getifaddrs=yes
78184else $as_nop
78185  ac_have_getifaddrs=no
78186fi
78187rm -f core conftest.err conftest.$ac_objext conftest.beam \
78188    conftest$ac_exeext conftest.$ac_ext
78189if test "$ac_have_getifaddrs" = "yes" ; then
78190
78191printf "%s\n" "#define HAVE_GETIFADDRS 1" >>confdefs.h
78192
78193  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
78194printf "%s\n" "yes" >&6; }
78195else
78196  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
78197printf "%s\n" "no" >&6; }
78198fi
78199
78200
78201  ext_builddir=ext/standard
78202  ext_srcdir=$abs_srcdir/ext/standard
78203  ext_dir=ext/standard
78204
78205  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
78206
78207  if test "" != "shared" && test "" != "yes" && test "" != "cli"; then
78208    PHP_STANDARD_SHARED=no
78209
78210
78211  case $ext_dir in
78212  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78213  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78214  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78215  esac
78216
78217
78218
78219  b_c_pre=$php_c_pre
78220  b_cxx_pre=$php_cxx_pre
78221  b_c_meta=$php_c_meta
78222  b_cxx_meta=$php_cxx_meta
78223  b_c_post=$php_c_post
78224  b_cxx_post=$php_cxx_post
78225  b_lo=$php_lo
78226
78227
78228  old_IFS=$IFS
78229  for ac_src in array.c base64.c basic_functions.c browscap.c crc32.c crypt.c \
78230                            datetime.c dir.c dl.c dns.c exec.c file.c filestat.c \
78231                            flock_compat.c formatted_print.c fsock.c head.c html.c image.c \
78232                            info.c iptc.c lcg.c link.c mail.c math.c md5.c metaphone.c \
78233                            microtime.c pack.c pageinfo.c quot_print.c rand.c mt_rand.c \
78234                            soundex.c string.c scanf.c syslog.c type.c uniqid.c url.c \
78235                            var.c versioning.c assert.c strnatcmp.c levenshtein.c \
78236                            incomplete_class.c url_scanner_ex.c ftp_fopen_wrapper.c \
78237                            http_fopen_wrapper.c php_fopen_wrapper.c credits.c css.c \
78238                            var_unserializer.c ftok.c sha1.c user_filters.c uuencode.c \
78239                            filters.c proc_open.c streamsfuncs.c http.c password.c \
78240                            random.c net.c hrtime.c crc32_x86.c; do
78241
78242      IFS=.
78243      set $ac_src
78244      ac_obj=$1
78245      IFS=$old_IFS
78246
78247      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78248
78249      case $ac_src in
78250        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78251        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78252        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78253        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78254      esac
78255
78256      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78257
78258    cat >>Makefile.objects<<EOF
78259-include $ac_bdir$ac_obj.dep
78260$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78261	$ac_comp
78262EOF
78263  done
78264
78265
78266    EXT_STATIC="$EXT_STATIC standard;$ext_dir"
78267    if test "" != "nocli"; then
78268      EXT_CLI_STATIC="$EXT_CLI_STATIC standard;$ext_dir"
78269    fi
78270  else
78271    if test "" = "shared" || test "" = "yes"; then
78272      PHP_STANDARD_SHARED=yes
78273
78274  case $ext_dir in
78275  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78276  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78277  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78278  esac
78279
78280
78281
78282  b_c_pre=$shared_c_pre
78283  b_cxx_pre=$shared_cxx_pre
78284  b_c_meta=$shared_c_meta
78285  b_cxx_meta=$shared_cxx_meta
78286  b_c_post=$shared_c_post
78287  b_cxx_post=$shared_cxx_post
78288  b_lo=$shared_lo
78289
78290
78291  old_IFS=$IFS
78292  for ac_src in array.c base64.c basic_functions.c browscap.c crc32.c crypt.c \
78293                            datetime.c dir.c dl.c dns.c exec.c file.c filestat.c \
78294                            flock_compat.c formatted_print.c fsock.c head.c html.c image.c \
78295                            info.c iptc.c lcg.c link.c mail.c math.c md5.c metaphone.c \
78296                            microtime.c pack.c pageinfo.c quot_print.c rand.c mt_rand.c \
78297                            soundex.c string.c scanf.c syslog.c type.c uniqid.c url.c \
78298                            var.c versioning.c assert.c strnatcmp.c levenshtein.c \
78299                            incomplete_class.c url_scanner_ex.c ftp_fopen_wrapper.c \
78300                            http_fopen_wrapper.c php_fopen_wrapper.c credits.c css.c \
78301                            var_unserializer.c ftok.c sha1.c user_filters.c uuencode.c \
78302                            filters.c proc_open.c streamsfuncs.c http.c password.c \
78303                            random.c net.c hrtime.c crc32_x86.c; do
78304
78305      IFS=.
78306      set $ac_src
78307      ac_obj=$1
78308      IFS=$old_IFS
78309
78310      shared_objects_standard="$shared_objects_standard $ac_bdir$ac_obj.lo"
78311
78312      case $ac_src in
78313        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78314        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78315        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78316        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78317      esac
78318
78319      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78320
78321    cat >>Makefile.objects<<EOF
78322-include $ac_bdir$ac_obj.dep
78323$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78324	$ac_comp
78325EOF
78326  done
78327
78328
78329  install_modules="install-modules"
78330  suffix=la
78331
78332  case $host_alias in
78333    *aix*)
78334      additional_flags="-Wl,-G"
78335      ;;
78336  esac
78337
78338  if test "x" = "xyes"; then
78339    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/standard.$suffix"
78340  else
78341    PHP_MODULES="$PHP_MODULES \$(phplibdir)/standard.$suffix"
78342  fi
78343
78344  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_standard"
78345
78346  cat >>Makefile.objects<<EOF
78347\$(phplibdir)/standard.$suffix: $ext_builddir/standard.$suffix
78348	\$(LIBTOOL) --mode=install cp $ext_builddir/standard.$suffix \$(phplibdir)
78349
78350$ext_builddir/standard.$suffix: \$(shared_objects_standard) \$(STANDARD_SHARED_DEPENDENCIES)
78351	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_standard) \$(STANDARD_SHARED_LIBADD)
78352
78353EOF
78354
78355
78356printf "%s\n" "#define COMPILE_DL_STANDARD 1" >>confdefs.h
78357
78358    fi
78359  fi
78360
78361  if test "" != "shared" && test "" != "yes" && test "" = "cli"; then
78362    PHP_STANDARD_SHARED=no
78363    case "$PHP_SAPI" in
78364      cgi|embed|phpdbg)
78365
78366
78367  case $ext_dir in
78368  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78369  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78370  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78371  esac
78372
78373
78374
78375  b_c_pre=$php_c_pre
78376  b_cxx_pre=$php_cxx_pre
78377  b_c_meta=$php_c_meta
78378  b_cxx_meta=$php_cxx_meta
78379  b_c_post=$php_c_post
78380  b_cxx_post=$php_cxx_post
78381  b_lo=$php_lo
78382
78383
78384  old_IFS=$IFS
78385  for ac_src in array.c base64.c basic_functions.c browscap.c crc32.c crypt.c \
78386                            datetime.c dir.c dl.c dns.c exec.c file.c filestat.c \
78387                            flock_compat.c formatted_print.c fsock.c head.c html.c image.c \
78388                            info.c iptc.c lcg.c link.c mail.c math.c md5.c metaphone.c \
78389                            microtime.c pack.c pageinfo.c quot_print.c rand.c mt_rand.c \
78390                            soundex.c string.c scanf.c syslog.c type.c uniqid.c url.c \
78391                            var.c versioning.c assert.c strnatcmp.c levenshtein.c \
78392                            incomplete_class.c url_scanner_ex.c ftp_fopen_wrapper.c \
78393                            http_fopen_wrapper.c php_fopen_wrapper.c credits.c css.c \
78394                            var_unserializer.c ftok.c sha1.c user_filters.c uuencode.c \
78395                            filters.c proc_open.c streamsfuncs.c http.c password.c \
78396                            random.c net.c hrtime.c crc32_x86.c; do
78397
78398      IFS=.
78399      set $ac_src
78400      ac_obj=$1
78401      IFS=$old_IFS
78402
78403      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78404
78405      case $ac_src in
78406        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78407        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78408        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78409        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78410      esac
78411
78412      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78413
78414    cat >>Makefile.objects<<EOF
78415-include $ac_bdir$ac_obj.dep
78416$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78417	$ac_comp
78418EOF
78419  done
78420
78421
78422        EXT_STATIC="$EXT_STATIC standard;$ext_dir"
78423        ;;
78424      *)
78425
78426
78427  case $ext_dir in
78428  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78429  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78430  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78431  esac
78432
78433
78434
78435  b_c_pre=$php_c_pre
78436  b_cxx_pre=$php_cxx_pre
78437  b_c_meta=$php_c_meta
78438  b_cxx_meta=$php_cxx_meta
78439  b_c_post=$php_c_post
78440  b_cxx_post=$php_cxx_post
78441  b_lo=$php_lo
78442
78443
78444  old_IFS=$IFS
78445  for ac_src in array.c base64.c basic_functions.c browscap.c crc32.c crypt.c \
78446                            datetime.c dir.c dl.c dns.c exec.c file.c filestat.c \
78447                            flock_compat.c formatted_print.c fsock.c head.c html.c image.c \
78448                            info.c iptc.c lcg.c link.c mail.c math.c md5.c metaphone.c \
78449                            microtime.c pack.c pageinfo.c quot_print.c rand.c mt_rand.c \
78450                            soundex.c string.c scanf.c syslog.c type.c uniqid.c url.c \
78451                            var.c versioning.c assert.c strnatcmp.c levenshtein.c \
78452                            incomplete_class.c url_scanner_ex.c ftp_fopen_wrapper.c \
78453                            http_fopen_wrapper.c php_fopen_wrapper.c credits.c css.c \
78454                            var_unserializer.c ftok.c sha1.c user_filters.c uuencode.c \
78455                            filters.c proc_open.c streamsfuncs.c http.c password.c \
78456                            random.c net.c hrtime.c crc32_x86.c; do
78457
78458      IFS=.
78459      set $ac_src
78460      ac_obj=$1
78461      IFS=$old_IFS
78462
78463      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78464
78465      case $ac_src in
78466        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78467        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78468        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78469        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78470      esac
78471
78472      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78473
78474    cat >>Makefile.objects<<EOF
78475-include $ac_bdir$ac_obj.dep
78476$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78477	$ac_comp
78478EOF
78479  done
78480
78481
78482        ;;
78483    esac
78484    EXT_CLI_STATIC="$EXT_CLI_STATIC standard;$ext_dir"
78485  fi
78486
78487
78488    BUILD_DIR="$BUILD_DIR $ext_builddir"
78489
78490
78491
78492  if test "$ext_builddir" = "."; then
78493    PHP_PECL_EXTENSION=standard
78494
78495  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
78496
78497  fi
78498
78499
78500
78501  src=$ext_srcdir/Makefile.frag
78502  ac_srcdir=$ext_srcdir
78503  ac_builddir=$ext_builddir
78504  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
78505
78506
78507
78508    for header_file in ext/standard/; do
78509
78510
78511  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
78512
78513  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
78514  if test -n "$unique" && test "`eval $cmd`" = "" ; then
78515    eval "INSTALLHEADERS$unique=set"
78516
78517        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
78518
78519  fi
78520
78521    done
78522
78523
78524
78525
78526
78527
78528
78529php_enable_sysvmsg=no
78530
78531{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable System V IPC support" >&5
78532printf %s "checking whether to enable System V IPC support... " >&6; }
78533# Check whether --enable-sysvmsg was given.
78534if test ${enable_sysvmsg+y}
78535then :
78536  enableval=$enable_sysvmsg; PHP_SYSVMSG=$enableval
78537else $as_nop
78538
78539  PHP_SYSVMSG=no
78540  test "$PHP_ENABLE_ALL" && PHP_SYSVMSG=$PHP_ENABLE_ALL
78541
78542fi
78543
78544
78545
78546ext_output="yes, shared"
78547ext_shared=yes
78548case $PHP_SYSVMSG in
78549shared,*)
78550  PHP_SYSVMSG=`echo "$PHP_SYSVMSG"|$SED 's/^shared,//'`
78551  ;;
78552shared)
78553  PHP_SYSVMSG=yes
78554  ;;
78555no)
78556  ext_output=no
78557  ext_shared=no
78558  ;;
78559*)
78560  ext_output=yes
78561  ext_shared=no
78562  ;;
78563esac
78564
78565
78566
78567{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
78568printf "%s\n" "$ext_output" >&6; }
78569
78570
78571
78572
78573if test "$PHP_SYSVMSG" != "no"; then
78574  ac_fn_c_check_header_compile "$LINENO" "sys/msg.h" "ac_cv_header_sys_msg_h" "$ac_includes_default"
78575if test "x$ac_cv_header_sys_msg_h" = xyes
78576then :
78577
78578else $as_nop
78579  as_fn_error $? "Cannot enable System V IPC support, sys/msg.h is missing" "$LINENO" 5
78580
78581fi
78582
78583
78584
78585printf "%s\n" "#define HAVE_SYSVMSG 1" >>confdefs.h
78586
78587
78588  ext_builddir=ext/sysvmsg
78589  ext_srcdir=$abs_srcdir/ext/sysvmsg
78590  ext_dir=ext/sysvmsg
78591
78592  ac_extra=
78593
78594  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
78595    PHP_SYSVMSG_SHARED=no
78596
78597
78598  case $ext_dir in
78599  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78600  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78601  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78602  esac
78603
78604
78605
78606  b_c_pre=$php_c_pre
78607  b_cxx_pre=$php_cxx_pre
78608  b_c_meta=$php_c_meta
78609  b_cxx_meta=$php_cxx_meta
78610  b_c_post=$php_c_post
78611  b_cxx_post=$php_cxx_post
78612  b_lo=$php_lo
78613
78614
78615  old_IFS=$IFS
78616  for ac_src in sysvmsg.c; do
78617
78618      IFS=.
78619      set $ac_src
78620      ac_obj=$1
78621      IFS=$old_IFS
78622
78623      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78624
78625      case $ac_src in
78626        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78627        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78628        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78629        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78630      esac
78631
78632      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78633
78634    cat >>Makefile.objects<<EOF
78635-include $ac_bdir$ac_obj.dep
78636$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78637	$ac_comp
78638EOF
78639  done
78640
78641
78642    EXT_STATIC="$EXT_STATIC sysvmsg;$ext_dir"
78643    if test "$ext_shared" != "nocli"; then
78644      EXT_CLI_STATIC="$EXT_CLI_STATIC sysvmsg;$ext_dir"
78645    fi
78646  else
78647    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
78648      PHP_SYSVMSG_SHARED=yes
78649
78650  case $ext_dir in
78651  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78652  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78653  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78654  esac
78655
78656
78657
78658  b_c_pre=$shared_c_pre
78659  b_cxx_pre=$shared_cxx_pre
78660  b_c_meta=$shared_c_meta
78661  b_cxx_meta=$shared_cxx_meta
78662  b_c_post=$shared_c_post
78663  b_cxx_post=$shared_cxx_post
78664  b_lo=$shared_lo
78665
78666
78667  old_IFS=$IFS
78668  for ac_src in sysvmsg.c; do
78669
78670      IFS=.
78671      set $ac_src
78672      ac_obj=$1
78673      IFS=$old_IFS
78674
78675      shared_objects_sysvmsg="$shared_objects_sysvmsg $ac_bdir$ac_obj.lo"
78676
78677      case $ac_src in
78678        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78679        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78680        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78681        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78682      esac
78683
78684      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78685
78686    cat >>Makefile.objects<<EOF
78687-include $ac_bdir$ac_obj.dep
78688$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78689	$ac_comp
78690EOF
78691  done
78692
78693
78694  install_modules="install-modules"
78695  suffix=la
78696
78697  case $host_alias in
78698    *aix*)
78699      additional_flags="-Wl,-G"
78700      ;;
78701  esac
78702
78703  if test "x" = "xyes"; then
78704    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sysvmsg.$suffix"
78705  else
78706    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sysvmsg.$suffix"
78707  fi
78708
78709  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sysvmsg"
78710
78711  cat >>Makefile.objects<<EOF
78712\$(phplibdir)/sysvmsg.$suffix: $ext_builddir/sysvmsg.$suffix
78713	\$(LIBTOOL) --mode=install cp $ext_builddir/sysvmsg.$suffix \$(phplibdir)
78714
78715$ext_builddir/sysvmsg.$suffix: \$(shared_objects_sysvmsg) \$(SYSVMSG_SHARED_DEPENDENCIES)
78716	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sysvmsg) \$(SYSVMSG_SHARED_LIBADD)
78717
78718EOF
78719
78720
78721printf "%s\n" "#define COMPILE_DL_SYSVMSG 1" >>confdefs.h
78722
78723    fi
78724  fi
78725
78726  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
78727    PHP_SYSVMSG_SHARED=no
78728    case "$PHP_SAPI" in
78729      cgi|embed|phpdbg)
78730
78731
78732  case $ext_dir in
78733  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78734  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78735  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78736  esac
78737
78738
78739
78740  b_c_pre=$php_c_pre
78741  b_cxx_pre=$php_cxx_pre
78742  b_c_meta=$php_c_meta
78743  b_cxx_meta=$php_cxx_meta
78744  b_c_post=$php_c_post
78745  b_cxx_post=$php_cxx_post
78746  b_lo=$php_lo
78747
78748
78749  old_IFS=$IFS
78750  for ac_src in sysvmsg.c; do
78751
78752      IFS=.
78753      set $ac_src
78754      ac_obj=$1
78755      IFS=$old_IFS
78756
78757      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78758
78759      case $ac_src in
78760        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78761        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78762        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78763        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78764      esac
78765
78766      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78767
78768    cat >>Makefile.objects<<EOF
78769-include $ac_bdir$ac_obj.dep
78770$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78771	$ac_comp
78772EOF
78773  done
78774
78775
78776        EXT_STATIC="$EXT_STATIC sysvmsg;$ext_dir"
78777        ;;
78778      *)
78779
78780
78781  case $ext_dir in
78782  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78783  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78784  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78785  esac
78786
78787
78788
78789  b_c_pre=$php_c_pre
78790  b_cxx_pre=$php_cxx_pre
78791  b_c_meta=$php_c_meta
78792  b_cxx_meta=$php_cxx_meta
78793  b_c_post=$php_c_post
78794  b_cxx_post=$php_cxx_post
78795  b_lo=$php_lo
78796
78797
78798  old_IFS=$IFS
78799  for ac_src in sysvmsg.c; do
78800
78801      IFS=.
78802      set $ac_src
78803      ac_obj=$1
78804      IFS=$old_IFS
78805
78806      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78807
78808      case $ac_src in
78809        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78810        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78811        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78812        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78813      esac
78814
78815      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78816
78817    cat >>Makefile.objects<<EOF
78818-include $ac_bdir$ac_obj.dep
78819$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78820	$ac_comp
78821EOF
78822  done
78823
78824
78825        ;;
78826    esac
78827    EXT_CLI_STATIC="$EXT_CLI_STATIC sysvmsg;$ext_dir"
78828  fi
78829
78830
78831    BUILD_DIR="$BUILD_DIR $ext_builddir"
78832
78833
78834
78835  if test "$ext_builddir" = "."; then
78836    PHP_PECL_EXTENSION=sysvmsg
78837
78838  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
78839
78840  fi
78841
78842fi
78843
78844
78845
78846
78847
78848php_enable_sysvsem=no
78849
78850{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable System V semaphore support" >&5
78851printf %s "checking whether to enable System V semaphore support... " >&6; }
78852# Check whether --enable-sysvsem was given.
78853if test ${enable_sysvsem+y}
78854then :
78855  enableval=$enable_sysvsem; PHP_SYSVSEM=$enableval
78856else $as_nop
78857
78858  PHP_SYSVSEM=no
78859  test "$PHP_ENABLE_ALL" && PHP_SYSVSEM=$PHP_ENABLE_ALL
78860
78861fi
78862
78863
78864
78865ext_output="yes, shared"
78866ext_shared=yes
78867case $PHP_SYSVSEM in
78868shared,*)
78869  PHP_SYSVSEM=`echo "$PHP_SYSVSEM"|$SED 's/^shared,//'`
78870  ;;
78871shared)
78872  PHP_SYSVSEM=yes
78873  ;;
78874no)
78875  ext_output=no
78876  ext_shared=no
78877  ;;
78878*)
78879  ext_output=yes
78880  ext_shared=no
78881  ;;
78882esac
78883
78884
78885
78886{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
78887printf "%s\n" "$ext_output" >&6; }
78888
78889
78890
78891
78892if test "$PHP_SYSVSEM" != "no"; then
78893
78894  ext_builddir=ext/sysvsem
78895  ext_srcdir=$abs_srcdir/ext/sysvsem
78896  ext_dir=ext/sysvsem
78897
78898  ac_extra=
78899
78900  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
78901    PHP_SYSVSEM_SHARED=no
78902
78903
78904  case $ext_dir in
78905  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78906  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78907  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78908  esac
78909
78910
78911
78912  b_c_pre=$php_c_pre
78913  b_cxx_pre=$php_cxx_pre
78914  b_c_meta=$php_c_meta
78915  b_cxx_meta=$php_cxx_meta
78916  b_c_post=$php_c_post
78917  b_cxx_post=$php_cxx_post
78918  b_lo=$php_lo
78919
78920
78921  old_IFS=$IFS
78922  for ac_src in sysvsem.c; do
78923
78924      IFS=.
78925      set $ac_src
78926      ac_obj=$1
78927      IFS=$old_IFS
78928
78929      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
78930
78931      case $ac_src in
78932        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78933        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78934        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78935        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78936      esac
78937
78938      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78939
78940    cat >>Makefile.objects<<EOF
78941-include $ac_bdir$ac_obj.dep
78942$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78943	$ac_comp
78944EOF
78945  done
78946
78947
78948    EXT_STATIC="$EXT_STATIC sysvsem;$ext_dir"
78949    if test "$ext_shared" != "nocli"; then
78950      EXT_CLI_STATIC="$EXT_CLI_STATIC sysvsem;$ext_dir"
78951    fi
78952  else
78953    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
78954      PHP_SYSVSEM_SHARED=yes
78955
78956  case $ext_dir in
78957  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
78958  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
78959  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
78960  esac
78961
78962
78963
78964  b_c_pre=$shared_c_pre
78965  b_cxx_pre=$shared_cxx_pre
78966  b_c_meta=$shared_c_meta
78967  b_cxx_meta=$shared_cxx_meta
78968  b_c_post=$shared_c_post
78969  b_cxx_post=$shared_cxx_post
78970  b_lo=$shared_lo
78971
78972
78973  old_IFS=$IFS
78974  for ac_src in sysvsem.c; do
78975
78976      IFS=.
78977      set $ac_src
78978      ac_obj=$1
78979      IFS=$old_IFS
78980
78981      shared_objects_sysvsem="$shared_objects_sysvsem $ac_bdir$ac_obj.lo"
78982
78983      case $ac_src in
78984        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78985        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78986        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
78987        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
78988      esac
78989
78990      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
78991
78992    cat >>Makefile.objects<<EOF
78993-include $ac_bdir$ac_obj.dep
78994$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
78995	$ac_comp
78996EOF
78997  done
78998
78999
79000  install_modules="install-modules"
79001  suffix=la
79002
79003  case $host_alias in
79004    *aix*)
79005      additional_flags="-Wl,-G"
79006      ;;
79007  esac
79008
79009  if test "x" = "xyes"; then
79010    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sysvsem.$suffix"
79011  else
79012    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sysvsem.$suffix"
79013  fi
79014
79015  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sysvsem"
79016
79017  cat >>Makefile.objects<<EOF
79018\$(phplibdir)/sysvsem.$suffix: $ext_builddir/sysvsem.$suffix
79019	\$(LIBTOOL) --mode=install cp $ext_builddir/sysvsem.$suffix \$(phplibdir)
79020
79021$ext_builddir/sysvsem.$suffix: \$(shared_objects_sysvsem) \$(SYSVSEM_SHARED_DEPENDENCIES)
79022	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sysvsem) \$(SYSVSEM_SHARED_LIBADD)
79023
79024EOF
79025
79026
79027printf "%s\n" "#define COMPILE_DL_SYSVSEM 1" >>confdefs.h
79028
79029    fi
79030  fi
79031
79032  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
79033    PHP_SYSVSEM_SHARED=no
79034    case "$PHP_SAPI" in
79035      cgi|embed|phpdbg)
79036
79037
79038  case $ext_dir in
79039  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79040  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79041  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79042  esac
79043
79044
79045
79046  b_c_pre=$php_c_pre
79047  b_cxx_pre=$php_cxx_pre
79048  b_c_meta=$php_c_meta
79049  b_cxx_meta=$php_cxx_meta
79050  b_c_post=$php_c_post
79051  b_cxx_post=$php_cxx_post
79052  b_lo=$php_lo
79053
79054
79055  old_IFS=$IFS
79056  for ac_src in sysvsem.c; do
79057
79058      IFS=.
79059      set $ac_src
79060      ac_obj=$1
79061      IFS=$old_IFS
79062
79063      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
79064
79065      case $ac_src in
79066        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79067        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79068        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79069        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79070      esac
79071
79072      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79073
79074    cat >>Makefile.objects<<EOF
79075-include $ac_bdir$ac_obj.dep
79076$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79077	$ac_comp
79078EOF
79079  done
79080
79081
79082        EXT_STATIC="$EXT_STATIC sysvsem;$ext_dir"
79083        ;;
79084      *)
79085
79086
79087  case $ext_dir in
79088  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79089  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79090  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79091  esac
79092
79093
79094
79095  b_c_pre=$php_c_pre
79096  b_cxx_pre=$php_cxx_pre
79097  b_c_meta=$php_c_meta
79098  b_cxx_meta=$php_cxx_meta
79099  b_c_post=$php_c_post
79100  b_cxx_post=$php_cxx_post
79101  b_lo=$php_lo
79102
79103
79104  old_IFS=$IFS
79105  for ac_src in sysvsem.c; do
79106
79107      IFS=.
79108      set $ac_src
79109      ac_obj=$1
79110      IFS=$old_IFS
79111
79112      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
79113
79114      case $ac_src in
79115        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79116        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79117        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79118        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79119      esac
79120
79121      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79122
79123    cat >>Makefile.objects<<EOF
79124-include $ac_bdir$ac_obj.dep
79125$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79126	$ac_comp
79127EOF
79128  done
79129
79130
79131        ;;
79132    esac
79133    EXT_CLI_STATIC="$EXT_CLI_STATIC sysvsem;$ext_dir"
79134  fi
79135
79136
79137    BUILD_DIR="$BUILD_DIR $ext_builddir"
79138
79139
79140
79141  if test "$ext_builddir" = "."; then
79142    PHP_PECL_EXTENSION=sysvsem
79143
79144  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
79145
79146  fi
79147
79148
79149printf "%s\n" "#define HAVE_SYSVSEM 1" >>confdefs.h
79150
79151 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for union semun" >&5
79152printf %s "checking for union semun... " >&6; }
79153if test ${php_cv_semun+y}
79154then :
79155  printf %s "(cached) " >&6
79156else $as_nop
79157  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
79158/* end confdefs.h.  */
79159
79160#include <sys/types.h>
79161#include <sys/ipc.h>
79162#include <sys/sem.h>
79163
79164int
79165main (void)
79166{
79167union semun x;
79168  ;
79169  return 0;
79170}
79171_ACEOF
79172if ac_fn_c_try_compile "$LINENO"
79173then :
79174
79175     php_cv_semun=yes
79176
79177else $as_nop
79178
79179     php_cv_semun=no
79180
79181fi
79182rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
79183
79184fi
79185{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $php_cv_semun" >&5
79186printf "%s\n" "$php_cv_semun" >&6; }
79187 if test "$php_cv_semun" = "yes"; then
79188
79189printf "%s\n" "#define HAVE_SEMUN 1" >>confdefs.h
79190
79191 else
79192
79193printf "%s\n" "#define HAVE_SEMUN 0" >>confdefs.h
79194
79195 fi
79196fi
79197
79198
79199
79200
79201
79202php_enable_sysvshm=no
79203
79204{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable System V shared memory support" >&5
79205printf %s "checking whether to enable System V shared memory support... " >&6; }
79206# Check whether --enable-sysvshm was given.
79207if test ${enable_sysvshm+y}
79208then :
79209  enableval=$enable_sysvshm; PHP_SYSVSHM=$enableval
79210else $as_nop
79211
79212  PHP_SYSVSHM=no
79213  test "$PHP_ENABLE_ALL" && PHP_SYSVSHM=$PHP_ENABLE_ALL
79214
79215fi
79216
79217
79218
79219ext_output="yes, shared"
79220ext_shared=yes
79221case $PHP_SYSVSHM in
79222shared,*)
79223  PHP_SYSVSHM=`echo "$PHP_SYSVSHM"|$SED 's/^shared,//'`
79224  ;;
79225shared)
79226  PHP_SYSVSHM=yes
79227  ;;
79228no)
79229  ext_output=no
79230  ext_shared=no
79231  ;;
79232*)
79233  ext_output=yes
79234  ext_shared=no
79235  ;;
79236esac
79237
79238
79239
79240{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
79241printf "%s\n" "$ext_output" >&6; }
79242
79243
79244
79245
79246if test "$PHP_SYSVSHM" != "no"; then
79247
79248printf "%s\n" "#define HAVE_SYSVSHM 1" >>confdefs.h
79249
79250
79251  ext_builddir=ext/sysvshm
79252  ext_srcdir=$abs_srcdir/ext/sysvshm
79253  ext_dir=ext/sysvshm
79254
79255  ac_extra=
79256
79257  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
79258    PHP_SYSVSHM_SHARED=no
79259
79260
79261  case $ext_dir in
79262  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79263  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79264  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79265  esac
79266
79267
79268
79269  b_c_pre=$php_c_pre
79270  b_cxx_pre=$php_cxx_pre
79271  b_c_meta=$php_c_meta
79272  b_cxx_meta=$php_cxx_meta
79273  b_c_post=$php_c_post
79274  b_cxx_post=$php_cxx_post
79275  b_lo=$php_lo
79276
79277
79278  old_IFS=$IFS
79279  for ac_src in sysvshm.c; do
79280
79281      IFS=.
79282      set $ac_src
79283      ac_obj=$1
79284      IFS=$old_IFS
79285
79286      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
79287
79288      case $ac_src in
79289        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79290        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79291        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79292        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79293      esac
79294
79295      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79296
79297    cat >>Makefile.objects<<EOF
79298-include $ac_bdir$ac_obj.dep
79299$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79300	$ac_comp
79301EOF
79302  done
79303
79304
79305    EXT_STATIC="$EXT_STATIC sysvshm;$ext_dir"
79306    if test "$ext_shared" != "nocli"; then
79307      EXT_CLI_STATIC="$EXT_CLI_STATIC sysvshm;$ext_dir"
79308    fi
79309  else
79310    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
79311      PHP_SYSVSHM_SHARED=yes
79312
79313  case $ext_dir in
79314  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79315  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79316  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79317  esac
79318
79319
79320
79321  b_c_pre=$shared_c_pre
79322  b_cxx_pre=$shared_cxx_pre
79323  b_c_meta=$shared_c_meta
79324  b_cxx_meta=$shared_cxx_meta
79325  b_c_post=$shared_c_post
79326  b_cxx_post=$shared_cxx_post
79327  b_lo=$shared_lo
79328
79329
79330  old_IFS=$IFS
79331  for ac_src in sysvshm.c; do
79332
79333      IFS=.
79334      set $ac_src
79335      ac_obj=$1
79336      IFS=$old_IFS
79337
79338      shared_objects_sysvshm="$shared_objects_sysvshm $ac_bdir$ac_obj.lo"
79339
79340      case $ac_src in
79341        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79342        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79343        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79344        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79345      esac
79346
79347      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79348
79349    cat >>Makefile.objects<<EOF
79350-include $ac_bdir$ac_obj.dep
79351$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79352	$ac_comp
79353EOF
79354  done
79355
79356
79357  install_modules="install-modules"
79358  suffix=la
79359
79360  case $host_alias in
79361    *aix*)
79362      additional_flags="-Wl,-G"
79363      ;;
79364  esac
79365
79366  if test "x" = "xyes"; then
79367    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/sysvshm.$suffix"
79368  else
79369    PHP_MODULES="$PHP_MODULES \$(phplibdir)/sysvshm.$suffix"
79370  fi
79371
79372  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_sysvshm"
79373
79374  cat >>Makefile.objects<<EOF
79375\$(phplibdir)/sysvshm.$suffix: $ext_builddir/sysvshm.$suffix
79376	\$(LIBTOOL) --mode=install cp $ext_builddir/sysvshm.$suffix \$(phplibdir)
79377
79378$ext_builddir/sysvshm.$suffix: \$(shared_objects_sysvshm) \$(SYSVSHM_SHARED_DEPENDENCIES)
79379	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_sysvshm) \$(SYSVSHM_SHARED_LIBADD)
79380
79381EOF
79382
79383
79384printf "%s\n" "#define COMPILE_DL_SYSVSHM 1" >>confdefs.h
79385
79386    fi
79387  fi
79388
79389  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
79390    PHP_SYSVSHM_SHARED=no
79391    case "$PHP_SAPI" in
79392      cgi|embed|phpdbg)
79393
79394
79395  case $ext_dir in
79396  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79397  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79398  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79399  esac
79400
79401
79402
79403  b_c_pre=$php_c_pre
79404  b_cxx_pre=$php_cxx_pre
79405  b_c_meta=$php_c_meta
79406  b_cxx_meta=$php_cxx_meta
79407  b_c_post=$php_c_post
79408  b_cxx_post=$php_cxx_post
79409  b_lo=$php_lo
79410
79411
79412  old_IFS=$IFS
79413  for ac_src in sysvshm.c; do
79414
79415      IFS=.
79416      set $ac_src
79417      ac_obj=$1
79418      IFS=$old_IFS
79419
79420      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
79421
79422      case $ac_src in
79423        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79424        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79425        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79426        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79427      esac
79428
79429      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79430
79431    cat >>Makefile.objects<<EOF
79432-include $ac_bdir$ac_obj.dep
79433$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79434	$ac_comp
79435EOF
79436  done
79437
79438
79439        EXT_STATIC="$EXT_STATIC sysvshm;$ext_dir"
79440        ;;
79441      *)
79442
79443
79444  case $ext_dir in
79445  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
79446  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
79447  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
79448  esac
79449
79450
79451
79452  b_c_pre=$php_c_pre
79453  b_cxx_pre=$php_cxx_pre
79454  b_c_meta=$php_c_meta
79455  b_cxx_meta=$php_cxx_meta
79456  b_c_post=$php_c_post
79457  b_cxx_post=$php_cxx_post
79458  b_lo=$php_lo
79459
79460
79461  old_IFS=$IFS
79462  for ac_src in sysvshm.c; do
79463
79464      IFS=.
79465      set $ac_src
79466      ac_obj=$1
79467      IFS=$old_IFS
79468
79469      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
79470
79471      case $ac_src in
79472        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79473        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79474        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
79475        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
79476      esac
79477
79478      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
79479
79480    cat >>Makefile.objects<<EOF
79481-include $ac_bdir$ac_obj.dep
79482$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
79483	$ac_comp
79484EOF
79485  done
79486
79487
79488        ;;
79489    esac
79490    EXT_CLI_STATIC="$EXT_CLI_STATIC sysvshm;$ext_dir"
79491  fi
79492
79493
79494    BUILD_DIR="$BUILD_DIR $ext_builddir"
79495
79496
79497
79498  if test "$ext_builddir" = "."; then
79499    PHP_PECL_EXTENSION=sysvshm
79500
79501  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
79502
79503  fi
79504
79505fi
79506
79507
79508
79509
79510
79511php_with_tidy=no
79512
79513{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for TIDY support" >&5
79514printf %s "checking for TIDY support... " >&6; }
79515
79516# Check whether --with-tidy was given.
79517if test ${with_tidy+y}
79518then :
79519  withval=$with_tidy; PHP_TIDY=$withval
79520else $as_nop
79521
79522  PHP_TIDY=no
79523  test "$PHP_ENABLE_ALL" && PHP_TIDY=$PHP_ENABLE_ALL
79524
79525fi
79526
79527
79528
79529ext_output="yes, shared"
79530ext_shared=yes
79531case $PHP_TIDY in
79532shared,*)
79533  PHP_TIDY=`echo "$PHP_TIDY"|$SED 's/^shared,//'`
79534  ;;
79535shared)
79536  PHP_TIDY=yes
79537  ;;
79538no)
79539  ext_output=no
79540  ext_shared=no
79541  ;;
79542*)
79543  ext_output=yes
79544  ext_shared=no
79545  ;;
79546esac
79547
79548
79549
79550{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
79551printf "%s\n" "$ext_output" >&6; }
79552
79553
79554
79555
79556if test "$PHP_TIDY" != "no"; then
79557
79558  if test "$PHP_TIDY" != "yes"; then
79559    TIDY_SEARCH_DIRS=$PHP_TIDY
79560  else
79561    TIDY_SEARCH_DIRS="/usr/local /usr"
79562  fi
79563
79564  for i in $TIDY_SEARCH_DIRS; do
79565    for j in tidy tidyp; do
79566        if test -f $i/include/$j/$j.h; then
79567            TIDY_DIR=$i
79568            TIDY_INCDIR=$i/include/$j
79569            TIDY_LIB_NAME=$j
79570        break
79571        elif test -f $i/include/$j.h; then
79572            TIDY_DIR=$i
79573            TIDY_INCDIR=$i/include
79574            TIDY_LIB_NAME=$j
79575        break
79576        fi
79577    done
79578  done
79579
79580  if test -z "$TIDY_DIR"; then
79581    as_fn_error $? "Cannot find libtidy" "$LINENO" 5
79582  else
79583                if test -f "$TIDY_INCDIR/tidybuffio.h"; then
79584
79585printf "%s\n" "#define HAVE_TIDYBUFFIO_H 1" >>confdefs.h
79586
79587    fi
79588  fi
79589
79590  TIDY_LIBDIR=$TIDY_DIR/$PHP_LIBDIR
79591  if test "$TIDY_LIB_NAME" == 'tidyp'; then
79592
79593printf "%s\n" "#define HAVE_TIDYP_H 1" >>confdefs.h
79594
79595  else
79596
79597printf "%s\n" "#define HAVE_TIDY_H 1" >>confdefs.h
79598
79599  fi
79600
79601
79602
79603  save_old_LDFLAGS=$LDFLAGS
79604  ac_stuff=""
79605
79606  save_ext_shared=$ext_shared
79607  ext_shared=yes
79608
79609  for ac_i in $ac_stuff; do
79610    case $ac_i in
79611    -pthread)
79612      if test "$ext_shared" = "yes"; then
79613        LDFLAGS="$LDFLAGS -pthread"
79614      else
79615
79616
79617  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79618
79619  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
79620  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79621    eval "EXTRA_LDFLAGS$unique=set"
79622    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
79623  fi
79624
79625
79626
79627  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79628
79629  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
79630  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79631    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
79632    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
79633  fi
79634
79635      fi
79636    ;;
79637    -l*)
79638      ac_ii=`echo $ac_i|cut -c 3-`
79639
79640
79641  case $ac_ii in
79642  c|c_r) ;;
79643  *)
79644    if test "$ext_shared" = "yes"; then
79645        LDFLAGS="$LDFLAGS -l$ac_ii"
79646    else
79647
79648
79649  case $ac_ii in
79650  c|c_r) ;;
79651  *)
79652      LIBS="$LIBS -l$ac_ii"
79653   ;;
79654  esac
79655
79656
79657    fi
79658   ;;
79659  esac
79660
79661
79662    ;;
79663    -L*)
79664      ac_ii=`echo $ac_i|cut -c 3-`
79665
79666  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
79667
79668  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
79669    ai_p=$ac_ii
79670  else
79671
79672    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
79673
79674    ep_realdir=`(cd "$ep_dir" && pwd)`
79675    ai_p="$ep_realdir"/`basename "$ac_ii"`
79676  fi
79677
79678
79679      if test "$ext_shared" = "yes"; then
79680        LDFLAGS="-L$ai_p $LDFLAGS"
79681        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
79682      else
79683
79684
79685
79686  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
79687
79688  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
79689  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79690    eval "LIBPATH$unique=set"
79691
79692    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
79693    LDFLAGS="$LDFLAGS -L$ai_p"
79694    PHP_RPATHS="$PHP_RPATHS $ai_p"
79695
79696  fi
79697
79698
79699      fi
79700
79701  fi
79702
79703    ;;
79704    esac
79705  done
79706
79707  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$TIDY_LIB_NAME""_tidyOptGetDoc" | $as_tr_sh`
79708{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tidyOptGetDoc in -l$TIDY_LIB_NAME" >&5
79709printf %s "checking for tidyOptGetDoc in -l$TIDY_LIB_NAME... " >&6; }
79710if eval test \${$as_ac_Lib+y}
79711then :
79712  printf %s "(cached) " >&6
79713else $as_nop
79714  ac_check_lib_save_LIBS=$LIBS
79715LIBS="-l$TIDY_LIB_NAME  $LIBS"
79716cat confdefs.h - <<_ACEOF >conftest.$ac_ext
79717/* end confdefs.h.  */
79718
79719/* Override any GCC internal prototype to avoid an error.
79720   Use char because int might match the return type of a GCC
79721   builtin and then its argument prototype would still apply.  */
79722char tidyOptGetDoc ();
79723int
79724main (void)
79725{
79726return tidyOptGetDoc ();
79727  ;
79728  return 0;
79729}
79730_ACEOF
79731if ac_fn_c_try_link "$LINENO"
79732then :
79733  eval "$as_ac_Lib=yes"
79734else $as_nop
79735  eval "$as_ac_Lib=no"
79736fi
79737rm -f core conftest.err conftest.$ac_objext conftest.beam \
79738    conftest$ac_exeext conftest.$ac_ext
79739LIBS=$ac_check_lib_save_LIBS
79740fi
79741eval ac_res=\$$as_ac_Lib
79742	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
79743printf "%s\n" "$ac_res" >&6; }
79744if eval test \"x\$"$as_ac_Lib"\" = x"yes"
79745then :
79746
79747    LDFLAGS=$save_old_LDFLAGS
79748    ext_shared=$save_ext_shared
79749
79750
79751printf "%s\n" "#define HAVE_TIDYOPTGETDOC 1" >>confdefs.h
79752
79753
79754
79755else $as_nop
79756
79757    LDFLAGS=$save_old_LDFLAGS
79758    ext_shared=$save_ext_shared
79759    unset ac_cv_lib_$TIDY_LIB_NAME_tidyOptGetDoc
79760
79761
79762  save_old_LDFLAGS=$LDFLAGS
79763  ac_stuff=""
79764
79765  save_ext_shared=$ext_shared
79766  ext_shared=yes
79767
79768  for ac_i in $ac_stuff; do
79769    case $ac_i in
79770    -pthread)
79771      if test "$ext_shared" = "yes"; then
79772        LDFLAGS="$LDFLAGS -pthread"
79773      else
79774
79775
79776  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79777
79778  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
79779  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79780    eval "EXTRA_LDFLAGS$unique=set"
79781    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
79782  fi
79783
79784
79785
79786  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79787
79788  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
79789  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79790    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
79791    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
79792  fi
79793
79794      fi
79795    ;;
79796    -l*)
79797      ac_ii=`echo $ac_i|cut -c 3-`
79798
79799
79800  case $ac_ii in
79801  c|c_r) ;;
79802  *)
79803    if test "$ext_shared" = "yes"; then
79804        LDFLAGS="$LDFLAGS -l$ac_ii"
79805    else
79806
79807
79808  case $ac_ii in
79809  c|c_r) ;;
79810  *)
79811      LIBS="$LIBS -l$ac_ii"
79812   ;;
79813  esac
79814
79815
79816    fi
79817   ;;
79818  esac
79819
79820
79821    ;;
79822    -L*)
79823      ac_ii=`echo $ac_i|cut -c 3-`
79824
79825  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
79826
79827  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
79828    ai_p=$ac_ii
79829  else
79830
79831    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
79832
79833    ep_realdir=`(cd "$ep_dir" && pwd)`
79834    ai_p="$ep_realdir"/`basename "$ac_ii"`
79835  fi
79836
79837
79838      if test "$ext_shared" = "yes"; then
79839        LDFLAGS="-L$ai_p $LDFLAGS"
79840        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
79841      else
79842
79843
79844
79845  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
79846
79847  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
79848  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79849    eval "LIBPATH$unique=set"
79850
79851    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
79852    LDFLAGS="$LDFLAGS -L$ai_p"
79853    PHP_RPATHS="$PHP_RPATHS $ai_p"
79854
79855  fi
79856
79857
79858      fi
79859
79860  fi
79861
79862    ;;
79863    esac
79864  done
79865
79866  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tidyOptGetDoc in -ltidy5" >&5
79867printf %s "checking for tidyOptGetDoc in -ltidy5... " >&6; }
79868if test ${ac_cv_lib_tidy5_tidyOptGetDoc+y}
79869then :
79870  printf %s "(cached) " >&6
79871else $as_nop
79872  ac_check_lib_save_LIBS=$LIBS
79873LIBS="-ltidy5  $LIBS"
79874cat confdefs.h - <<_ACEOF >conftest.$ac_ext
79875/* end confdefs.h.  */
79876
79877/* Override any GCC internal prototype to avoid an error.
79878   Use char because int might match the return type of a GCC
79879   builtin and then its argument prototype would still apply.  */
79880char tidyOptGetDoc ();
79881int
79882main (void)
79883{
79884return tidyOptGetDoc ();
79885  ;
79886  return 0;
79887}
79888_ACEOF
79889if ac_fn_c_try_link "$LINENO"
79890then :
79891  ac_cv_lib_tidy5_tidyOptGetDoc=yes
79892else $as_nop
79893  ac_cv_lib_tidy5_tidyOptGetDoc=no
79894fi
79895rm -f core conftest.err conftest.$ac_objext conftest.beam \
79896    conftest$ac_exeext conftest.$ac_ext
79897LIBS=$ac_check_lib_save_LIBS
79898fi
79899{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tidy5_tidyOptGetDoc" >&5
79900printf "%s\n" "$ac_cv_lib_tidy5_tidyOptGetDoc" >&6; }
79901if test "x$ac_cv_lib_tidy5_tidyOptGetDoc" = xyes
79902then :
79903
79904    LDFLAGS=$save_old_LDFLAGS
79905    ext_shared=$save_ext_shared
79906
79907      TIDY_LIB_NAME=tidy5
79908
79909printf "%s\n" "#define HAVE_TIDYOPTGETDOC 1" >>confdefs.h
79910
79911
79912
79913else $as_nop
79914
79915    LDFLAGS=$save_old_LDFLAGS
79916    ext_shared=$save_ext_shared
79917    unset ac_cv_lib_tidy5_tidyOptGetDoc
79918
79919
79920fi
79921
79922
79923
79924fi
79925
79926
79927
79928  save_old_LDFLAGS=$LDFLAGS
79929  ac_stuff=""
79930
79931  save_ext_shared=$ext_shared
79932  ext_shared=yes
79933
79934  for ac_i in $ac_stuff; do
79935    case $ac_i in
79936    -pthread)
79937      if test "$ext_shared" = "yes"; then
79938        LDFLAGS="$LDFLAGS -pthread"
79939      else
79940
79941
79942  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79943
79944  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
79945  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79946    eval "EXTRA_LDFLAGS$unique=set"
79947    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
79948  fi
79949
79950
79951
79952  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
79953
79954  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
79955  if test -n "$unique" && test "`eval $cmd`" = "" ; then
79956    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
79957    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
79958  fi
79959
79960      fi
79961    ;;
79962    -l*)
79963      ac_ii=`echo $ac_i|cut -c 3-`
79964
79965
79966  case $ac_ii in
79967  c|c_r) ;;
79968  *)
79969    if test "$ext_shared" = "yes"; then
79970        LDFLAGS="$LDFLAGS -l$ac_ii"
79971    else
79972
79973
79974  case $ac_ii in
79975  c|c_r) ;;
79976  *)
79977      LIBS="$LIBS -l$ac_ii"
79978   ;;
79979  esac
79980
79981
79982    fi
79983   ;;
79984  esac
79985
79986
79987    ;;
79988    -L*)
79989      ac_ii=`echo $ac_i|cut -c 3-`
79990
79991  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
79992
79993  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
79994    ai_p=$ac_ii
79995  else
79996
79997    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
79998
79999    ep_realdir=`(cd "$ep_dir" && pwd)`
80000    ai_p="$ep_realdir"/`basename "$ac_ii"`
80001  fi
80002
80003
80004      if test "$ext_shared" = "yes"; then
80005        LDFLAGS="-L$ai_p $LDFLAGS"
80006        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
80007      else
80008
80009
80010
80011  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
80012
80013  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
80014  if test -n "$unique" && test "`eval $cmd`" = "" ; then
80015    eval "LIBPATH$unique=set"
80016
80017    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
80018    LDFLAGS="$LDFLAGS -L$ai_p"
80019    PHP_RPATHS="$PHP_RPATHS $ai_p"
80020
80021  fi
80022
80023
80024      fi
80025
80026  fi
80027
80028    ;;
80029    esac
80030  done
80031
80032  as_ac_Lib=`printf "%s\n" "ac_cv_lib_$TIDY_LIB_NAME""_tidyReleaseDate" | $as_tr_sh`
80033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tidyReleaseDate in -l$TIDY_LIB_NAME" >&5
80034printf %s "checking for tidyReleaseDate in -l$TIDY_LIB_NAME... " >&6; }
80035if eval test \${$as_ac_Lib+y}
80036then :
80037  printf %s "(cached) " >&6
80038else $as_nop
80039  ac_check_lib_save_LIBS=$LIBS
80040LIBS="-l$TIDY_LIB_NAME  $LIBS"
80041cat confdefs.h - <<_ACEOF >conftest.$ac_ext
80042/* end confdefs.h.  */
80043
80044/* Override any GCC internal prototype to avoid an error.
80045   Use char because int might match the return type of a GCC
80046   builtin and then its argument prototype would still apply.  */
80047char tidyReleaseDate ();
80048int
80049main (void)
80050{
80051return tidyReleaseDate ();
80052  ;
80053  return 0;
80054}
80055_ACEOF
80056if ac_fn_c_try_link "$LINENO"
80057then :
80058  eval "$as_ac_Lib=yes"
80059else $as_nop
80060  eval "$as_ac_Lib=no"
80061fi
80062rm -f core conftest.err conftest.$ac_objext conftest.beam \
80063    conftest$ac_exeext conftest.$ac_ext
80064LIBS=$ac_check_lib_save_LIBS
80065fi
80066eval ac_res=\$$as_ac_Lib
80067	       { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
80068printf "%s\n" "$ac_res" >&6; }
80069if eval test \"x\$"$as_ac_Lib"\" = x"yes"
80070then :
80071
80072    LDFLAGS=$save_old_LDFLAGS
80073    ext_shared=$save_ext_shared
80074
80075
80076printf "%s\n" "#define HAVE_TIDYRELEASEDATE 1" >>confdefs.h
80077
80078
80079
80080else $as_nop
80081
80082    LDFLAGS=$save_old_LDFLAGS
80083    ext_shared=$save_ext_shared
80084    unset ac_cv_lib_$TIDY_LIB_NAME_tidyReleaseDate
80085
80086
80087fi
80088
80089
80090
80091
80092  if test "$ext_shared" = "yes"; then
80093    TIDY_SHARED_LIBADD="-l$TIDY_LIB_NAME $TIDY_SHARED_LIBADD"
80094    if test -n "$TIDY_LIBDIR"; then
80095
80096  if test "$TIDY_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$TIDY_LIBDIR" != "/usr/lib"; then
80097
80098  if test -z "$TIDY_LIBDIR" || echo "$TIDY_LIBDIR" | grep '^/' >/dev/null ; then
80099    ai_p=$TIDY_LIBDIR
80100  else
80101
80102    ep_dir=`echo $TIDY_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
80103
80104    ep_realdir=`(cd "$ep_dir" && pwd)`
80105    ai_p="$ep_realdir"/`basename "$TIDY_LIBDIR"`
80106  fi
80107
80108
80109      if test "$ext_shared" = "yes"; then
80110        TIDY_SHARED_LIBADD="-L$ai_p $TIDY_SHARED_LIBADD"
80111        test -n "$ld_runpath_switch" && TIDY_SHARED_LIBADD="$ld_runpath_switch$ai_p $TIDY_SHARED_LIBADD"
80112      else
80113
80114
80115
80116  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
80117
80118  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
80119  if test -n "$unique" && test "`eval $cmd`" = "" ; then
80120    eval "LIBPATH$unique=set"
80121
80122    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
80123    LDFLAGS="$LDFLAGS -L$ai_p"
80124    PHP_RPATHS="$PHP_RPATHS $ai_p"
80125
80126  fi
80127
80128
80129      fi
80130
80131  fi
80132
80133    fi
80134  else
80135
80136
80137  if test -n "$TIDY_LIBDIR"; then
80138
80139  if test "$TIDY_LIBDIR" != "/usr/$PHP_LIBDIR" && test "$TIDY_LIBDIR" != "/usr/lib"; then
80140
80141  if test -z "$TIDY_LIBDIR" || echo "$TIDY_LIBDIR" | grep '^/' >/dev/null ; then
80142    ai_p=$TIDY_LIBDIR
80143  else
80144
80145    ep_dir=`echo $TIDY_LIBDIR|$SED 's%/*[^/][^/]*/*$%%'`
80146
80147    ep_realdir=`(cd "$ep_dir" && pwd)`
80148    ai_p="$ep_realdir"/`basename "$TIDY_LIBDIR"`
80149  fi
80150
80151
80152
80153
80154
80155  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
80156
80157  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
80158  if test -n "$unique" && test "`eval $cmd`" = "" ; then
80159    eval "LIBPATH$unique=set"
80160
80161    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
80162    LDFLAGS="$LDFLAGS -L$ai_p"
80163    PHP_RPATHS="$PHP_RPATHS $ai_p"
80164
80165  fi
80166
80167
80168
80169  fi
80170
80171  fi
80172
80173
80174  case $TIDY_LIB_NAME in
80175  c|c_r) ;;
80176  *)
80177      LIBS="-l$TIDY_LIB_NAME $LIBS"
80178   ;;
80179  esac
80180
80181
80182
80183
80184  fi
80185
80186
80187
80188  if test "$TIDY_INCDIR" != "/usr/include"; then
80189
80190  if test -z "$TIDY_INCDIR" || echo "$TIDY_INCDIR" | grep '^/' >/dev/null ; then
80191    ai_p=$TIDY_INCDIR
80192  else
80193
80194    ep_dir=`echo $TIDY_INCDIR|$SED 's%/*[^/][^/]*/*$%%'`
80195
80196    ep_realdir=`(cd "$ep_dir" && pwd)`
80197    ai_p="$ep_realdir"/`basename "$TIDY_INCDIR"`
80198  fi
80199
80200
80201
80202  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
80203
80204  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
80205  if test -n "$unique" && test "`eval $cmd`" = "" ; then
80206    eval "INCLUDEPATH$unique=set"
80207
80208      if test ""; then
80209        INCLUDES="-I$ai_p $INCLUDES"
80210      else
80211        INCLUDES="$INCLUDES -I$ai_p"
80212      fi
80213
80214  fi
80215
80216  fi
80217
80218
80219    TIDY_COMPILER_FLAGS="$TIDY_CFLAGS -Wno-ignored-qualifiers -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"
80220
80221  ext_builddir=ext/tidy
80222  ext_srcdir=$abs_srcdir/ext/tidy
80223  ext_dir=ext/tidy
80224
80225  ac_extra=`echo "$TIDY_COMPILER_FLAGS"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
80226
80227  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
80228    PHP_TIDY_SHARED=no
80229
80230
80231  case $ext_dir in
80232  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80233  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80234  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80235  esac
80236
80237
80238
80239  b_c_pre=$php_c_pre
80240  b_cxx_pre=$php_cxx_pre
80241  b_c_meta=$php_c_meta
80242  b_cxx_meta=$php_cxx_meta
80243  b_c_post=$php_c_post
80244  b_cxx_post=$php_cxx_post
80245  b_lo=$php_lo
80246
80247
80248  old_IFS=$IFS
80249  for ac_src in tidy.c; do
80250
80251      IFS=.
80252      set $ac_src
80253      ac_obj=$1
80254      IFS=$old_IFS
80255
80256      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80257
80258      case $ac_src in
80259        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80260        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80261        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80262        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80263      esac
80264
80265      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80266
80267    cat >>Makefile.objects<<EOF
80268-include $ac_bdir$ac_obj.dep
80269$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80270	$ac_comp
80271EOF
80272  done
80273
80274
80275    EXT_STATIC="$EXT_STATIC tidy;$ext_dir"
80276    if test "$ext_shared" != "nocli"; then
80277      EXT_CLI_STATIC="$EXT_CLI_STATIC tidy;$ext_dir"
80278    fi
80279  else
80280    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
80281      PHP_TIDY_SHARED=yes
80282
80283  case $ext_dir in
80284  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80285  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80286  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80287  esac
80288
80289
80290
80291  b_c_pre=$shared_c_pre
80292  b_cxx_pre=$shared_cxx_pre
80293  b_c_meta=$shared_c_meta
80294  b_cxx_meta=$shared_cxx_meta
80295  b_c_post=$shared_c_post
80296  b_cxx_post=$shared_cxx_post
80297  b_lo=$shared_lo
80298
80299
80300  old_IFS=$IFS
80301  for ac_src in tidy.c; do
80302
80303      IFS=.
80304      set $ac_src
80305      ac_obj=$1
80306      IFS=$old_IFS
80307
80308      shared_objects_tidy="$shared_objects_tidy $ac_bdir$ac_obj.lo"
80309
80310      case $ac_src in
80311        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80312        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80313        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80314        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80315      esac
80316
80317      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80318
80319    cat >>Makefile.objects<<EOF
80320-include $ac_bdir$ac_obj.dep
80321$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80322	$ac_comp
80323EOF
80324  done
80325
80326
80327  install_modules="install-modules"
80328  suffix=la
80329
80330  case $host_alias in
80331    *aix*)
80332      additional_flags="-Wl,-G"
80333      ;;
80334  esac
80335
80336  if test "x" = "xyes"; then
80337    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/tidy.$suffix"
80338  else
80339    PHP_MODULES="$PHP_MODULES \$(phplibdir)/tidy.$suffix"
80340  fi
80341
80342  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_tidy"
80343
80344  cat >>Makefile.objects<<EOF
80345\$(phplibdir)/tidy.$suffix: $ext_builddir/tidy.$suffix
80346	\$(LIBTOOL) --mode=install cp $ext_builddir/tidy.$suffix \$(phplibdir)
80347
80348$ext_builddir/tidy.$suffix: \$(shared_objects_tidy) \$(TIDY_SHARED_DEPENDENCIES)
80349	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_tidy) \$(TIDY_SHARED_LIBADD)
80350
80351EOF
80352
80353
80354printf "%s\n" "#define COMPILE_DL_TIDY 1" >>confdefs.h
80355
80356    fi
80357  fi
80358
80359  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
80360    PHP_TIDY_SHARED=no
80361    case "$PHP_SAPI" in
80362      cgi|embed|phpdbg)
80363
80364
80365  case $ext_dir in
80366  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80367  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80368  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80369  esac
80370
80371
80372
80373  b_c_pre=$php_c_pre
80374  b_cxx_pre=$php_cxx_pre
80375  b_c_meta=$php_c_meta
80376  b_cxx_meta=$php_cxx_meta
80377  b_c_post=$php_c_post
80378  b_cxx_post=$php_cxx_post
80379  b_lo=$php_lo
80380
80381
80382  old_IFS=$IFS
80383  for ac_src in tidy.c; do
80384
80385      IFS=.
80386      set $ac_src
80387      ac_obj=$1
80388      IFS=$old_IFS
80389
80390      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80391
80392      case $ac_src in
80393        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80394        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80395        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80396        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80397      esac
80398
80399      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80400
80401    cat >>Makefile.objects<<EOF
80402-include $ac_bdir$ac_obj.dep
80403$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80404	$ac_comp
80405EOF
80406  done
80407
80408
80409        EXT_STATIC="$EXT_STATIC tidy;$ext_dir"
80410        ;;
80411      *)
80412
80413
80414  case $ext_dir in
80415  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80416  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80417  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80418  esac
80419
80420
80421
80422  b_c_pre=$php_c_pre
80423  b_cxx_pre=$php_cxx_pre
80424  b_c_meta=$php_c_meta
80425  b_cxx_meta=$php_cxx_meta
80426  b_c_post=$php_c_post
80427  b_cxx_post=$php_cxx_post
80428  b_lo=$php_lo
80429
80430
80431  old_IFS=$IFS
80432  for ac_src in tidy.c; do
80433
80434      IFS=.
80435      set $ac_src
80436      ac_obj=$1
80437      IFS=$old_IFS
80438
80439      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80440
80441      case $ac_src in
80442        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80443        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80444        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80445        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80446      esac
80447
80448      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80449
80450    cat >>Makefile.objects<<EOF
80451-include $ac_bdir$ac_obj.dep
80452$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80453	$ac_comp
80454EOF
80455  done
80456
80457
80458        ;;
80459    esac
80460    EXT_CLI_STATIC="$EXT_CLI_STATIC tidy;$ext_dir"
80461  fi
80462
80463
80464    BUILD_DIR="$BUILD_DIR $ext_builddir"
80465
80466
80467
80468  if test "$ext_builddir" = "."; then
80469    PHP_PECL_EXTENSION=tidy
80470
80471  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
80472
80473  fi
80474
80475
80476  PHP_VAR_SUBST="$PHP_VAR_SUBST TIDY_SHARED_LIBADD"
80477
80478
80479printf "%s\n" "#define HAVE_TIDY 1" >>confdefs.h
80480
80481fi
80482
80483
80484
80485
80486
80487php_enable_tokenizer=yes
80488
80489{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable tokenizer support" >&5
80490printf %s "checking whether to enable tokenizer support... " >&6; }
80491# Check whether --enable-tokenizer was given.
80492if test ${enable_tokenizer+y}
80493then :
80494  enableval=$enable_tokenizer; PHP_TOKENIZER=$enableval
80495else $as_nop
80496
80497  PHP_TOKENIZER=yes
80498  test "$PHP_ENABLE_ALL" && PHP_TOKENIZER=$PHP_ENABLE_ALL
80499
80500fi
80501
80502
80503
80504ext_output="yes, shared"
80505ext_shared=yes
80506case $PHP_TOKENIZER in
80507shared,*)
80508  PHP_TOKENIZER=`echo "$PHP_TOKENIZER"|$SED 's/^shared,//'`
80509  ;;
80510shared)
80511  PHP_TOKENIZER=yes
80512  ;;
80513no)
80514  ext_output=no
80515  ext_shared=no
80516  ;;
80517*)
80518  ext_output=yes
80519  ext_shared=no
80520  ;;
80521esac
80522
80523
80524
80525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
80526printf "%s\n" "$ext_output" >&6; }
80527
80528
80529
80530
80531if test "$PHP_TOKENIZER" != "no"; then
80532
80533  ext_builddir=ext/tokenizer
80534  ext_srcdir=$abs_srcdir/ext/tokenizer
80535  ext_dir=ext/tokenizer
80536
80537  ac_extra=
80538
80539  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
80540    PHP_TOKENIZER_SHARED=no
80541
80542
80543  case $ext_dir in
80544  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80545  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80546  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80547  esac
80548
80549
80550
80551  b_c_pre=$php_c_pre
80552  b_cxx_pre=$php_cxx_pre
80553  b_c_meta=$php_c_meta
80554  b_cxx_meta=$php_cxx_meta
80555  b_c_post=$php_c_post
80556  b_cxx_post=$php_cxx_post
80557  b_lo=$php_lo
80558
80559
80560  old_IFS=$IFS
80561  for ac_src in tokenizer.c tokenizer_data.c; do
80562
80563      IFS=.
80564      set $ac_src
80565      ac_obj=$1
80566      IFS=$old_IFS
80567
80568      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80569
80570      case $ac_src in
80571        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80572        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80573        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80574        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80575      esac
80576
80577      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80578
80579    cat >>Makefile.objects<<EOF
80580-include $ac_bdir$ac_obj.dep
80581$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80582	$ac_comp
80583EOF
80584  done
80585
80586
80587    EXT_STATIC="$EXT_STATIC tokenizer;$ext_dir"
80588    if test "$ext_shared" != "nocli"; then
80589      EXT_CLI_STATIC="$EXT_CLI_STATIC tokenizer;$ext_dir"
80590    fi
80591  else
80592    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
80593      PHP_TOKENIZER_SHARED=yes
80594
80595  case $ext_dir in
80596  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80597  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80598  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80599  esac
80600
80601
80602
80603  b_c_pre=$shared_c_pre
80604  b_cxx_pre=$shared_cxx_pre
80605  b_c_meta=$shared_c_meta
80606  b_cxx_meta=$shared_cxx_meta
80607  b_c_post=$shared_c_post
80608  b_cxx_post=$shared_cxx_post
80609  b_lo=$shared_lo
80610
80611
80612  old_IFS=$IFS
80613  for ac_src in tokenizer.c tokenizer_data.c; do
80614
80615      IFS=.
80616      set $ac_src
80617      ac_obj=$1
80618      IFS=$old_IFS
80619
80620      shared_objects_tokenizer="$shared_objects_tokenizer $ac_bdir$ac_obj.lo"
80621
80622      case $ac_src in
80623        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80624        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80625        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80626        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80627      esac
80628
80629      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80630
80631    cat >>Makefile.objects<<EOF
80632-include $ac_bdir$ac_obj.dep
80633$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80634	$ac_comp
80635EOF
80636  done
80637
80638
80639  install_modules="install-modules"
80640  suffix=la
80641
80642  case $host_alias in
80643    *aix*)
80644      additional_flags="-Wl,-G"
80645      ;;
80646  esac
80647
80648  if test "x" = "xyes"; then
80649    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/tokenizer.$suffix"
80650  else
80651    PHP_MODULES="$PHP_MODULES \$(phplibdir)/tokenizer.$suffix"
80652  fi
80653
80654  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_tokenizer"
80655
80656  cat >>Makefile.objects<<EOF
80657\$(phplibdir)/tokenizer.$suffix: $ext_builddir/tokenizer.$suffix
80658	\$(LIBTOOL) --mode=install cp $ext_builddir/tokenizer.$suffix \$(phplibdir)
80659
80660$ext_builddir/tokenizer.$suffix: \$(shared_objects_tokenizer) \$(TOKENIZER_SHARED_DEPENDENCIES)
80661	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_tokenizer) \$(TOKENIZER_SHARED_LIBADD)
80662
80663EOF
80664
80665
80666printf "%s\n" "#define COMPILE_DL_TOKENIZER 1" >>confdefs.h
80667
80668    fi
80669  fi
80670
80671  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
80672    PHP_TOKENIZER_SHARED=no
80673    case "$PHP_SAPI" in
80674      cgi|embed|phpdbg)
80675
80676
80677  case $ext_dir in
80678  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80679  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80680  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80681  esac
80682
80683
80684
80685  b_c_pre=$php_c_pre
80686  b_cxx_pre=$php_cxx_pre
80687  b_c_meta=$php_c_meta
80688  b_cxx_meta=$php_cxx_meta
80689  b_c_post=$php_c_post
80690  b_cxx_post=$php_cxx_post
80691  b_lo=$php_lo
80692
80693
80694  old_IFS=$IFS
80695  for ac_src in tokenizer.c tokenizer_data.c; do
80696
80697      IFS=.
80698      set $ac_src
80699      ac_obj=$1
80700      IFS=$old_IFS
80701
80702      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80703
80704      case $ac_src in
80705        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80706        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80707        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80708        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80709      esac
80710
80711      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80712
80713    cat >>Makefile.objects<<EOF
80714-include $ac_bdir$ac_obj.dep
80715$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80716	$ac_comp
80717EOF
80718  done
80719
80720
80721        EXT_STATIC="$EXT_STATIC tokenizer;$ext_dir"
80722        ;;
80723      *)
80724
80725
80726  case $ext_dir in
80727  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
80728  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
80729  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
80730  esac
80731
80732
80733
80734  b_c_pre=$php_c_pre
80735  b_cxx_pre=$php_cxx_pre
80736  b_c_meta=$php_c_meta
80737  b_cxx_meta=$php_cxx_meta
80738  b_c_post=$php_c_post
80739  b_cxx_post=$php_cxx_post
80740  b_lo=$php_lo
80741
80742
80743  old_IFS=$IFS
80744  for ac_src in tokenizer.c tokenizer_data.c; do
80745
80746      IFS=.
80747      set $ac_src
80748      ac_obj=$1
80749      IFS=$old_IFS
80750
80751      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
80752
80753      case $ac_src in
80754        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80755        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80756        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
80757        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
80758      esac
80759
80760      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
80761
80762    cat >>Makefile.objects<<EOF
80763-include $ac_bdir$ac_obj.dep
80764$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
80765	$ac_comp
80766EOF
80767  done
80768
80769
80770        ;;
80771    esac
80772    EXT_CLI_STATIC="$EXT_CLI_STATIC tokenizer;$ext_dir"
80773  fi
80774
80775
80776    BUILD_DIR="$BUILD_DIR $ext_builddir"
80777
80778
80779
80780  if test "$ext_builddir" = "."; then
80781    PHP_PECL_EXTENSION=tokenizer
80782
80783  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
80784
80785  fi
80786
80787
80788  src=$ext_srcdir/Makefile.frag
80789  ac_srcdir=$ext_srcdir
80790  ac_builddir=$ext_builddir
80791  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
80792
80793fi
80794
80795
80796
80797
80798
80799php_enable_xml=yes
80800
80801{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable XML support" >&5
80802printf %s "checking whether to enable XML support... " >&6; }
80803# Check whether --enable-xml was given.
80804if test ${enable_xml+y}
80805then :
80806  enableval=$enable_xml; PHP_XML=$enableval
80807else $as_nop
80808
80809  PHP_XML=yes
80810  test "$PHP_ENABLE_ALL" && PHP_XML=$PHP_ENABLE_ALL
80811
80812fi
80813
80814
80815
80816ext_output="yes, shared"
80817ext_shared=yes
80818case $PHP_XML in
80819shared,*)
80820  PHP_XML=`echo "$PHP_XML"|$SED 's/^shared,//'`
80821  ;;
80822shared)
80823  PHP_XML=yes
80824  ;;
80825no)
80826  ext_output=no
80827  ext_shared=no
80828  ;;
80829*)
80830  ext_output=yes
80831  ext_shared=no
80832  ;;
80833esac
80834
80835
80836
80837{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
80838printf "%s\n" "$ext_output" >&6; }
80839
80840
80841
80842
80843
80844php_with_expat=no
80845
80846{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with expat support" >&5
80847printf %s "checking whether to build with expat support... " >&6; }
80848
80849# Check whether --with-expat was given.
80850if test ${with_expat+y}
80851then :
80852  withval=$with_expat; PHP_EXPAT=$withval
80853else $as_nop
80854
80855  PHP_EXPAT=no
80856
80857
80858fi
80859
80860
80861ext_output=$PHP_EXPAT
80862{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
80863printf "%s\n" "$ext_output" >&6; }
80864
80865
80866
80867
80868if test "$PHP_XML" != "no"; then
80869
80870        if test "$PHP_EXPAT" = "no"; then
80871
80872    if test "$PHP_LIBXML" = "no"; then
80873      as_fn_error $? "XML extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
80874    fi
80875
80876
80877
80878pkg_failed=no
80879{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
80880printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
80881
80882if test -n "$LIBXML_CFLAGS"; then
80883    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
80884 elif test -n "$PKG_CONFIG"; then
80885    if test -n "$PKG_CONFIG" && \
80886    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
80887  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
80888  ac_status=$?
80889  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
80890  test $ac_status = 0; }; then
80891  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
80892		      test "x$?" != "x0" && pkg_failed=yes
80893else
80894  pkg_failed=yes
80895fi
80896 else
80897    pkg_failed=untried
80898fi
80899if test -n "$LIBXML_LIBS"; then
80900    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
80901 elif test -n "$PKG_CONFIG"; then
80902    if test -n "$PKG_CONFIG" && \
80903    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
80904  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
80905  ac_status=$?
80906  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
80907  test $ac_status = 0; }; then
80908  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
80909		      test "x$?" != "x0" && pkg_failed=yes
80910else
80911  pkg_failed=yes
80912fi
80913 else
80914    pkg_failed=untried
80915fi
80916
80917
80918
80919if test $pkg_failed = yes; then
80920        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
80921printf "%s\n" "no" >&6; }
80922
80923if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
80924        _pkg_short_errors_supported=yes
80925else
80926        _pkg_short_errors_supported=no
80927fi
80928        if test $_pkg_short_errors_supported = yes; then
80929	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
80930        else
80931	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
80932        fi
80933	# Put the nasty error message in config.log where it belongs
80934	echo "$LIBXML_PKG_ERRORS" >&5
80935
80936	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
80937
80938$LIBXML_PKG_ERRORS
80939
80940Consider adjusting the PKG_CONFIG_PATH environment variable if you
80941installed software in a non-standard prefix.
80942
80943Alternatively, you may set the environment variables LIBXML_CFLAGS
80944and LIBXML_LIBS to avoid the need to call pkg-config.
80945See the pkg-config man page for more details." "$LINENO" 5
80946elif test $pkg_failed = untried; then
80947        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
80948printf "%s\n" "no" >&6; }
80949	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
80950printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
80951as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
80952is in your PATH or set the PKG_CONFIG environment variable to the full
80953path to pkg-config.
80954
80955Alternatively, you may set the environment variables LIBXML_CFLAGS
80956and LIBXML_LIBS to avoid the need to call pkg-config.
80957See the pkg-config man page for more details.
80958
80959To get pkg-config, see <http://pkg-config.freedesktop.org/>.
80960See \`config.log' for more details" "$LINENO" 5; }
80961else
80962	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
80963	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
80964        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
80965printf "%s\n" "yes" >&6; }
80966
80967fi
80968
80969
80970  for ac_i in $LIBXML_CFLAGS; do
80971    case $ac_i in
80972    -I*)
80973      ac_ii=`echo $ac_i|cut -c 3-`
80974
80975  if test "$ac_ii" != "/usr/include"; then
80976
80977  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
80978    ai_p=$ac_ii
80979  else
80980
80981    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
80982
80983    ep_realdir=`(cd "$ep_dir" && pwd)`
80984    ai_p="$ep_realdir"/`basename "$ac_ii"`
80985  fi
80986
80987
80988
80989  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
80990
80991  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
80992  if test -n "$unique" && test "`eval $cmd`" = "" ; then
80993    eval "INCLUDEPATH$unique=set"
80994
80995      if test ""; then
80996        INCLUDES="-I$ai_p $INCLUDES"
80997      else
80998        INCLUDES="$INCLUDES -I$ai_p"
80999      fi
81000
81001  fi
81002
81003  fi
81004
81005    ;;
81006    esac
81007  done
81008
81009
81010  for ac_i in $LIBXML_LIBS; do
81011    case $ac_i in
81012    -pthread)
81013      if test "$ext_shared" = "yes"; then
81014        XML_SHARED_LIBADD="$XML_SHARED_LIBADD -pthread"
81015      else
81016
81017
81018  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81019
81020  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
81021  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81022    eval "EXTRA_LDFLAGS$unique=set"
81023    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
81024  fi
81025
81026
81027
81028  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81029
81030  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
81031  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81032    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
81033    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
81034  fi
81035
81036      fi
81037    ;;
81038    -l*)
81039      ac_ii=`echo $ac_i|cut -c 3-`
81040
81041
81042  case $ac_ii in
81043  c|c_r) ;;
81044  *)
81045    if test "$ext_shared" = "yes"; then
81046        XML_SHARED_LIBADD="$XML_SHARED_LIBADD -l$ac_ii"
81047    else
81048
81049
81050  case $ac_ii in
81051  c|c_r) ;;
81052  *)
81053      LIBS="$LIBS -l$ac_ii"
81054   ;;
81055  esac
81056
81057
81058    fi
81059   ;;
81060  esac
81061
81062
81063    ;;
81064    -L*)
81065      ac_ii=`echo $ac_i|cut -c 3-`
81066
81067  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
81068
81069  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
81070    ai_p=$ac_ii
81071  else
81072
81073    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
81074
81075    ep_realdir=`(cd "$ep_dir" && pwd)`
81076    ai_p="$ep_realdir"/`basename "$ac_ii"`
81077  fi
81078
81079
81080      if test "$ext_shared" = "yes"; then
81081        XML_SHARED_LIBADD="-L$ai_p $XML_SHARED_LIBADD"
81082        test -n "$ld_runpath_switch" && XML_SHARED_LIBADD="$ld_runpath_switch$ai_p $XML_SHARED_LIBADD"
81083      else
81084
81085
81086
81087  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
81088
81089  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
81090  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81091    eval "LIBPATH$unique=set"
81092
81093    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
81094    LDFLAGS="$LDFLAGS -L$ai_p"
81095    PHP_RPATHS="$PHP_RPATHS $ai_p"
81096
81097  fi
81098
81099
81100      fi
81101
81102  fi
81103
81104    ;;
81105    esac
81106  done
81107
81108
81109
81110printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
81111
81112
81113
81114      xml_extra_sources="compat.c"
81115
81116  am_i_shared=$PHP_XML_SHARED
81117  is_it_shared=$PHP_LIBXML_SHARED
81118  is_it_enabled=$PHP_LIBXML
81119  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
81120    as_fn_error $? "
81121You've configured extension xml to build statically, but it
81122depends on extension libxml, which you've configured to build shared.
81123You either need to build xml shared or build libxml statically for the
81124build to be successful.
81125" "$LINENO" 5
81126  fi
81127  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
81128    as_fn_error $? "
81129You've configured extension xml, which depends on extension libxml,
81130but you've either not enabled libxml, or have disabled it.
81131" "$LINENO" 5
81132  fi
81133
81134
81135
81136  else
81137
81138
81139pkg_failed=no
81140{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for expat" >&5
81141printf %s "checking for expat... " >&6; }
81142
81143if test -n "$EXPAT_CFLAGS"; then
81144    pkg_cv_EXPAT_CFLAGS="$EXPAT_CFLAGS"
81145 elif test -n "$PKG_CONFIG"; then
81146    if test -n "$PKG_CONFIG" && \
81147    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"expat\""; } >&5
81148  ($PKG_CONFIG --exists --print-errors "expat") 2>&5
81149  ac_status=$?
81150  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
81151  test $ac_status = 0; }; then
81152  pkg_cv_EXPAT_CFLAGS=`$PKG_CONFIG --cflags "expat" 2>/dev/null`
81153		      test "x$?" != "x0" && pkg_failed=yes
81154else
81155  pkg_failed=yes
81156fi
81157 else
81158    pkg_failed=untried
81159fi
81160if test -n "$EXPAT_LIBS"; then
81161    pkg_cv_EXPAT_LIBS="$EXPAT_LIBS"
81162 elif test -n "$PKG_CONFIG"; then
81163    if test -n "$PKG_CONFIG" && \
81164    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"expat\""; } >&5
81165  ($PKG_CONFIG --exists --print-errors "expat") 2>&5
81166  ac_status=$?
81167  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
81168  test $ac_status = 0; }; then
81169  pkg_cv_EXPAT_LIBS=`$PKG_CONFIG --libs "expat" 2>/dev/null`
81170		      test "x$?" != "x0" && pkg_failed=yes
81171else
81172  pkg_failed=yes
81173fi
81174 else
81175    pkg_failed=untried
81176fi
81177
81178
81179
81180if test $pkg_failed = yes; then
81181        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
81182printf "%s\n" "no" >&6; }
81183
81184if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
81185        _pkg_short_errors_supported=yes
81186else
81187        _pkg_short_errors_supported=no
81188fi
81189        if test $_pkg_short_errors_supported = yes; then
81190	        EXPAT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "expat" 2>&1`
81191        else
81192	        EXPAT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "expat" 2>&1`
81193        fi
81194	# Put the nasty error message in config.log where it belongs
81195	echo "$EXPAT_PKG_ERRORS" >&5
81196
81197	as_fn_error $? "Package requirements (expat) were not met:
81198
81199$EXPAT_PKG_ERRORS
81200
81201Consider adjusting the PKG_CONFIG_PATH environment variable if you
81202installed software in a non-standard prefix.
81203
81204Alternatively, you may set the environment variables EXPAT_CFLAGS
81205and EXPAT_LIBS to avoid the need to call pkg-config.
81206See the pkg-config man page for more details." "$LINENO" 5
81207elif test $pkg_failed = untried; then
81208        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
81209printf "%s\n" "no" >&6; }
81210	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
81211printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
81212as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
81213is in your PATH or set the PKG_CONFIG environment variable to the full
81214path to pkg-config.
81215
81216Alternatively, you may set the environment variables EXPAT_CFLAGS
81217and EXPAT_LIBS to avoid the need to call pkg-config.
81218See the pkg-config man page for more details.
81219
81220To get pkg-config, see <http://pkg-config.freedesktop.org/>.
81221See \`config.log' for more details" "$LINENO" 5; }
81222else
81223	EXPAT_CFLAGS=$pkg_cv_EXPAT_CFLAGS
81224	EXPAT_LIBS=$pkg_cv_EXPAT_LIBS
81225        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
81226printf "%s\n" "yes" >&6; }
81227
81228fi
81229
81230
81231  for ac_i in $EXPAT_CFLAGS; do
81232    case $ac_i in
81233    -I*)
81234      ac_ii=`echo $ac_i|cut -c 3-`
81235
81236  if test "$ac_ii" != "/usr/include"; then
81237
81238  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
81239    ai_p=$ac_ii
81240  else
81241
81242    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
81243
81244    ep_realdir=`(cd "$ep_dir" && pwd)`
81245    ai_p="$ep_realdir"/`basename "$ac_ii"`
81246  fi
81247
81248
81249
81250  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
81251
81252  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
81253  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81254    eval "INCLUDEPATH$unique=set"
81255
81256      if test ""; then
81257        INCLUDES="-I$ai_p $INCLUDES"
81258      else
81259        INCLUDES="$INCLUDES -I$ai_p"
81260      fi
81261
81262  fi
81263
81264  fi
81265
81266    ;;
81267    esac
81268  done
81269
81270
81271  for ac_i in $EXPAT_LIBS; do
81272    case $ac_i in
81273    -pthread)
81274      if test "$ext_shared" = "yes"; then
81275        XML_SHARED_LIBADD="$XML_SHARED_LIBADD -pthread"
81276      else
81277
81278
81279  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81280
81281  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
81282  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81283    eval "EXTRA_LDFLAGS$unique=set"
81284    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
81285  fi
81286
81287
81288
81289  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81290
81291  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
81292  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81293    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
81294    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
81295  fi
81296
81297      fi
81298    ;;
81299    -l*)
81300      ac_ii=`echo $ac_i|cut -c 3-`
81301
81302
81303  case $ac_ii in
81304  c|c_r) ;;
81305  *)
81306    if test "$ext_shared" = "yes"; then
81307        XML_SHARED_LIBADD="$XML_SHARED_LIBADD -l$ac_ii"
81308    else
81309
81310
81311  case $ac_ii in
81312  c|c_r) ;;
81313  *)
81314      LIBS="$LIBS -l$ac_ii"
81315   ;;
81316  esac
81317
81318
81319    fi
81320   ;;
81321  esac
81322
81323
81324    ;;
81325    -L*)
81326      ac_ii=`echo $ac_i|cut -c 3-`
81327
81328  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
81329
81330  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
81331    ai_p=$ac_ii
81332  else
81333
81334    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
81335
81336    ep_realdir=`(cd "$ep_dir" && pwd)`
81337    ai_p="$ep_realdir"/`basename "$ac_ii"`
81338  fi
81339
81340
81341      if test "$ext_shared" = "yes"; then
81342        XML_SHARED_LIBADD="-L$ai_p $XML_SHARED_LIBADD"
81343        test -n "$ld_runpath_switch" && XML_SHARED_LIBADD="$ld_runpath_switch$ai_p $XML_SHARED_LIBADD"
81344      else
81345
81346
81347
81348  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
81349
81350  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
81351  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81352    eval "LIBPATH$unique=set"
81353
81354    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
81355    LDFLAGS="$LDFLAGS -L$ai_p"
81356    PHP_RPATHS="$PHP_RPATHS $ai_p"
81357
81358  fi
81359
81360
81361      fi
81362
81363  fi
81364
81365    ;;
81366    esac
81367  done
81368
81369
81370
81371printf "%s\n" "#define HAVE_LIBEXPAT 1" >>confdefs.h
81372
81373
81374  fi
81375
81376
81377  ext_builddir=ext/xml
81378  ext_srcdir=$abs_srcdir/ext/xml
81379  ext_dir=ext/xml
81380
81381  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
81382
81383  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
81384    PHP_XML_SHARED=no
81385
81386
81387  case $ext_dir in
81388  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
81389  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
81390  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
81391  esac
81392
81393
81394
81395  b_c_pre=$php_c_pre
81396  b_cxx_pre=$php_cxx_pre
81397  b_c_meta=$php_c_meta
81398  b_cxx_meta=$php_cxx_meta
81399  b_c_post=$php_c_post
81400  b_cxx_post=$php_cxx_post
81401  b_lo=$php_lo
81402
81403
81404  old_IFS=$IFS
81405  for ac_src in xml.c $xml_extra_sources; do
81406
81407      IFS=.
81408      set $ac_src
81409      ac_obj=$1
81410      IFS=$old_IFS
81411
81412      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
81413
81414      case $ac_src in
81415        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81416        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81417        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81418        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
81419      esac
81420
81421      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
81422
81423    cat >>Makefile.objects<<EOF
81424-include $ac_bdir$ac_obj.dep
81425$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
81426	$ac_comp
81427EOF
81428  done
81429
81430
81431    EXT_STATIC="$EXT_STATIC xml;$ext_dir"
81432    if test "$ext_shared" != "nocli"; then
81433      EXT_CLI_STATIC="$EXT_CLI_STATIC xml;$ext_dir"
81434    fi
81435  else
81436    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
81437      PHP_XML_SHARED=yes
81438
81439  case $ext_dir in
81440  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
81441  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
81442  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
81443  esac
81444
81445
81446
81447  b_c_pre=$shared_c_pre
81448  b_cxx_pre=$shared_cxx_pre
81449  b_c_meta=$shared_c_meta
81450  b_cxx_meta=$shared_cxx_meta
81451  b_c_post=$shared_c_post
81452  b_cxx_post=$shared_cxx_post
81453  b_lo=$shared_lo
81454
81455
81456  old_IFS=$IFS
81457  for ac_src in xml.c $xml_extra_sources; do
81458
81459      IFS=.
81460      set $ac_src
81461      ac_obj=$1
81462      IFS=$old_IFS
81463
81464      shared_objects_xml="$shared_objects_xml $ac_bdir$ac_obj.lo"
81465
81466      case $ac_src in
81467        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81468        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81469        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81470        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
81471      esac
81472
81473      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
81474
81475    cat >>Makefile.objects<<EOF
81476-include $ac_bdir$ac_obj.dep
81477$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
81478	$ac_comp
81479EOF
81480  done
81481
81482
81483  install_modules="install-modules"
81484  suffix=la
81485
81486  case $host_alias in
81487    *aix*)
81488      additional_flags="-Wl,-G"
81489      ;;
81490  esac
81491
81492  if test "x" = "xyes"; then
81493    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/xml.$suffix"
81494  else
81495    PHP_MODULES="$PHP_MODULES \$(phplibdir)/xml.$suffix"
81496  fi
81497
81498  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_xml"
81499
81500  cat >>Makefile.objects<<EOF
81501\$(phplibdir)/xml.$suffix: $ext_builddir/xml.$suffix
81502	\$(LIBTOOL) --mode=install cp $ext_builddir/xml.$suffix \$(phplibdir)
81503
81504$ext_builddir/xml.$suffix: \$(shared_objects_xml) \$(XML_SHARED_DEPENDENCIES)
81505	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_xml) \$(XML_SHARED_LIBADD)
81506
81507EOF
81508
81509
81510printf "%s\n" "#define COMPILE_DL_XML 1" >>confdefs.h
81511
81512    fi
81513  fi
81514
81515  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
81516    PHP_XML_SHARED=no
81517    case "$PHP_SAPI" in
81518      cgi|embed|phpdbg)
81519
81520
81521  case $ext_dir in
81522  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
81523  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
81524  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
81525  esac
81526
81527
81528
81529  b_c_pre=$php_c_pre
81530  b_cxx_pre=$php_cxx_pre
81531  b_c_meta=$php_c_meta
81532  b_cxx_meta=$php_cxx_meta
81533  b_c_post=$php_c_post
81534  b_cxx_post=$php_cxx_post
81535  b_lo=$php_lo
81536
81537
81538  old_IFS=$IFS
81539  for ac_src in xml.c $xml_extra_sources; do
81540
81541      IFS=.
81542      set $ac_src
81543      ac_obj=$1
81544      IFS=$old_IFS
81545
81546      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
81547
81548      case $ac_src in
81549        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81550        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81551        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81552        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
81553      esac
81554
81555      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
81556
81557    cat >>Makefile.objects<<EOF
81558-include $ac_bdir$ac_obj.dep
81559$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
81560	$ac_comp
81561EOF
81562  done
81563
81564
81565        EXT_STATIC="$EXT_STATIC xml;$ext_dir"
81566        ;;
81567      *)
81568
81569
81570  case $ext_dir in
81571  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
81572  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
81573  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
81574  esac
81575
81576
81577
81578  b_c_pre=$php_c_pre
81579  b_cxx_pre=$php_cxx_pre
81580  b_c_meta=$php_c_meta
81581  b_cxx_meta=$php_cxx_meta
81582  b_c_post=$php_c_post
81583  b_cxx_post=$php_cxx_post
81584  b_lo=$php_lo
81585
81586
81587  old_IFS=$IFS
81588  for ac_src in xml.c $xml_extra_sources; do
81589
81590      IFS=.
81591      set $ac_src
81592      ac_obj=$1
81593      IFS=$old_IFS
81594
81595      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
81596
81597      case $ac_src in
81598        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81599        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81600        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81601        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
81602      esac
81603
81604      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
81605
81606    cat >>Makefile.objects<<EOF
81607-include $ac_bdir$ac_obj.dep
81608$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
81609	$ac_comp
81610EOF
81611  done
81612
81613
81614        ;;
81615    esac
81616    EXT_CLI_STATIC="$EXT_CLI_STATIC xml;$ext_dir"
81617  fi
81618
81619
81620    BUILD_DIR="$BUILD_DIR $ext_builddir"
81621
81622
81623
81624  if test "$ext_builddir" = "."; then
81625    PHP_PECL_EXTENSION=xml
81626
81627  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
81628
81629  fi
81630
81631
81632  PHP_VAR_SUBST="$PHP_VAR_SUBST XML_SHARED_LIBADD"
81633
81634
81635
81636    for header_file in ext/xml/; do
81637
81638
81639  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
81640
81641  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
81642  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81643    eval "INSTALLHEADERS$unique=set"
81644
81645        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
81646
81647  fi
81648
81649    done
81650
81651
81652
81653printf "%s\n" "#define HAVE_XML 1" >>confdefs.h
81654
81655fi
81656
81657
81658
81659
81660
81661php_enable_xmlreader=yes
81662
81663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable XMLReader support" >&5
81664printf %s "checking whether to enable XMLReader support... " >&6; }
81665# Check whether --enable-xmlreader was given.
81666if test ${enable_xmlreader+y}
81667then :
81668  enableval=$enable_xmlreader; PHP_XMLREADER=$enableval
81669else $as_nop
81670
81671  PHP_XMLREADER=yes
81672  test "$PHP_ENABLE_ALL" && PHP_XMLREADER=$PHP_ENABLE_ALL
81673
81674fi
81675
81676
81677
81678ext_output="yes, shared"
81679ext_shared=yes
81680case $PHP_XMLREADER in
81681shared,*)
81682  PHP_XMLREADER=`echo "$PHP_XMLREADER"|$SED 's/^shared,//'`
81683  ;;
81684shared)
81685  PHP_XMLREADER=yes
81686  ;;
81687no)
81688  ext_output=no
81689  ext_shared=no
81690  ;;
81691*)
81692  ext_output=yes
81693  ext_shared=no
81694  ;;
81695esac
81696
81697
81698
81699{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
81700printf "%s\n" "$ext_output" >&6; }
81701
81702
81703
81704
81705if test "$PHP_XMLREADER" != "no"; then
81706
81707  if test "$PHP_LIBXML" = "no"; then
81708    as_fn_error $? "XMLReader extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
81709  fi
81710
81711
81712
81713pkg_failed=no
81714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
81715printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
81716
81717if test -n "$LIBXML_CFLAGS"; then
81718    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
81719 elif test -n "$PKG_CONFIG"; then
81720    if test -n "$PKG_CONFIG" && \
81721    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
81722  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
81723  ac_status=$?
81724  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
81725  test $ac_status = 0; }; then
81726  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
81727		      test "x$?" != "x0" && pkg_failed=yes
81728else
81729  pkg_failed=yes
81730fi
81731 else
81732    pkg_failed=untried
81733fi
81734if test -n "$LIBXML_LIBS"; then
81735    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
81736 elif test -n "$PKG_CONFIG"; then
81737    if test -n "$PKG_CONFIG" && \
81738    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
81739  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
81740  ac_status=$?
81741  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
81742  test $ac_status = 0; }; then
81743  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
81744		      test "x$?" != "x0" && pkg_failed=yes
81745else
81746  pkg_failed=yes
81747fi
81748 else
81749    pkg_failed=untried
81750fi
81751
81752
81753
81754if test $pkg_failed = yes; then
81755        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
81756printf "%s\n" "no" >&6; }
81757
81758if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
81759        _pkg_short_errors_supported=yes
81760else
81761        _pkg_short_errors_supported=no
81762fi
81763        if test $_pkg_short_errors_supported = yes; then
81764	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
81765        else
81766	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
81767        fi
81768	# Put the nasty error message in config.log where it belongs
81769	echo "$LIBXML_PKG_ERRORS" >&5
81770
81771	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
81772
81773$LIBXML_PKG_ERRORS
81774
81775Consider adjusting the PKG_CONFIG_PATH environment variable if you
81776installed software in a non-standard prefix.
81777
81778Alternatively, you may set the environment variables LIBXML_CFLAGS
81779and LIBXML_LIBS to avoid the need to call pkg-config.
81780See the pkg-config man page for more details." "$LINENO" 5
81781elif test $pkg_failed = untried; then
81782        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
81783printf "%s\n" "no" >&6; }
81784	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
81785printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
81786as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
81787is in your PATH or set the PKG_CONFIG environment variable to the full
81788path to pkg-config.
81789
81790Alternatively, you may set the environment variables LIBXML_CFLAGS
81791and LIBXML_LIBS to avoid the need to call pkg-config.
81792See the pkg-config man page for more details.
81793
81794To get pkg-config, see <http://pkg-config.freedesktop.org/>.
81795See \`config.log' for more details" "$LINENO" 5; }
81796else
81797	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
81798	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
81799        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
81800printf "%s\n" "yes" >&6; }
81801
81802fi
81803
81804
81805  for ac_i in $LIBXML_CFLAGS; do
81806    case $ac_i in
81807    -I*)
81808      ac_ii=`echo $ac_i|cut -c 3-`
81809
81810  if test "$ac_ii" != "/usr/include"; then
81811
81812  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
81813    ai_p=$ac_ii
81814  else
81815
81816    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
81817
81818    ep_realdir=`(cd "$ep_dir" && pwd)`
81819    ai_p="$ep_realdir"/`basename "$ac_ii"`
81820  fi
81821
81822
81823
81824  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
81825
81826  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
81827  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81828    eval "INCLUDEPATH$unique=set"
81829
81830      if test ""; then
81831        INCLUDES="-I$ai_p $INCLUDES"
81832      else
81833        INCLUDES="$INCLUDES -I$ai_p"
81834      fi
81835
81836  fi
81837
81838  fi
81839
81840    ;;
81841    esac
81842  done
81843
81844
81845  for ac_i in $LIBXML_LIBS; do
81846    case $ac_i in
81847    -pthread)
81848      if test "$ext_shared" = "yes"; then
81849        XMLREADER_SHARED_LIBADD="$XMLREADER_SHARED_LIBADD -pthread"
81850      else
81851
81852
81853  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81854
81855  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
81856  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81857    eval "EXTRA_LDFLAGS$unique=set"
81858    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
81859  fi
81860
81861
81862
81863  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
81864
81865  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
81866  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81867    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
81868    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
81869  fi
81870
81871      fi
81872    ;;
81873    -l*)
81874      ac_ii=`echo $ac_i|cut -c 3-`
81875
81876
81877  case $ac_ii in
81878  c|c_r) ;;
81879  *)
81880    if test "$ext_shared" = "yes"; then
81881        XMLREADER_SHARED_LIBADD="$XMLREADER_SHARED_LIBADD -l$ac_ii"
81882    else
81883
81884
81885  case $ac_ii in
81886  c|c_r) ;;
81887  *)
81888      LIBS="$LIBS -l$ac_ii"
81889   ;;
81890  esac
81891
81892
81893    fi
81894   ;;
81895  esac
81896
81897
81898    ;;
81899    -L*)
81900      ac_ii=`echo $ac_i|cut -c 3-`
81901
81902  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
81903
81904  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
81905    ai_p=$ac_ii
81906  else
81907
81908    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
81909
81910    ep_realdir=`(cd "$ep_dir" && pwd)`
81911    ai_p="$ep_realdir"/`basename "$ac_ii"`
81912  fi
81913
81914
81915      if test "$ext_shared" = "yes"; then
81916        XMLREADER_SHARED_LIBADD="-L$ai_p $XMLREADER_SHARED_LIBADD"
81917        test -n "$ld_runpath_switch" && XMLREADER_SHARED_LIBADD="$ld_runpath_switch$ai_p $XMLREADER_SHARED_LIBADD"
81918      else
81919
81920
81921
81922  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
81923
81924  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
81925  if test -n "$unique" && test "`eval $cmd`" = "" ; then
81926    eval "LIBPATH$unique=set"
81927
81928    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
81929    LDFLAGS="$LDFLAGS -L$ai_p"
81930    PHP_RPATHS="$PHP_RPATHS $ai_p"
81931
81932  fi
81933
81934
81935      fi
81936
81937  fi
81938
81939    ;;
81940    esac
81941  done
81942
81943
81944
81945printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
81946
81947
81948
81949
81950printf "%s\n" "#define HAVE_XMLREADER 1" >>confdefs.h
81951
81952
81953  ext_builddir=ext/xmlreader
81954  ext_srcdir=$abs_srcdir/ext/xmlreader
81955  ext_dir=ext/xmlreader
81956
81957  ac_extra=
81958
81959  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
81960    PHP_XMLREADER_SHARED=no
81961
81962
81963  case $ext_dir in
81964  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
81965  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
81966  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
81967  esac
81968
81969
81970
81971  b_c_pre=$php_c_pre
81972  b_cxx_pre=$php_cxx_pre
81973  b_c_meta=$php_c_meta
81974  b_cxx_meta=$php_cxx_meta
81975  b_c_post=$php_c_post
81976  b_cxx_post=$php_cxx_post
81977  b_lo=$php_lo
81978
81979
81980  old_IFS=$IFS
81981  for ac_src in php_xmlreader.c; do
81982
81983      IFS=.
81984      set $ac_src
81985      ac_obj=$1
81986      IFS=$old_IFS
81987
81988      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
81989
81990      case $ac_src in
81991        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81992        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81993        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
81994        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
81995      esac
81996
81997      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
81998
81999    cat >>Makefile.objects<<EOF
82000-include $ac_bdir$ac_obj.dep
82001$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82002	$ac_comp
82003EOF
82004  done
82005
82006
82007    EXT_STATIC="$EXT_STATIC xmlreader;$ext_dir"
82008    if test "$ext_shared" != "nocli"; then
82009      EXT_CLI_STATIC="$EXT_CLI_STATIC xmlreader;$ext_dir"
82010    fi
82011  else
82012    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
82013      PHP_XMLREADER_SHARED=yes
82014
82015  case $ext_dir in
82016  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82017  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82018  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82019  esac
82020
82021
82022
82023  b_c_pre=$shared_c_pre
82024  b_cxx_pre=$shared_cxx_pre
82025  b_c_meta=$shared_c_meta
82026  b_cxx_meta=$shared_cxx_meta
82027  b_c_post=$shared_c_post
82028  b_cxx_post=$shared_cxx_post
82029  b_lo=$shared_lo
82030
82031
82032  old_IFS=$IFS
82033  for ac_src in php_xmlreader.c; do
82034
82035      IFS=.
82036      set $ac_src
82037      ac_obj=$1
82038      IFS=$old_IFS
82039
82040      shared_objects_xmlreader="$shared_objects_xmlreader $ac_bdir$ac_obj.lo"
82041
82042      case $ac_src in
82043        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82044        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82045        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82046        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82047      esac
82048
82049      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82050
82051    cat >>Makefile.objects<<EOF
82052-include $ac_bdir$ac_obj.dep
82053$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82054	$ac_comp
82055EOF
82056  done
82057
82058
82059  install_modules="install-modules"
82060  suffix=la
82061
82062  case $host_alias in
82063    *aix*)
82064      additional_flags="-Wl,-G"
82065      ;;
82066  esac
82067
82068  if test "x" = "xyes"; then
82069    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/xmlreader.$suffix"
82070  else
82071    PHP_MODULES="$PHP_MODULES \$(phplibdir)/xmlreader.$suffix"
82072  fi
82073
82074  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_xmlreader"
82075
82076  cat >>Makefile.objects<<EOF
82077\$(phplibdir)/xmlreader.$suffix: $ext_builddir/xmlreader.$suffix
82078	\$(LIBTOOL) --mode=install cp $ext_builddir/xmlreader.$suffix \$(phplibdir)
82079
82080$ext_builddir/xmlreader.$suffix: \$(shared_objects_xmlreader) \$(XMLREADER_SHARED_DEPENDENCIES)
82081	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_xmlreader) \$(XMLREADER_SHARED_LIBADD)
82082
82083EOF
82084
82085
82086printf "%s\n" "#define COMPILE_DL_XMLREADER 1" >>confdefs.h
82087
82088    fi
82089  fi
82090
82091  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
82092    PHP_XMLREADER_SHARED=no
82093    case "$PHP_SAPI" in
82094      cgi|embed|phpdbg)
82095
82096
82097  case $ext_dir in
82098  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82099  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82100  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82101  esac
82102
82103
82104
82105  b_c_pre=$php_c_pre
82106  b_cxx_pre=$php_cxx_pre
82107  b_c_meta=$php_c_meta
82108  b_cxx_meta=$php_cxx_meta
82109  b_c_post=$php_c_post
82110  b_cxx_post=$php_cxx_post
82111  b_lo=$php_lo
82112
82113
82114  old_IFS=$IFS
82115  for ac_src in php_xmlreader.c; do
82116
82117      IFS=.
82118      set $ac_src
82119      ac_obj=$1
82120      IFS=$old_IFS
82121
82122      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
82123
82124      case $ac_src in
82125        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82126        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82127        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82128        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82129      esac
82130
82131      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82132
82133    cat >>Makefile.objects<<EOF
82134-include $ac_bdir$ac_obj.dep
82135$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82136	$ac_comp
82137EOF
82138  done
82139
82140
82141        EXT_STATIC="$EXT_STATIC xmlreader;$ext_dir"
82142        ;;
82143      *)
82144
82145
82146  case $ext_dir in
82147  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82148  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82149  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82150  esac
82151
82152
82153
82154  b_c_pre=$php_c_pre
82155  b_cxx_pre=$php_cxx_pre
82156  b_c_meta=$php_c_meta
82157  b_cxx_meta=$php_cxx_meta
82158  b_c_post=$php_c_post
82159  b_cxx_post=$php_cxx_post
82160  b_lo=$php_lo
82161
82162
82163  old_IFS=$IFS
82164  for ac_src in php_xmlreader.c; do
82165
82166      IFS=.
82167      set $ac_src
82168      ac_obj=$1
82169      IFS=$old_IFS
82170
82171      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
82172
82173      case $ac_src in
82174        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82175        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82176        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82177        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82178      esac
82179
82180      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82181
82182    cat >>Makefile.objects<<EOF
82183-include $ac_bdir$ac_obj.dep
82184$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82185	$ac_comp
82186EOF
82187  done
82188
82189
82190        ;;
82191    esac
82192    EXT_CLI_STATIC="$EXT_CLI_STATIC xmlreader;$ext_dir"
82193  fi
82194
82195
82196    BUILD_DIR="$BUILD_DIR $ext_builddir"
82197
82198
82199
82200  if test "$ext_builddir" = "."; then
82201    PHP_PECL_EXTENSION=xmlreader
82202
82203  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
82204
82205  fi
82206
82207
82208  am_i_shared=$PHP_XMLREADER_SHARED
82209  is_it_shared=$PHP_DOM_SHARED
82210  is_it_enabled=$PHP_DOM
82211  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
82212    as_fn_error $? "
82213You've configured extension xmlreader to build statically, but it
82214depends on extension dom, which you've configured to build shared.
82215You either need to build xmlreader shared or build dom statically for the
82216build to be successful.
82217" "$LINENO" 5
82218  fi
82219  if test "x$is_it_enabled" = "xno" && test "xtrue" != "xtrue"; then
82220    as_fn_error $? "
82221You've configured extension xmlreader, which depends on extension dom,
82222but you've either not enabled dom, or have disabled it.
82223" "$LINENO" 5
82224  fi
82225
82226
82227  PHP_VAR_SUBST="$PHP_VAR_SUBST XMLREADER_SHARED_LIBADD"
82228
82229
82230
82231fi
82232
82233
82234
82235
82236
82237php_enable_xmlwriter=yes
82238
82239{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable XMLWriter support" >&5
82240printf %s "checking whether to enable XMLWriter support... " >&6; }
82241# Check whether --enable-xmlwriter was given.
82242if test ${enable_xmlwriter+y}
82243then :
82244  enableval=$enable_xmlwriter; PHP_XMLWRITER=$enableval
82245else $as_nop
82246
82247  PHP_XMLWRITER=yes
82248  test "$PHP_ENABLE_ALL" && PHP_XMLWRITER=$PHP_ENABLE_ALL
82249
82250fi
82251
82252
82253
82254ext_output="yes, shared"
82255ext_shared=yes
82256case $PHP_XMLWRITER in
82257shared,*)
82258  PHP_XMLWRITER=`echo "$PHP_XMLWRITER"|$SED 's/^shared,//'`
82259  ;;
82260shared)
82261  PHP_XMLWRITER=yes
82262  ;;
82263no)
82264  ext_output=no
82265  ext_shared=no
82266  ;;
82267*)
82268  ext_output=yes
82269  ext_shared=no
82270  ;;
82271esac
82272
82273
82274
82275{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
82276printf "%s\n" "$ext_output" >&6; }
82277
82278
82279
82280
82281if test "$PHP_XMLWRITER" != "no"; then
82282
82283  if test "$PHP_LIBXML" = "no"; then
82284    as_fn_error $? "XMLWriter extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
82285  fi
82286
82287
82288
82289pkg_failed=no
82290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 >= 2.9.0" >&5
82291printf %s "checking for libxml-2.0 >= 2.9.0... " >&6; }
82292
82293if test -n "$LIBXML_CFLAGS"; then
82294    pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
82295 elif test -n "$PKG_CONFIG"; then
82296    if test -n "$PKG_CONFIG" && \
82297    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
82298  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
82299  ac_status=$?
82300  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
82301  test $ac_status = 0; }; then
82302  pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= 2.9.0" 2>/dev/null`
82303		      test "x$?" != "x0" && pkg_failed=yes
82304else
82305  pkg_failed=yes
82306fi
82307 else
82308    pkg_failed=untried
82309fi
82310if test -n "$LIBXML_LIBS"; then
82311    pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
82312 elif test -n "$PKG_CONFIG"; then
82313    if test -n "$PKG_CONFIG" && \
82314    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= 2.9.0\""; } >&5
82315  ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= 2.9.0") 2>&5
82316  ac_status=$?
82317  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
82318  test $ac_status = 0; }; then
82319  pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= 2.9.0" 2>/dev/null`
82320		      test "x$?" != "x0" && pkg_failed=yes
82321else
82322  pkg_failed=yes
82323fi
82324 else
82325    pkg_failed=untried
82326fi
82327
82328
82329
82330if test $pkg_failed = yes; then
82331        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
82332printf "%s\n" "no" >&6; }
82333
82334if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
82335        _pkg_short_errors_supported=yes
82336else
82337        _pkg_short_errors_supported=no
82338fi
82339        if test $_pkg_short_errors_supported = yes; then
82340	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
82341        else
82342	        LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= 2.9.0" 2>&1`
82343        fi
82344	# Put the nasty error message in config.log where it belongs
82345	echo "$LIBXML_PKG_ERRORS" >&5
82346
82347	as_fn_error $? "Package requirements (libxml-2.0 >= 2.9.0) were not met:
82348
82349$LIBXML_PKG_ERRORS
82350
82351Consider adjusting the PKG_CONFIG_PATH environment variable if you
82352installed software in a non-standard prefix.
82353
82354Alternatively, you may set the environment variables LIBXML_CFLAGS
82355and LIBXML_LIBS to avoid the need to call pkg-config.
82356See the pkg-config man page for more details." "$LINENO" 5
82357elif test $pkg_failed = untried; then
82358        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
82359printf "%s\n" "no" >&6; }
82360	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
82361printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
82362as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
82363is in your PATH or set the PKG_CONFIG environment variable to the full
82364path to pkg-config.
82365
82366Alternatively, you may set the environment variables LIBXML_CFLAGS
82367and LIBXML_LIBS to avoid the need to call pkg-config.
82368See the pkg-config man page for more details.
82369
82370To get pkg-config, see <http://pkg-config.freedesktop.org/>.
82371See \`config.log' for more details" "$LINENO" 5; }
82372else
82373	LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
82374	LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
82375        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
82376printf "%s\n" "yes" >&6; }
82377
82378fi
82379
82380
82381  for ac_i in $LIBXML_CFLAGS; do
82382    case $ac_i in
82383    -I*)
82384      ac_ii=`echo $ac_i|cut -c 3-`
82385
82386  if test "$ac_ii" != "/usr/include"; then
82387
82388  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
82389    ai_p=$ac_ii
82390  else
82391
82392    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
82393
82394    ep_realdir=`(cd "$ep_dir" && pwd)`
82395    ai_p="$ep_realdir"/`basename "$ac_ii"`
82396  fi
82397
82398
82399
82400  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
82401
82402  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
82403  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82404    eval "INCLUDEPATH$unique=set"
82405
82406      if test ""; then
82407        INCLUDES="-I$ai_p $INCLUDES"
82408      else
82409        INCLUDES="$INCLUDES -I$ai_p"
82410      fi
82411
82412  fi
82413
82414  fi
82415
82416    ;;
82417    esac
82418  done
82419
82420
82421  for ac_i in $LIBXML_LIBS; do
82422    case $ac_i in
82423    -pthread)
82424      if test "$ext_shared" = "yes"; then
82425        XMLWRITER_SHARED_LIBADD="$XMLWRITER_SHARED_LIBADD -pthread"
82426      else
82427
82428
82429  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
82430
82431  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
82432  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82433    eval "EXTRA_LDFLAGS$unique=set"
82434    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
82435  fi
82436
82437
82438
82439  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
82440
82441  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
82442  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82443    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
82444    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
82445  fi
82446
82447      fi
82448    ;;
82449    -l*)
82450      ac_ii=`echo $ac_i|cut -c 3-`
82451
82452
82453  case $ac_ii in
82454  c|c_r) ;;
82455  *)
82456    if test "$ext_shared" = "yes"; then
82457        XMLWRITER_SHARED_LIBADD="$XMLWRITER_SHARED_LIBADD -l$ac_ii"
82458    else
82459
82460
82461  case $ac_ii in
82462  c|c_r) ;;
82463  *)
82464      LIBS="$LIBS -l$ac_ii"
82465   ;;
82466  esac
82467
82468
82469    fi
82470   ;;
82471  esac
82472
82473
82474    ;;
82475    -L*)
82476      ac_ii=`echo $ac_i|cut -c 3-`
82477
82478  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
82479
82480  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
82481    ai_p=$ac_ii
82482  else
82483
82484    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
82485
82486    ep_realdir=`(cd "$ep_dir" && pwd)`
82487    ai_p="$ep_realdir"/`basename "$ac_ii"`
82488  fi
82489
82490
82491      if test "$ext_shared" = "yes"; then
82492        XMLWRITER_SHARED_LIBADD="-L$ai_p $XMLWRITER_SHARED_LIBADD"
82493        test -n "$ld_runpath_switch" && XMLWRITER_SHARED_LIBADD="$ld_runpath_switch$ai_p $XMLWRITER_SHARED_LIBADD"
82494      else
82495
82496
82497
82498  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
82499
82500  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
82501  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82502    eval "LIBPATH$unique=set"
82503
82504    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
82505    LDFLAGS="$LDFLAGS -L$ai_p"
82506    PHP_RPATHS="$PHP_RPATHS $ai_p"
82507
82508  fi
82509
82510
82511      fi
82512
82513  fi
82514
82515    ;;
82516    esac
82517  done
82518
82519
82520
82521printf "%s\n" "#define HAVE_LIBXML 1" >>confdefs.h
82522
82523
82524
82525
82526printf "%s\n" "#define HAVE_XMLWRITER 1" >>confdefs.h
82527
82528
82529  ext_builddir=ext/xmlwriter
82530  ext_srcdir=$abs_srcdir/ext/xmlwriter
82531  ext_dir=ext/xmlwriter
82532
82533  ac_extra=
82534
82535  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
82536    PHP_XMLWRITER_SHARED=no
82537
82538
82539  case $ext_dir in
82540  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82541  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82542  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82543  esac
82544
82545
82546
82547  b_c_pre=$php_c_pre
82548  b_cxx_pre=$php_cxx_pre
82549  b_c_meta=$php_c_meta
82550  b_cxx_meta=$php_cxx_meta
82551  b_c_post=$php_c_post
82552  b_cxx_post=$php_cxx_post
82553  b_lo=$php_lo
82554
82555
82556  old_IFS=$IFS
82557  for ac_src in php_xmlwriter.c; do
82558
82559      IFS=.
82560      set $ac_src
82561      ac_obj=$1
82562      IFS=$old_IFS
82563
82564      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
82565
82566      case $ac_src in
82567        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82568        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82569        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82570        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82571      esac
82572
82573      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82574
82575    cat >>Makefile.objects<<EOF
82576-include $ac_bdir$ac_obj.dep
82577$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82578	$ac_comp
82579EOF
82580  done
82581
82582
82583    EXT_STATIC="$EXT_STATIC xmlwriter;$ext_dir"
82584    if test "$ext_shared" != "nocli"; then
82585      EXT_CLI_STATIC="$EXT_CLI_STATIC xmlwriter;$ext_dir"
82586    fi
82587  else
82588    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
82589      PHP_XMLWRITER_SHARED=yes
82590
82591  case $ext_dir in
82592  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82593  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82594  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82595  esac
82596
82597
82598
82599  b_c_pre=$shared_c_pre
82600  b_cxx_pre=$shared_cxx_pre
82601  b_c_meta=$shared_c_meta
82602  b_cxx_meta=$shared_cxx_meta
82603  b_c_post=$shared_c_post
82604  b_cxx_post=$shared_cxx_post
82605  b_lo=$shared_lo
82606
82607
82608  old_IFS=$IFS
82609  for ac_src in php_xmlwriter.c; do
82610
82611      IFS=.
82612      set $ac_src
82613      ac_obj=$1
82614      IFS=$old_IFS
82615
82616      shared_objects_xmlwriter="$shared_objects_xmlwriter $ac_bdir$ac_obj.lo"
82617
82618      case $ac_src in
82619        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82620        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82621        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82622        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82623      esac
82624
82625      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82626
82627    cat >>Makefile.objects<<EOF
82628-include $ac_bdir$ac_obj.dep
82629$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82630	$ac_comp
82631EOF
82632  done
82633
82634
82635  install_modules="install-modules"
82636  suffix=la
82637
82638  case $host_alias in
82639    *aix*)
82640      additional_flags="-Wl,-G"
82641      ;;
82642  esac
82643
82644  if test "x" = "xyes"; then
82645    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/xmlwriter.$suffix"
82646  else
82647    PHP_MODULES="$PHP_MODULES \$(phplibdir)/xmlwriter.$suffix"
82648  fi
82649
82650  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_xmlwriter"
82651
82652  cat >>Makefile.objects<<EOF
82653\$(phplibdir)/xmlwriter.$suffix: $ext_builddir/xmlwriter.$suffix
82654	\$(LIBTOOL) --mode=install cp $ext_builddir/xmlwriter.$suffix \$(phplibdir)
82655
82656$ext_builddir/xmlwriter.$suffix: \$(shared_objects_xmlwriter) \$(XMLWRITER_SHARED_DEPENDENCIES)
82657	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_xmlwriter) \$(XMLWRITER_SHARED_LIBADD)
82658
82659EOF
82660
82661
82662printf "%s\n" "#define COMPILE_DL_XMLWRITER 1" >>confdefs.h
82663
82664    fi
82665  fi
82666
82667  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
82668    PHP_XMLWRITER_SHARED=no
82669    case "$PHP_SAPI" in
82670      cgi|embed|phpdbg)
82671
82672
82673  case $ext_dir in
82674  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82675  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82676  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82677  esac
82678
82679
82680
82681  b_c_pre=$php_c_pre
82682  b_cxx_pre=$php_cxx_pre
82683  b_c_meta=$php_c_meta
82684  b_cxx_meta=$php_cxx_meta
82685  b_c_post=$php_c_post
82686  b_cxx_post=$php_cxx_post
82687  b_lo=$php_lo
82688
82689
82690  old_IFS=$IFS
82691  for ac_src in php_xmlwriter.c; do
82692
82693      IFS=.
82694      set $ac_src
82695      ac_obj=$1
82696      IFS=$old_IFS
82697
82698      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
82699
82700      case $ac_src in
82701        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82702        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82703        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82704        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82705      esac
82706
82707      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82708
82709    cat >>Makefile.objects<<EOF
82710-include $ac_bdir$ac_obj.dep
82711$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82712	$ac_comp
82713EOF
82714  done
82715
82716
82717        EXT_STATIC="$EXT_STATIC xmlwriter;$ext_dir"
82718        ;;
82719      *)
82720
82721
82722  case $ext_dir in
82723  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
82724  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
82725  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
82726  esac
82727
82728
82729
82730  b_c_pre=$php_c_pre
82731  b_cxx_pre=$php_cxx_pre
82732  b_c_meta=$php_c_meta
82733  b_cxx_meta=$php_cxx_meta
82734  b_c_post=$php_c_post
82735  b_cxx_post=$php_cxx_post
82736  b_lo=$php_lo
82737
82738
82739  old_IFS=$IFS
82740  for ac_src in php_xmlwriter.c; do
82741
82742      IFS=.
82743      set $ac_src
82744      ac_obj=$1
82745      IFS=$old_IFS
82746
82747      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
82748
82749      case $ac_src in
82750        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82751        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82752        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
82753        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
82754      esac
82755
82756      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
82757
82758    cat >>Makefile.objects<<EOF
82759-include $ac_bdir$ac_obj.dep
82760$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
82761	$ac_comp
82762EOF
82763  done
82764
82765
82766        ;;
82767    esac
82768    EXT_CLI_STATIC="$EXT_CLI_STATIC xmlwriter;$ext_dir"
82769  fi
82770
82771
82772    BUILD_DIR="$BUILD_DIR $ext_builddir"
82773
82774
82775
82776  if test "$ext_builddir" = "."; then
82777    PHP_PECL_EXTENSION=xmlwriter
82778
82779  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
82780
82781  fi
82782
82783
82784  PHP_VAR_SUBST="$PHP_VAR_SUBST XMLWRITER_SHARED_LIBADD"
82785
82786
82787
82788fi
82789
82790
82791
82792
82793
82794php_with_xsl=no
82795
82796{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build with XSL support" >&5
82797printf %s "checking whether to build with XSL support... " >&6; }
82798
82799# Check whether --with-xsl was given.
82800if test ${with_xsl+y}
82801then :
82802  withval=$with_xsl; PHP_XSL=$withval
82803else $as_nop
82804
82805  PHP_XSL=no
82806  test "$PHP_ENABLE_ALL" && PHP_XSL=$PHP_ENABLE_ALL
82807
82808fi
82809
82810
82811
82812ext_output="yes, shared"
82813ext_shared=yes
82814case $PHP_XSL in
82815shared,*)
82816  PHP_XSL=`echo "$PHP_XSL"|$SED 's/^shared,//'`
82817  ;;
82818shared)
82819  PHP_XSL=yes
82820  ;;
82821no)
82822  ext_output=no
82823  ext_shared=no
82824  ;;
82825*)
82826  ext_output=yes
82827  ext_shared=no
82828  ;;
82829esac
82830
82831
82832
82833{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
82834printf "%s\n" "$ext_output" >&6; }
82835
82836
82837
82838
82839if test "$PHP_XSL" != "no"; then
82840
82841  if test "$PHP_LIBXML" = "no"; then
82842    as_fn_error $? "XSL extension requires LIBXML extension, add --with-libxml" "$LINENO" 5
82843  fi
82844
82845  if test "$PHP_DOM" = "no"; then
82846    as_fn_error $? "XSL extension requires DOM extension, add --enable-dom" "$LINENO" 5
82847  fi
82848
82849
82850pkg_failed=no
82851{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libxslt >= 1.1.0" >&5
82852printf %s "checking for libxslt >= 1.1.0... " >&6; }
82853
82854if test -n "$XSL_CFLAGS"; then
82855    pkg_cv_XSL_CFLAGS="$XSL_CFLAGS"
82856 elif test -n "$PKG_CONFIG"; then
82857    if test -n "$PKG_CONFIG" && \
82858    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxslt >= 1.1.0\""; } >&5
82859  ($PKG_CONFIG --exists --print-errors "libxslt >= 1.1.0") 2>&5
82860  ac_status=$?
82861  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
82862  test $ac_status = 0; }; then
82863  pkg_cv_XSL_CFLAGS=`$PKG_CONFIG --cflags "libxslt >= 1.1.0" 2>/dev/null`
82864		      test "x$?" != "x0" && pkg_failed=yes
82865else
82866  pkg_failed=yes
82867fi
82868 else
82869    pkg_failed=untried
82870fi
82871if test -n "$XSL_LIBS"; then
82872    pkg_cv_XSL_LIBS="$XSL_LIBS"
82873 elif test -n "$PKG_CONFIG"; then
82874    if test -n "$PKG_CONFIG" && \
82875    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxslt >= 1.1.0\""; } >&5
82876  ($PKG_CONFIG --exists --print-errors "libxslt >= 1.1.0") 2>&5
82877  ac_status=$?
82878  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
82879  test $ac_status = 0; }; then
82880  pkg_cv_XSL_LIBS=`$PKG_CONFIG --libs "libxslt >= 1.1.0" 2>/dev/null`
82881		      test "x$?" != "x0" && pkg_failed=yes
82882else
82883  pkg_failed=yes
82884fi
82885 else
82886    pkg_failed=untried
82887fi
82888
82889
82890
82891if test $pkg_failed = yes; then
82892        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
82893printf "%s\n" "no" >&6; }
82894
82895if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
82896        _pkg_short_errors_supported=yes
82897else
82898        _pkg_short_errors_supported=no
82899fi
82900        if test $_pkg_short_errors_supported = yes; then
82901	        XSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxslt >= 1.1.0" 2>&1`
82902        else
82903	        XSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxslt >= 1.1.0" 2>&1`
82904        fi
82905	# Put the nasty error message in config.log where it belongs
82906	echo "$XSL_PKG_ERRORS" >&5
82907
82908	as_fn_error $? "Package requirements (libxslt >= 1.1.0) were not met:
82909
82910$XSL_PKG_ERRORS
82911
82912Consider adjusting the PKG_CONFIG_PATH environment variable if you
82913installed software in a non-standard prefix.
82914
82915Alternatively, you may set the environment variables XSL_CFLAGS
82916and XSL_LIBS to avoid the need to call pkg-config.
82917See the pkg-config man page for more details." "$LINENO" 5
82918elif test $pkg_failed = untried; then
82919        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
82920printf "%s\n" "no" >&6; }
82921	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
82922printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
82923as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
82924is in your PATH or set the PKG_CONFIG environment variable to the full
82925path to pkg-config.
82926
82927Alternatively, you may set the environment variables XSL_CFLAGS
82928and XSL_LIBS to avoid the need to call pkg-config.
82929See the pkg-config man page for more details.
82930
82931To get pkg-config, see <http://pkg-config.freedesktop.org/>.
82932See \`config.log' for more details" "$LINENO" 5; }
82933else
82934	XSL_CFLAGS=$pkg_cv_XSL_CFLAGS
82935	XSL_LIBS=$pkg_cv_XSL_LIBS
82936        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
82937printf "%s\n" "yes" >&6; }
82938
82939fi
82940
82941
82942  for ac_i in $XSL_CFLAGS; do
82943    case $ac_i in
82944    -I*)
82945      ac_ii=`echo $ac_i|cut -c 3-`
82946
82947  if test "$ac_ii" != "/usr/include"; then
82948
82949  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
82950    ai_p=$ac_ii
82951  else
82952
82953    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
82954
82955    ep_realdir=`(cd "$ep_dir" && pwd)`
82956    ai_p="$ep_realdir"/`basename "$ac_ii"`
82957  fi
82958
82959
82960
82961  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
82962
82963  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
82964  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82965    eval "INCLUDEPATH$unique=set"
82966
82967      if test ""; then
82968        INCLUDES="-I$ai_p $INCLUDES"
82969      else
82970        INCLUDES="$INCLUDES -I$ai_p"
82971      fi
82972
82973  fi
82974
82975  fi
82976
82977    ;;
82978    esac
82979  done
82980
82981
82982  for ac_i in $XSL_LIBS; do
82983    case $ac_i in
82984    -pthread)
82985      if test "$ext_shared" = "yes"; then
82986        XSL_SHARED_LIBADD="$XSL_SHARED_LIBADD -pthread"
82987      else
82988
82989
82990  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
82991
82992  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
82993  if test -n "$unique" && test "`eval $cmd`" = "" ; then
82994    eval "EXTRA_LDFLAGS$unique=set"
82995    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
82996  fi
82997
82998
82999
83000  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
83001
83002  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
83003  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83004    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
83005    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
83006  fi
83007
83008      fi
83009    ;;
83010    -l*)
83011      ac_ii=`echo $ac_i|cut -c 3-`
83012
83013
83014  case $ac_ii in
83015  c|c_r) ;;
83016  *)
83017    if test "$ext_shared" = "yes"; then
83018        XSL_SHARED_LIBADD="$XSL_SHARED_LIBADD -l$ac_ii"
83019    else
83020
83021
83022  case $ac_ii in
83023  c|c_r) ;;
83024  *)
83025      LIBS="$LIBS -l$ac_ii"
83026   ;;
83027  esac
83028
83029
83030    fi
83031   ;;
83032  esac
83033
83034
83035    ;;
83036    -L*)
83037      ac_ii=`echo $ac_i|cut -c 3-`
83038
83039  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
83040
83041  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
83042    ai_p=$ac_ii
83043  else
83044
83045    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
83046
83047    ep_realdir=`(cd "$ep_dir" && pwd)`
83048    ai_p="$ep_realdir"/`basename "$ac_ii"`
83049  fi
83050
83051
83052      if test "$ext_shared" = "yes"; then
83053        XSL_SHARED_LIBADD="-L$ai_p $XSL_SHARED_LIBADD"
83054        test -n "$ld_runpath_switch" && XSL_SHARED_LIBADD="$ld_runpath_switch$ai_p $XSL_SHARED_LIBADD"
83055      else
83056
83057
83058
83059  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
83060
83061  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
83062  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83063    eval "LIBPATH$unique=set"
83064
83065    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
83066    LDFLAGS="$LDFLAGS -L$ai_p"
83067    PHP_RPATHS="$PHP_RPATHS $ai_p"
83068
83069  fi
83070
83071
83072      fi
83073
83074  fi
83075
83076    ;;
83077    esac
83078  done
83079
83080
83081
83082pkg_failed=no
83083{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libexslt" >&5
83084printf %s "checking for libexslt... " >&6; }
83085
83086if test -n "$EXSLT_CFLAGS"; then
83087    pkg_cv_EXSLT_CFLAGS="$EXSLT_CFLAGS"
83088 elif test -n "$PKG_CONFIG"; then
83089    if test -n "$PKG_CONFIG" && \
83090    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libexslt\""; } >&5
83091  ($PKG_CONFIG --exists --print-errors "libexslt") 2>&5
83092  ac_status=$?
83093  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
83094  test $ac_status = 0; }; then
83095  pkg_cv_EXSLT_CFLAGS=`$PKG_CONFIG --cflags "libexslt" 2>/dev/null`
83096		      test "x$?" != "x0" && pkg_failed=yes
83097else
83098  pkg_failed=yes
83099fi
83100 else
83101    pkg_failed=untried
83102fi
83103if test -n "$EXSLT_LIBS"; then
83104    pkg_cv_EXSLT_LIBS="$EXSLT_LIBS"
83105 elif test -n "$PKG_CONFIG"; then
83106    if test -n "$PKG_CONFIG" && \
83107    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libexslt\""; } >&5
83108  ($PKG_CONFIG --exists --print-errors "libexslt") 2>&5
83109  ac_status=$?
83110  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
83111  test $ac_status = 0; }; then
83112  pkg_cv_EXSLT_LIBS=`$PKG_CONFIG --libs "libexslt" 2>/dev/null`
83113		      test "x$?" != "x0" && pkg_failed=yes
83114else
83115  pkg_failed=yes
83116fi
83117 else
83118    pkg_failed=untried
83119fi
83120
83121
83122
83123if test $pkg_failed = yes; then
83124        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
83125printf "%s\n" "no" >&6; }
83126
83127if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
83128        _pkg_short_errors_supported=yes
83129else
83130        _pkg_short_errors_supported=no
83131fi
83132        if test $_pkg_short_errors_supported = yes; then
83133	        EXSLT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libexslt" 2>&1`
83134        else
83135	        EXSLT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libexslt" 2>&1`
83136        fi
83137	# Put the nasty error message in config.log where it belongs
83138	echo "$EXSLT_PKG_ERRORS" >&5
83139
83140
83141elif test $pkg_failed = untried; then
83142        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
83143printf "%s\n" "no" >&6; }
83144
83145else
83146	EXSLT_CFLAGS=$pkg_cv_EXSLT_CFLAGS
83147	EXSLT_LIBS=$pkg_cv_EXSLT_LIBS
83148        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
83149printf "%s\n" "yes" >&6; }
83150
83151
83152  for ac_i in $EXSLT_CFLAGS; do
83153    case $ac_i in
83154    -I*)
83155      ac_ii=`echo $ac_i|cut -c 3-`
83156
83157  if test "$ac_ii" != "/usr/include"; then
83158
83159  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
83160    ai_p=$ac_ii
83161  else
83162
83163    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
83164
83165    ep_realdir=`(cd "$ep_dir" && pwd)`
83166    ai_p="$ep_realdir"/`basename "$ac_ii"`
83167  fi
83168
83169
83170
83171  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
83172
83173  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
83174  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83175    eval "INCLUDEPATH$unique=set"
83176
83177      if test ""; then
83178        INCLUDES="-I$ai_p $INCLUDES"
83179      else
83180        INCLUDES="$INCLUDES -I$ai_p"
83181      fi
83182
83183  fi
83184
83185  fi
83186
83187    ;;
83188    esac
83189  done
83190
83191
83192  for ac_i in $EXSLT_LIBS; do
83193    case $ac_i in
83194    -pthread)
83195      if test "$ext_shared" = "yes"; then
83196        XSL_SHARED_LIBADD="$XSL_SHARED_LIBADD -pthread"
83197      else
83198
83199
83200  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
83201
83202  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
83203  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83204    eval "EXTRA_LDFLAGS$unique=set"
83205    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
83206  fi
83207
83208
83209
83210  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
83211
83212  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
83213  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83214    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
83215    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
83216  fi
83217
83218      fi
83219    ;;
83220    -l*)
83221      ac_ii=`echo $ac_i|cut -c 3-`
83222
83223
83224  case $ac_ii in
83225  c|c_r) ;;
83226  *)
83227    if test "$ext_shared" = "yes"; then
83228        XSL_SHARED_LIBADD="$XSL_SHARED_LIBADD -l$ac_ii"
83229    else
83230
83231
83232  case $ac_ii in
83233  c|c_r) ;;
83234  *)
83235      LIBS="$LIBS -l$ac_ii"
83236   ;;
83237  esac
83238
83239
83240    fi
83241   ;;
83242  esac
83243
83244
83245    ;;
83246    -L*)
83247      ac_ii=`echo $ac_i|cut -c 3-`
83248
83249  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
83250
83251  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
83252    ai_p=$ac_ii
83253  else
83254
83255    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
83256
83257    ep_realdir=`(cd "$ep_dir" && pwd)`
83258    ai_p="$ep_realdir"/`basename "$ac_ii"`
83259  fi
83260
83261
83262      if test "$ext_shared" = "yes"; then
83263        XSL_SHARED_LIBADD="-L$ai_p $XSL_SHARED_LIBADD"
83264        test -n "$ld_runpath_switch" && XSL_SHARED_LIBADD="$ld_runpath_switch$ai_p $XSL_SHARED_LIBADD"
83265      else
83266
83267
83268
83269  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
83270
83271  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
83272  if test -n "$unique" && test "`eval $cmd`" = "" ; then
83273    eval "LIBPATH$unique=set"
83274
83275    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
83276    LDFLAGS="$LDFLAGS -L$ai_p"
83277    PHP_RPATHS="$PHP_RPATHS $ai_p"
83278
83279  fi
83280
83281
83282      fi
83283
83284  fi
83285
83286    ;;
83287    esac
83288  done
83289
83290
83291printf "%s\n" "#define HAVE_XSL_EXSLT 1" >>confdefs.h
83292
83293
83294fi
83295
83296
83297printf "%s\n" "#define HAVE_XSL 1" >>confdefs.h
83298
83299
83300  ext_builddir=ext/xsl
83301  ext_srcdir=$abs_srcdir/ext/xsl
83302  ext_dir=ext/xsl
83303
83304  ac_extra=
83305
83306  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
83307    PHP_XSL_SHARED=no
83308
83309
83310  case $ext_dir in
83311  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83312  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83313  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83314  esac
83315
83316
83317
83318  b_c_pre=$php_c_pre
83319  b_cxx_pre=$php_cxx_pre
83320  b_c_meta=$php_c_meta
83321  b_cxx_meta=$php_cxx_meta
83322  b_c_post=$php_c_post
83323  b_cxx_post=$php_cxx_post
83324  b_lo=$php_lo
83325
83326
83327  old_IFS=$IFS
83328  for ac_src in php_xsl.c xsltprocessor.c; do
83329
83330      IFS=.
83331      set $ac_src
83332      ac_obj=$1
83333      IFS=$old_IFS
83334
83335      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83336
83337      case $ac_src in
83338        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83339        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83340        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83341        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83342      esac
83343
83344      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83345
83346    cat >>Makefile.objects<<EOF
83347-include $ac_bdir$ac_obj.dep
83348$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83349	$ac_comp
83350EOF
83351  done
83352
83353
83354    EXT_STATIC="$EXT_STATIC xsl;$ext_dir"
83355    if test "$ext_shared" != "nocli"; then
83356      EXT_CLI_STATIC="$EXT_CLI_STATIC xsl;$ext_dir"
83357    fi
83358  else
83359    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
83360      PHP_XSL_SHARED=yes
83361
83362  case $ext_dir in
83363  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83364  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83365  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83366  esac
83367
83368
83369
83370  b_c_pre=$shared_c_pre
83371  b_cxx_pre=$shared_cxx_pre
83372  b_c_meta=$shared_c_meta
83373  b_cxx_meta=$shared_cxx_meta
83374  b_c_post=$shared_c_post
83375  b_cxx_post=$shared_cxx_post
83376  b_lo=$shared_lo
83377
83378
83379  old_IFS=$IFS
83380  for ac_src in php_xsl.c xsltprocessor.c; do
83381
83382      IFS=.
83383      set $ac_src
83384      ac_obj=$1
83385      IFS=$old_IFS
83386
83387      shared_objects_xsl="$shared_objects_xsl $ac_bdir$ac_obj.lo"
83388
83389      case $ac_src in
83390        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83391        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83392        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83393        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83394      esac
83395
83396      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83397
83398    cat >>Makefile.objects<<EOF
83399-include $ac_bdir$ac_obj.dep
83400$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83401	$ac_comp
83402EOF
83403  done
83404
83405
83406  install_modules="install-modules"
83407  suffix=la
83408
83409  case $host_alias in
83410    *aix*)
83411      additional_flags="-Wl,-G"
83412      ;;
83413  esac
83414
83415  if test "x" = "xyes"; then
83416    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/xsl.$suffix"
83417  else
83418    PHP_MODULES="$PHP_MODULES \$(phplibdir)/xsl.$suffix"
83419  fi
83420
83421  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_xsl"
83422
83423  cat >>Makefile.objects<<EOF
83424\$(phplibdir)/xsl.$suffix: $ext_builddir/xsl.$suffix
83425	\$(LIBTOOL) --mode=install cp $ext_builddir/xsl.$suffix \$(phplibdir)
83426
83427$ext_builddir/xsl.$suffix: \$(shared_objects_xsl) \$(XSL_SHARED_DEPENDENCIES)
83428	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_xsl) \$(XSL_SHARED_LIBADD)
83429
83430EOF
83431
83432
83433printf "%s\n" "#define COMPILE_DL_XSL 1" >>confdefs.h
83434
83435    fi
83436  fi
83437
83438  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
83439    PHP_XSL_SHARED=no
83440    case "$PHP_SAPI" in
83441      cgi|embed|phpdbg)
83442
83443
83444  case $ext_dir in
83445  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83446  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83447  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83448  esac
83449
83450
83451
83452  b_c_pre=$php_c_pre
83453  b_cxx_pre=$php_cxx_pre
83454  b_c_meta=$php_c_meta
83455  b_cxx_meta=$php_cxx_meta
83456  b_c_post=$php_c_post
83457  b_cxx_post=$php_cxx_post
83458  b_lo=$php_lo
83459
83460
83461  old_IFS=$IFS
83462  for ac_src in php_xsl.c xsltprocessor.c; do
83463
83464      IFS=.
83465      set $ac_src
83466      ac_obj=$1
83467      IFS=$old_IFS
83468
83469      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83470
83471      case $ac_src in
83472        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83473        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83474        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83475        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83476      esac
83477
83478      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83479
83480    cat >>Makefile.objects<<EOF
83481-include $ac_bdir$ac_obj.dep
83482$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83483	$ac_comp
83484EOF
83485  done
83486
83487
83488        EXT_STATIC="$EXT_STATIC xsl;$ext_dir"
83489        ;;
83490      *)
83491
83492
83493  case $ext_dir in
83494  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83495  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83496  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83497  esac
83498
83499
83500
83501  b_c_pre=$php_c_pre
83502  b_cxx_pre=$php_cxx_pre
83503  b_c_meta=$php_c_meta
83504  b_cxx_meta=$php_cxx_meta
83505  b_c_post=$php_c_post
83506  b_cxx_post=$php_cxx_post
83507  b_lo=$php_lo
83508
83509
83510  old_IFS=$IFS
83511  for ac_src in php_xsl.c xsltprocessor.c; do
83512
83513      IFS=.
83514      set $ac_src
83515      ac_obj=$1
83516      IFS=$old_IFS
83517
83518      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83519
83520      case $ac_src in
83521        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83522        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83523        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83524        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83525      esac
83526
83527      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83528
83529    cat >>Makefile.objects<<EOF
83530-include $ac_bdir$ac_obj.dep
83531$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83532	$ac_comp
83533EOF
83534  done
83535
83536
83537        ;;
83538    esac
83539    EXT_CLI_STATIC="$EXT_CLI_STATIC xsl;$ext_dir"
83540  fi
83541
83542
83543    BUILD_DIR="$BUILD_DIR $ext_builddir"
83544
83545
83546
83547  if test "$ext_builddir" = "."; then
83548    PHP_PECL_EXTENSION=xsl
83549
83550  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
83551
83552  fi
83553
83554
83555  PHP_VAR_SUBST="$PHP_VAR_SUBST XSL_SHARED_LIBADD"
83556
83557
83558  am_i_shared=$PHP_XSL_SHARED
83559  is_it_shared=$PHP_LIBXML_SHARED
83560  is_it_enabled=$PHP_LIBXML
83561  if test "$am_i_shared" = "no" && test "$is_it_shared" = "yes" ; then
83562    as_fn_error $? "
83563You've configured extension xsl to build statically, but it
83564depends on extension libxml, which you've configured to build shared.
83565You either need to build xsl shared or build libxml statically for the
83566build to be successful.
83567" "$LINENO" 5
83568  fi
83569  if test "x$is_it_enabled" = "xno" && test "x" != "xtrue"; then
83570    as_fn_error $? "
83571You've configured extension xsl, which depends on extension libxml,
83572but you've either not enabled libxml, or have disabled it.
83573" "$LINENO" 5
83574  fi
83575
83576fi
83577
83578
83579
83580
83581
83582php_enable_zend_test=no
83583
83584{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable zend-test extension" >&5
83585printf %s "checking whether to enable zend-test extension... " >&6; }
83586# Check whether --enable-zend-test was given.
83587if test ${enable_zend_test+y}
83588then :
83589  enableval=$enable_zend_test; PHP_ZEND_TEST=$enableval
83590else $as_nop
83591
83592  PHP_ZEND_TEST=no
83593  test "$PHP_ENABLE_ALL" && PHP_ZEND_TEST=$PHP_ENABLE_ALL
83594
83595fi
83596
83597
83598
83599ext_output="yes, shared"
83600ext_shared=yes
83601case $PHP_ZEND_TEST in
83602shared,*)
83603  PHP_ZEND_TEST=`echo "$PHP_ZEND_TEST"|$SED 's/^shared,//'`
83604  ;;
83605shared)
83606  PHP_ZEND_TEST=yes
83607  ;;
83608no)
83609  ext_output=no
83610  ext_shared=no
83611  ;;
83612*)
83613  ext_output=yes
83614  ext_shared=no
83615  ;;
83616esac
83617
83618
83619
83620{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
83621printf "%s\n" "$ext_output" >&6; }
83622
83623
83624
83625
83626if test "$PHP_ZEND_TEST" != "no"; then
83627
83628  ext_builddir=ext/zend_test
83629  ext_srcdir=$abs_srcdir/ext/zend_test
83630  ext_dir=ext/zend_test
83631
83632  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
83633
83634  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
83635    PHP_ZEND_TEST_SHARED=no
83636
83637
83638  case $ext_dir in
83639  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83640  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83641  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83642  esac
83643
83644
83645
83646  b_c_pre=$php_c_pre
83647  b_cxx_pre=$php_cxx_pre
83648  b_c_meta=$php_c_meta
83649  b_cxx_meta=$php_cxx_meta
83650  b_c_post=$php_c_post
83651  b_cxx_post=$php_cxx_post
83652  b_lo=$php_lo
83653
83654
83655  old_IFS=$IFS
83656  for ac_src in test.c observer.c fiber.c; do
83657
83658      IFS=.
83659      set $ac_src
83660      ac_obj=$1
83661      IFS=$old_IFS
83662
83663      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83664
83665      case $ac_src in
83666        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83667        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83668        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83669        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83670      esac
83671
83672      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83673
83674    cat >>Makefile.objects<<EOF
83675-include $ac_bdir$ac_obj.dep
83676$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83677	$ac_comp
83678EOF
83679  done
83680
83681
83682    EXT_STATIC="$EXT_STATIC zend_test;$ext_dir"
83683    if test "$ext_shared" != "nocli"; then
83684      EXT_CLI_STATIC="$EXT_CLI_STATIC zend_test;$ext_dir"
83685    fi
83686  else
83687    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
83688      PHP_ZEND_TEST_SHARED=yes
83689
83690  case $ext_dir in
83691  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83692  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83693  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83694  esac
83695
83696
83697
83698  b_c_pre=$shared_c_pre
83699  b_cxx_pre=$shared_cxx_pre
83700  b_c_meta=$shared_c_meta
83701  b_cxx_meta=$shared_cxx_meta
83702  b_c_post=$shared_c_post
83703  b_cxx_post=$shared_cxx_post
83704  b_lo=$shared_lo
83705
83706
83707  old_IFS=$IFS
83708  for ac_src in test.c observer.c fiber.c; do
83709
83710      IFS=.
83711      set $ac_src
83712      ac_obj=$1
83713      IFS=$old_IFS
83714
83715      shared_objects_zend_test="$shared_objects_zend_test $ac_bdir$ac_obj.lo"
83716
83717      case $ac_src in
83718        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83719        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83720        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83721        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83722      esac
83723
83724      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83725
83726    cat >>Makefile.objects<<EOF
83727-include $ac_bdir$ac_obj.dep
83728$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83729	$ac_comp
83730EOF
83731  done
83732
83733
83734  install_modules="install-modules"
83735  suffix=la
83736
83737  case $host_alias in
83738    *aix*)
83739      additional_flags="-Wl,-G"
83740      ;;
83741  esac
83742
83743  if test "x" = "xyes"; then
83744    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/zend_test.$suffix"
83745  else
83746    PHP_MODULES="$PHP_MODULES \$(phplibdir)/zend_test.$suffix"
83747  fi
83748
83749  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_zend_test"
83750
83751  cat >>Makefile.objects<<EOF
83752\$(phplibdir)/zend_test.$suffix: $ext_builddir/zend_test.$suffix
83753	\$(LIBTOOL) --mode=install cp $ext_builddir/zend_test.$suffix \$(phplibdir)
83754
83755$ext_builddir/zend_test.$suffix: \$(shared_objects_zend_test) \$(ZEND_TEST_SHARED_DEPENDENCIES)
83756	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_zend_test) \$(ZEND_TEST_SHARED_LIBADD)
83757
83758EOF
83759
83760
83761printf "%s\n" "#define COMPILE_DL_ZEND_TEST 1" >>confdefs.h
83762
83763    fi
83764  fi
83765
83766  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
83767    PHP_ZEND_TEST_SHARED=no
83768    case "$PHP_SAPI" in
83769      cgi|embed|phpdbg)
83770
83771
83772  case $ext_dir in
83773  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83774  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83775  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83776  esac
83777
83778
83779
83780  b_c_pre=$php_c_pre
83781  b_cxx_pre=$php_cxx_pre
83782  b_c_meta=$php_c_meta
83783  b_cxx_meta=$php_cxx_meta
83784  b_c_post=$php_c_post
83785  b_cxx_post=$php_cxx_post
83786  b_lo=$php_lo
83787
83788
83789  old_IFS=$IFS
83790  for ac_src in test.c observer.c fiber.c; do
83791
83792      IFS=.
83793      set $ac_src
83794      ac_obj=$1
83795      IFS=$old_IFS
83796
83797      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83798
83799      case $ac_src in
83800        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83801        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83802        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83803        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83804      esac
83805
83806      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83807
83808    cat >>Makefile.objects<<EOF
83809-include $ac_bdir$ac_obj.dep
83810$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83811	$ac_comp
83812EOF
83813  done
83814
83815
83816        EXT_STATIC="$EXT_STATIC zend_test;$ext_dir"
83817        ;;
83818      *)
83819
83820
83821  case $ext_dir in
83822  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
83823  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
83824  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
83825  esac
83826
83827
83828
83829  b_c_pre=$php_c_pre
83830  b_cxx_pre=$php_cxx_pre
83831  b_c_meta=$php_c_meta
83832  b_cxx_meta=$php_cxx_meta
83833  b_c_post=$php_c_post
83834  b_cxx_post=$php_cxx_post
83835  b_lo=$php_lo
83836
83837
83838  old_IFS=$IFS
83839  for ac_src in test.c observer.c fiber.c; do
83840
83841      IFS=.
83842      set $ac_src
83843      ac_obj=$1
83844      IFS=$old_IFS
83845
83846      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
83847
83848      case $ac_src in
83849        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83850        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83851        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
83852        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
83853      esac
83854
83855      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
83856
83857    cat >>Makefile.objects<<EOF
83858-include $ac_bdir$ac_obj.dep
83859$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
83860	$ac_comp
83861EOF
83862  done
83863
83864
83865        ;;
83866    esac
83867    EXT_CLI_STATIC="$EXT_CLI_STATIC zend_test;$ext_dir"
83868  fi
83869
83870
83871    BUILD_DIR="$BUILD_DIR $ext_builddir"
83872
83873
83874
83875  if test "$ext_builddir" = "."; then
83876    PHP_PECL_EXTENSION=zend_test
83877
83878  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
83879
83880  fi
83881
83882fi
83883
83884
83885
83886
83887
83888php_with_zip=no
83889
83890{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip archive read/write support" >&5
83891printf %s "checking for zip archive read/write support... " >&6; }
83892
83893# Check whether --with-zip was given.
83894if test ${with_zip+y}
83895then :
83896  withval=$with_zip; PHP_ZIP=$withval
83897else $as_nop
83898
83899  PHP_ZIP=no
83900  test "$PHP_ENABLE_ALL" && PHP_ZIP=$PHP_ENABLE_ALL
83901
83902fi
83903
83904
83905
83906ext_output="yes, shared"
83907ext_shared=yes
83908case $PHP_ZIP in
83909shared,*)
83910  PHP_ZIP=`echo "$PHP_ZIP"|$SED 's/^shared,//'`
83911  ;;
83912shared)
83913  PHP_ZIP=yes
83914  ;;
83915no)
83916  ext_output=no
83917  ext_shared=no
83918  ;;
83919*)
83920  ext_output=yes
83921  ext_shared=no
83922  ;;
83923esac
83924
83925
83926
83927{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
83928printf "%s\n" "$ext_output" >&6; }
83929
83930
83931
83932
83933if test "$PHP_ZIP" != "no"; then
83934
83935pkg_failed=no
83936{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0" >&5
83937printf %s "checking for libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0... " >&6; }
83938
83939if test -n "$LIBZIP_CFLAGS"; then
83940    pkg_cv_LIBZIP_CFLAGS="$LIBZIP_CFLAGS"
83941 elif test -n "$PKG_CONFIG"; then
83942    if test -n "$PKG_CONFIG" && \
83943    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0\""; } >&5
83944  ($PKG_CONFIG --exists --print-errors "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0") 2>&5
83945  ac_status=$?
83946  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
83947  test $ac_status = 0; }; then
83948  pkg_cv_LIBZIP_CFLAGS=`$PKG_CONFIG --cflags "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0" 2>/dev/null`
83949		      test "x$?" != "x0" && pkg_failed=yes
83950else
83951  pkg_failed=yes
83952fi
83953 else
83954    pkg_failed=untried
83955fi
83956if test -n "$LIBZIP_LIBS"; then
83957    pkg_cv_LIBZIP_LIBS="$LIBZIP_LIBS"
83958 elif test -n "$PKG_CONFIG"; then
83959    if test -n "$PKG_CONFIG" && \
83960    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0\""; } >&5
83961  ($PKG_CONFIG --exists --print-errors "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0") 2>&5
83962  ac_status=$?
83963  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
83964  test $ac_status = 0; }; then
83965  pkg_cv_LIBZIP_LIBS=`$PKG_CONFIG --libs "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0" 2>/dev/null`
83966		      test "x$?" != "x0" && pkg_failed=yes
83967else
83968  pkg_failed=yes
83969fi
83970 else
83971    pkg_failed=untried
83972fi
83973
83974
83975
83976if test $pkg_failed = yes; then
83977        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
83978printf "%s\n" "no" >&6; }
83979
83980if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
83981        _pkg_short_errors_supported=yes
83982else
83983        _pkg_short_errors_supported=no
83984fi
83985        if test $_pkg_short_errors_supported = yes; then
83986	        LIBZIP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0" 2>&1`
83987        else
83988	        LIBZIP_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0" 2>&1`
83989        fi
83990	# Put the nasty error message in config.log where it belongs
83991	echo "$LIBZIP_PKG_ERRORS" >&5
83992
83993	as_fn_error $? "Package requirements (libzip >= 0.11 libzip != 1.3.1 libzip != 1.7.0) were not met:
83994
83995$LIBZIP_PKG_ERRORS
83996
83997Consider adjusting the PKG_CONFIG_PATH environment variable if you
83998installed software in a non-standard prefix.
83999
84000Alternatively, you may set the environment variables LIBZIP_CFLAGS
84001and LIBZIP_LIBS to avoid the need to call pkg-config.
84002See the pkg-config man page for more details." "$LINENO" 5
84003elif test $pkg_failed = untried; then
84004        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
84005printf "%s\n" "no" >&6; }
84006	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
84007printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
84008as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
84009is in your PATH or set the PKG_CONFIG environment variable to the full
84010path to pkg-config.
84011
84012Alternatively, you may set the environment variables LIBZIP_CFLAGS
84013and LIBZIP_LIBS to avoid the need to call pkg-config.
84014See the pkg-config man page for more details.
84015
84016To get pkg-config, see <http://pkg-config.freedesktop.org/>.
84017See \`config.log' for more details" "$LINENO" 5; }
84018else
84019	LIBZIP_CFLAGS=$pkg_cv_LIBZIP_CFLAGS
84020	LIBZIP_LIBS=$pkg_cv_LIBZIP_LIBS
84021        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
84022printf "%s\n" "yes" >&6; }
84023
84024fi
84025
84026
84027  for ac_i in $LIBZIP_CFLAGS; do
84028    case $ac_i in
84029    -I*)
84030      ac_ii=`echo $ac_i|cut -c 3-`
84031
84032  if test "$ac_ii" != "/usr/include"; then
84033
84034  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84035    ai_p=$ac_ii
84036  else
84037
84038    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84039
84040    ep_realdir=`(cd "$ep_dir" && pwd)`
84041    ai_p="$ep_realdir"/`basename "$ac_ii"`
84042  fi
84043
84044
84045
84046  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84047
84048  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
84049  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84050    eval "INCLUDEPATH$unique=set"
84051
84052      if test ""; then
84053        INCLUDES="-I$ai_p $INCLUDES"
84054      else
84055        INCLUDES="$INCLUDES -I$ai_p"
84056      fi
84057
84058  fi
84059
84060  fi
84061
84062    ;;
84063    esac
84064  done
84065
84066
84067  for ac_i in $LIBZIP_LIBS; do
84068    case $ac_i in
84069    -pthread)
84070      if test "$ext_shared" = "yes"; then
84071        ZIP_SHARED_LIBADD="$ZIP_SHARED_LIBADD -pthread"
84072      else
84073
84074
84075  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84076
84077  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84078  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84079    eval "EXTRA_LDFLAGS$unique=set"
84080    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84081  fi
84082
84083
84084
84085  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84086
84087  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84088  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84089    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84090    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84091  fi
84092
84093      fi
84094    ;;
84095    -l*)
84096      ac_ii=`echo $ac_i|cut -c 3-`
84097
84098
84099  case $ac_ii in
84100  c|c_r) ;;
84101  *)
84102    if test "$ext_shared" = "yes"; then
84103        ZIP_SHARED_LIBADD="$ZIP_SHARED_LIBADD -l$ac_ii"
84104    else
84105
84106
84107  case $ac_ii in
84108  c|c_r) ;;
84109  *)
84110      LIBS="$LIBS -l$ac_ii"
84111   ;;
84112  esac
84113
84114
84115    fi
84116   ;;
84117  esac
84118
84119
84120    ;;
84121    -L*)
84122      ac_ii=`echo $ac_i|cut -c 3-`
84123
84124  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84125
84126  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84127    ai_p=$ac_ii
84128  else
84129
84130    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84131
84132    ep_realdir=`(cd "$ep_dir" && pwd)`
84133    ai_p="$ep_realdir"/`basename "$ac_ii"`
84134  fi
84135
84136
84137      if test "$ext_shared" = "yes"; then
84138        ZIP_SHARED_LIBADD="-L$ai_p $ZIP_SHARED_LIBADD"
84139        test -n "$ld_runpath_switch" && ZIP_SHARED_LIBADD="$ld_runpath_switch$ai_p $ZIP_SHARED_LIBADD"
84140      else
84141
84142
84143
84144  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84145
84146  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84147  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84148    eval "LIBPATH$unique=set"
84149
84150    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84151    LDFLAGS="$LDFLAGS -L$ai_p"
84152    PHP_RPATHS="$PHP_RPATHS $ai_p"
84153
84154  fi
84155
84156
84157      fi
84158
84159  fi
84160
84161    ;;
84162    esac
84163  done
84164
84165
84166
84167  save_old_LDFLAGS=$LDFLAGS
84168  ac_stuff="
84169    $LIBZIP_LIBS
84170  "
84171
84172  save_ext_shared=$ext_shared
84173  ext_shared=yes
84174
84175  for ac_i in $ac_stuff; do
84176    case $ac_i in
84177    -pthread)
84178      if test "$ext_shared" = "yes"; then
84179        LDFLAGS="$LDFLAGS -pthread"
84180      else
84181
84182
84183  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84184
84185  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84186  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84187    eval "EXTRA_LDFLAGS$unique=set"
84188    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84189  fi
84190
84191
84192
84193  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84194
84195  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84196  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84197    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84198    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84199  fi
84200
84201      fi
84202    ;;
84203    -l*)
84204      ac_ii=`echo $ac_i|cut -c 3-`
84205
84206
84207  case $ac_ii in
84208  c|c_r) ;;
84209  *)
84210    if test "$ext_shared" = "yes"; then
84211        LDFLAGS="$LDFLAGS -l$ac_ii"
84212    else
84213
84214
84215  case $ac_ii in
84216  c|c_r) ;;
84217  *)
84218      LIBS="$LIBS -l$ac_ii"
84219   ;;
84220  esac
84221
84222
84223    fi
84224   ;;
84225  esac
84226
84227
84228    ;;
84229    -L*)
84230      ac_ii=`echo $ac_i|cut -c 3-`
84231
84232  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84233
84234  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84235    ai_p=$ac_ii
84236  else
84237
84238    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84239
84240    ep_realdir=`(cd "$ep_dir" && pwd)`
84241    ai_p="$ep_realdir"/`basename "$ac_ii"`
84242  fi
84243
84244
84245      if test "$ext_shared" = "yes"; then
84246        LDFLAGS="-L$ai_p $LDFLAGS"
84247        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
84248      else
84249
84250
84251
84252  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84253
84254  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84255  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84256    eval "LIBPATH$unique=set"
84257
84258    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84259    LDFLAGS="$LDFLAGS -L$ai_p"
84260    PHP_RPATHS="$PHP_RPATHS $ai_p"
84261
84262  fi
84263
84264
84265      fi
84266
84267  fi
84268
84269    ;;
84270    esac
84271  done
84272
84273  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_file_set_mtime in -lzip" >&5
84274printf %s "checking for zip_file_set_mtime in -lzip... " >&6; }
84275if test ${ac_cv_lib_zip_zip_file_set_mtime+y}
84276then :
84277  printf %s "(cached) " >&6
84278else $as_nop
84279  ac_check_lib_save_LIBS=$LIBS
84280LIBS="-lzip  $LIBS"
84281cat confdefs.h - <<_ACEOF >conftest.$ac_ext
84282/* end confdefs.h.  */
84283
84284/* Override any GCC internal prototype to avoid an error.
84285   Use char because int might match the return type of a GCC
84286   builtin and then its argument prototype would still apply.  */
84287char zip_file_set_mtime ();
84288int
84289main (void)
84290{
84291return zip_file_set_mtime ();
84292  ;
84293  return 0;
84294}
84295_ACEOF
84296if ac_fn_c_try_link "$LINENO"
84297then :
84298  ac_cv_lib_zip_zip_file_set_mtime=yes
84299else $as_nop
84300  ac_cv_lib_zip_zip_file_set_mtime=no
84301fi
84302rm -f core conftest.err conftest.$ac_objext conftest.beam \
84303    conftest$ac_exeext conftest.$ac_ext
84304LIBS=$ac_check_lib_save_LIBS
84305fi
84306{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_file_set_mtime" >&5
84307printf "%s\n" "$ac_cv_lib_zip_zip_file_set_mtime" >&6; }
84308if test "x$ac_cv_lib_zip_zip_file_set_mtime" = xyes
84309then :
84310
84311    LDFLAGS=$save_old_LDFLAGS
84312    ext_shared=$save_ext_shared
84313
84314
84315printf "%s\n" "#define HAVE_SET_MTIME 1" >>confdefs.h
84316
84317
84318
84319else $as_nop
84320
84321    LDFLAGS=$save_old_LDFLAGS
84322    ext_shared=$save_ext_shared
84323    unset ac_cv_lib_zip_zip_file_set_mtime
84324
84325    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libzip >= 1.0.0 needed for setting mtime" >&5
84326printf "%s\n" "$as_me: WARNING: Libzip >= 1.0.0 needed for setting mtime" >&2;}
84327
84328
84329fi
84330
84331
84332
84333  save_old_LDFLAGS=$LDFLAGS
84334  ac_stuff="
84335    $LIBZIP_LIBS
84336  "
84337
84338  save_ext_shared=$ext_shared
84339  ext_shared=yes
84340
84341  for ac_i in $ac_stuff; do
84342    case $ac_i in
84343    -pthread)
84344      if test "$ext_shared" = "yes"; then
84345        LDFLAGS="$LDFLAGS -pthread"
84346      else
84347
84348
84349  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84350
84351  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84352  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84353    eval "EXTRA_LDFLAGS$unique=set"
84354    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84355  fi
84356
84357
84358
84359  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84360
84361  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84362  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84363    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84364    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84365  fi
84366
84367      fi
84368    ;;
84369    -l*)
84370      ac_ii=`echo $ac_i|cut -c 3-`
84371
84372
84373  case $ac_ii in
84374  c|c_r) ;;
84375  *)
84376    if test "$ext_shared" = "yes"; then
84377        LDFLAGS="$LDFLAGS -l$ac_ii"
84378    else
84379
84380
84381  case $ac_ii in
84382  c|c_r) ;;
84383  *)
84384      LIBS="$LIBS -l$ac_ii"
84385   ;;
84386  esac
84387
84388
84389    fi
84390   ;;
84391  esac
84392
84393
84394    ;;
84395    -L*)
84396      ac_ii=`echo $ac_i|cut -c 3-`
84397
84398  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84399
84400  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84401    ai_p=$ac_ii
84402  else
84403
84404    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84405
84406    ep_realdir=`(cd "$ep_dir" && pwd)`
84407    ai_p="$ep_realdir"/`basename "$ac_ii"`
84408  fi
84409
84410
84411      if test "$ext_shared" = "yes"; then
84412        LDFLAGS="-L$ai_p $LDFLAGS"
84413        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
84414      else
84415
84416
84417
84418  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84419
84420  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84421  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84422    eval "LIBPATH$unique=set"
84423
84424    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84425    LDFLAGS="$LDFLAGS -L$ai_p"
84426    PHP_RPATHS="$PHP_RPATHS $ai_p"
84427
84428  fi
84429
84430
84431      fi
84432
84433  fi
84434
84435    ;;
84436    esac
84437  done
84438
84439  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_file_set_encryption in -lzip" >&5
84440printf %s "checking for zip_file_set_encryption in -lzip... " >&6; }
84441if test ${ac_cv_lib_zip_zip_file_set_encryption+y}
84442then :
84443  printf %s "(cached) " >&6
84444else $as_nop
84445  ac_check_lib_save_LIBS=$LIBS
84446LIBS="-lzip  $LIBS"
84447cat confdefs.h - <<_ACEOF >conftest.$ac_ext
84448/* end confdefs.h.  */
84449
84450/* Override any GCC internal prototype to avoid an error.
84451   Use char because int might match the return type of a GCC
84452   builtin and then its argument prototype would still apply.  */
84453char zip_file_set_encryption ();
84454int
84455main (void)
84456{
84457return zip_file_set_encryption ();
84458  ;
84459  return 0;
84460}
84461_ACEOF
84462if ac_fn_c_try_link "$LINENO"
84463then :
84464  ac_cv_lib_zip_zip_file_set_encryption=yes
84465else $as_nop
84466  ac_cv_lib_zip_zip_file_set_encryption=no
84467fi
84468rm -f core conftest.err conftest.$ac_objext conftest.beam \
84469    conftest$ac_exeext conftest.$ac_ext
84470LIBS=$ac_check_lib_save_LIBS
84471fi
84472{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_file_set_encryption" >&5
84473printf "%s\n" "$ac_cv_lib_zip_zip_file_set_encryption" >&6; }
84474if test "x$ac_cv_lib_zip_zip_file_set_encryption" = xyes
84475then :
84476
84477    LDFLAGS=$save_old_LDFLAGS
84478    ext_shared=$save_ext_shared
84479
84480
84481printf "%s\n" "#define HAVE_ENCRYPTION 1" >>confdefs.h
84482
84483
84484
84485else $as_nop
84486
84487    LDFLAGS=$save_old_LDFLAGS
84488    ext_shared=$save_ext_shared
84489    unset ac_cv_lib_zip_zip_file_set_encryption
84490
84491    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libzip >= 1.2.0 needed for encryption support" >&5
84492printf "%s\n" "$as_me: WARNING: Libzip >= 1.2.0 needed for encryption support" >&2;}
84493
84494
84495fi
84496
84497
84498
84499  save_old_LDFLAGS=$LDFLAGS
84500  ac_stuff="
84501    $LIBZIP_LIBS
84502  "
84503
84504  save_ext_shared=$ext_shared
84505  ext_shared=yes
84506
84507  for ac_i in $ac_stuff; do
84508    case $ac_i in
84509    -pthread)
84510      if test "$ext_shared" = "yes"; then
84511        LDFLAGS="$LDFLAGS -pthread"
84512      else
84513
84514
84515  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84516
84517  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84518  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84519    eval "EXTRA_LDFLAGS$unique=set"
84520    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84521  fi
84522
84523
84524
84525  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84526
84527  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84528  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84529    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84530    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84531  fi
84532
84533      fi
84534    ;;
84535    -l*)
84536      ac_ii=`echo $ac_i|cut -c 3-`
84537
84538
84539  case $ac_ii in
84540  c|c_r) ;;
84541  *)
84542    if test "$ext_shared" = "yes"; then
84543        LDFLAGS="$LDFLAGS -l$ac_ii"
84544    else
84545
84546
84547  case $ac_ii in
84548  c|c_r) ;;
84549  *)
84550      LIBS="$LIBS -l$ac_ii"
84551   ;;
84552  esac
84553
84554
84555    fi
84556   ;;
84557  esac
84558
84559
84560    ;;
84561    -L*)
84562      ac_ii=`echo $ac_i|cut -c 3-`
84563
84564  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84565
84566  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84567    ai_p=$ac_ii
84568  else
84569
84570    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84571
84572    ep_realdir=`(cd "$ep_dir" && pwd)`
84573    ai_p="$ep_realdir"/`basename "$ac_ii"`
84574  fi
84575
84576
84577      if test "$ext_shared" = "yes"; then
84578        LDFLAGS="-L$ai_p $LDFLAGS"
84579        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
84580      else
84581
84582
84583
84584  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84585
84586  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84587  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84588    eval "LIBPATH$unique=set"
84589
84590    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84591    LDFLAGS="$LDFLAGS -L$ai_p"
84592    PHP_RPATHS="$PHP_RPATHS $ai_p"
84593
84594  fi
84595
84596
84597      fi
84598
84599  fi
84600
84601    ;;
84602    esac
84603  done
84604
84605  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_libzip_version in -lzip" >&5
84606printf %s "checking for zip_libzip_version in -lzip... " >&6; }
84607if test ${ac_cv_lib_zip_zip_libzip_version+y}
84608then :
84609  printf %s "(cached) " >&6
84610else $as_nop
84611  ac_check_lib_save_LIBS=$LIBS
84612LIBS="-lzip  $LIBS"
84613cat confdefs.h - <<_ACEOF >conftest.$ac_ext
84614/* end confdefs.h.  */
84615
84616/* Override any GCC internal prototype to avoid an error.
84617   Use char because int might match the return type of a GCC
84618   builtin and then its argument prototype would still apply.  */
84619char zip_libzip_version ();
84620int
84621main (void)
84622{
84623return zip_libzip_version ();
84624  ;
84625  return 0;
84626}
84627_ACEOF
84628if ac_fn_c_try_link "$LINENO"
84629then :
84630  ac_cv_lib_zip_zip_libzip_version=yes
84631else $as_nop
84632  ac_cv_lib_zip_zip_libzip_version=no
84633fi
84634rm -f core conftest.err conftest.$ac_objext conftest.beam \
84635    conftest$ac_exeext conftest.$ac_ext
84636LIBS=$ac_check_lib_save_LIBS
84637fi
84638{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_libzip_version" >&5
84639printf "%s\n" "$ac_cv_lib_zip_zip_libzip_version" >&6; }
84640if test "x$ac_cv_lib_zip_zip_libzip_version" = xyes
84641then :
84642
84643    LDFLAGS=$save_old_LDFLAGS
84644    ext_shared=$save_ext_shared
84645
84646
84647printf "%s\n" "#define HAVE_LIBZIP_VERSION 1" >>confdefs.h
84648
84649
84650
84651else $as_nop
84652
84653    LDFLAGS=$save_old_LDFLAGS
84654    ext_shared=$save_ext_shared
84655    unset ac_cv_lib_zip_zip_libzip_version
84656
84657
84658
84659fi
84660
84661
84662
84663  save_old_LDFLAGS=$LDFLAGS
84664  ac_stuff="
84665    $LIBZIP_LIBS
84666  "
84667
84668  save_ext_shared=$ext_shared
84669  ext_shared=yes
84670
84671  for ac_i in $ac_stuff; do
84672    case $ac_i in
84673    -pthread)
84674      if test "$ext_shared" = "yes"; then
84675        LDFLAGS="$LDFLAGS -pthread"
84676      else
84677
84678
84679  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84680
84681  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84682  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84683    eval "EXTRA_LDFLAGS$unique=set"
84684    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84685  fi
84686
84687
84688
84689  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84690
84691  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84692  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84693    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84694    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84695  fi
84696
84697      fi
84698    ;;
84699    -l*)
84700      ac_ii=`echo $ac_i|cut -c 3-`
84701
84702
84703  case $ac_ii in
84704  c|c_r) ;;
84705  *)
84706    if test "$ext_shared" = "yes"; then
84707        LDFLAGS="$LDFLAGS -l$ac_ii"
84708    else
84709
84710
84711  case $ac_ii in
84712  c|c_r) ;;
84713  *)
84714      LIBS="$LIBS -l$ac_ii"
84715   ;;
84716  esac
84717
84718
84719    fi
84720   ;;
84721  esac
84722
84723
84724    ;;
84725    -L*)
84726      ac_ii=`echo $ac_i|cut -c 3-`
84727
84728  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84729
84730  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84731    ai_p=$ac_ii
84732  else
84733
84734    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84735
84736    ep_realdir=`(cd "$ep_dir" && pwd)`
84737    ai_p="$ep_realdir"/`basename "$ac_ii"`
84738  fi
84739
84740
84741      if test "$ext_shared" = "yes"; then
84742        LDFLAGS="-L$ai_p $LDFLAGS"
84743        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
84744      else
84745
84746
84747
84748  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84749
84750  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84751  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84752    eval "LIBPATH$unique=set"
84753
84754    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84755    LDFLAGS="$LDFLAGS -L$ai_p"
84756    PHP_RPATHS="$PHP_RPATHS $ai_p"
84757
84758  fi
84759
84760
84761      fi
84762
84763  fi
84764
84765    ;;
84766    esac
84767  done
84768
84769  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_register_progress_callback_with_state in -lzip" >&5
84770printf %s "checking for zip_register_progress_callback_with_state in -lzip... " >&6; }
84771if test ${ac_cv_lib_zip_zip_register_progress_callback_with_state+y}
84772then :
84773  printf %s "(cached) " >&6
84774else $as_nop
84775  ac_check_lib_save_LIBS=$LIBS
84776LIBS="-lzip  $LIBS"
84777cat confdefs.h - <<_ACEOF >conftest.$ac_ext
84778/* end confdefs.h.  */
84779
84780/* Override any GCC internal prototype to avoid an error.
84781   Use char because int might match the return type of a GCC
84782   builtin and then its argument prototype would still apply.  */
84783char zip_register_progress_callback_with_state ();
84784int
84785main (void)
84786{
84787return zip_register_progress_callback_with_state ();
84788  ;
84789  return 0;
84790}
84791_ACEOF
84792if ac_fn_c_try_link "$LINENO"
84793then :
84794  ac_cv_lib_zip_zip_register_progress_callback_with_state=yes
84795else $as_nop
84796  ac_cv_lib_zip_zip_register_progress_callback_with_state=no
84797fi
84798rm -f core conftest.err conftest.$ac_objext conftest.beam \
84799    conftest$ac_exeext conftest.$ac_ext
84800LIBS=$ac_check_lib_save_LIBS
84801fi
84802{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_register_progress_callback_with_state" >&5
84803printf "%s\n" "$ac_cv_lib_zip_zip_register_progress_callback_with_state" >&6; }
84804if test "x$ac_cv_lib_zip_zip_register_progress_callback_with_state" = xyes
84805then :
84806
84807    LDFLAGS=$save_old_LDFLAGS
84808    ext_shared=$save_ext_shared
84809
84810
84811printf "%s\n" "#define HAVE_PROGRESS_CALLBACK 1" >>confdefs.h
84812
84813
84814
84815else $as_nop
84816
84817    LDFLAGS=$save_old_LDFLAGS
84818    ext_shared=$save_ext_shared
84819    unset ac_cv_lib_zip_zip_register_progress_callback_with_state
84820
84821
84822
84823fi
84824
84825
84826
84827  save_old_LDFLAGS=$LDFLAGS
84828  ac_stuff="
84829    $LIBZIP_LIBS
84830  "
84831
84832  save_ext_shared=$ext_shared
84833  ext_shared=yes
84834
84835  for ac_i in $ac_stuff; do
84836    case $ac_i in
84837    -pthread)
84838      if test "$ext_shared" = "yes"; then
84839        LDFLAGS="$LDFLAGS -pthread"
84840      else
84841
84842
84843  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84844
84845  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
84846  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84847    eval "EXTRA_LDFLAGS$unique=set"
84848    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
84849  fi
84850
84851
84852
84853  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
84854
84855  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
84856  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84857    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
84858    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
84859  fi
84860
84861      fi
84862    ;;
84863    -l*)
84864      ac_ii=`echo $ac_i|cut -c 3-`
84865
84866
84867  case $ac_ii in
84868  c|c_r) ;;
84869  *)
84870    if test "$ext_shared" = "yes"; then
84871        LDFLAGS="$LDFLAGS -l$ac_ii"
84872    else
84873
84874
84875  case $ac_ii in
84876  c|c_r) ;;
84877  *)
84878      LIBS="$LIBS -l$ac_ii"
84879   ;;
84880  esac
84881
84882
84883    fi
84884   ;;
84885  esac
84886
84887
84888    ;;
84889    -L*)
84890      ac_ii=`echo $ac_i|cut -c 3-`
84891
84892  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
84893
84894  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
84895    ai_p=$ac_ii
84896  else
84897
84898    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
84899
84900    ep_realdir=`(cd "$ep_dir" && pwd)`
84901    ai_p="$ep_realdir"/`basename "$ac_ii"`
84902  fi
84903
84904
84905      if test "$ext_shared" = "yes"; then
84906        LDFLAGS="-L$ai_p $LDFLAGS"
84907        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
84908      else
84909
84910
84911
84912  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
84913
84914  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
84915  if test -n "$unique" && test "`eval $cmd`" = "" ; then
84916    eval "LIBPATH$unique=set"
84917
84918    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
84919    LDFLAGS="$LDFLAGS -L$ai_p"
84920    PHP_RPATHS="$PHP_RPATHS $ai_p"
84921
84922  fi
84923
84924
84925      fi
84926
84927  fi
84928
84929    ;;
84930    esac
84931  done
84932
84933  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_register_cancel_callback_with_state in -lzip" >&5
84934printf %s "checking for zip_register_cancel_callback_with_state in -lzip... " >&6; }
84935if test ${ac_cv_lib_zip_zip_register_cancel_callback_with_state+y}
84936then :
84937  printf %s "(cached) " >&6
84938else $as_nop
84939  ac_check_lib_save_LIBS=$LIBS
84940LIBS="-lzip  $LIBS"
84941cat confdefs.h - <<_ACEOF >conftest.$ac_ext
84942/* end confdefs.h.  */
84943
84944/* Override any GCC internal prototype to avoid an error.
84945   Use char because int might match the return type of a GCC
84946   builtin and then its argument prototype would still apply.  */
84947char zip_register_cancel_callback_with_state ();
84948int
84949main (void)
84950{
84951return zip_register_cancel_callback_with_state ();
84952  ;
84953  return 0;
84954}
84955_ACEOF
84956if ac_fn_c_try_link "$LINENO"
84957then :
84958  ac_cv_lib_zip_zip_register_cancel_callback_with_state=yes
84959else $as_nop
84960  ac_cv_lib_zip_zip_register_cancel_callback_with_state=no
84961fi
84962rm -f core conftest.err conftest.$ac_objext conftest.beam \
84963    conftest$ac_exeext conftest.$ac_ext
84964LIBS=$ac_check_lib_save_LIBS
84965fi
84966{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_register_cancel_callback_with_state" >&5
84967printf "%s\n" "$ac_cv_lib_zip_zip_register_cancel_callback_with_state" >&6; }
84968if test "x$ac_cv_lib_zip_zip_register_cancel_callback_with_state" = xyes
84969then :
84970
84971    LDFLAGS=$save_old_LDFLAGS
84972    ext_shared=$save_ext_shared
84973
84974
84975printf "%s\n" "#define HAVE_CANCEL_CALLBACK 1" >>confdefs.h
84976
84977
84978
84979else $as_nop
84980
84981    LDFLAGS=$save_old_LDFLAGS
84982    ext_shared=$save_ext_shared
84983    unset ac_cv_lib_zip_zip_register_cancel_callback_with_state
84984
84985
84986
84987fi
84988
84989
84990
84991  save_old_LDFLAGS=$LDFLAGS
84992  ac_stuff="
84993    $LIBZIP_LIBS
84994  "
84995
84996  save_ext_shared=$ext_shared
84997  ext_shared=yes
84998
84999  for ac_i in $ac_stuff; do
85000    case $ac_i in
85001    -pthread)
85002      if test "$ext_shared" = "yes"; then
85003        LDFLAGS="$LDFLAGS -pthread"
85004      else
85005
85006
85007  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85008
85009  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
85010  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85011    eval "EXTRA_LDFLAGS$unique=set"
85012    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
85013  fi
85014
85015
85016
85017  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85018
85019  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
85020  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85021    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
85022    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
85023  fi
85024
85025      fi
85026    ;;
85027    -l*)
85028      ac_ii=`echo $ac_i|cut -c 3-`
85029
85030
85031  case $ac_ii in
85032  c|c_r) ;;
85033  *)
85034    if test "$ext_shared" = "yes"; then
85035        LDFLAGS="$LDFLAGS -l$ac_ii"
85036    else
85037
85038
85039  case $ac_ii in
85040  c|c_r) ;;
85041  *)
85042      LIBS="$LIBS -l$ac_ii"
85043   ;;
85044  esac
85045
85046
85047    fi
85048   ;;
85049  esac
85050
85051
85052    ;;
85053    -L*)
85054      ac_ii=`echo $ac_i|cut -c 3-`
85055
85056  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
85057
85058  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
85059    ai_p=$ac_ii
85060  else
85061
85062    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
85063
85064    ep_realdir=`(cd "$ep_dir" && pwd)`
85065    ai_p="$ep_realdir"/`basename "$ac_ii"`
85066  fi
85067
85068
85069      if test "$ext_shared" = "yes"; then
85070        LDFLAGS="-L$ai_p $LDFLAGS"
85071        test -n "$ld_runpath_switch" && LDFLAGS="$ld_runpath_switch$ai_p $LDFLAGS"
85072      else
85073
85074
85075
85076  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
85077
85078  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
85079  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85080    eval "LIBPATH$unique=set"
85081
85082    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
85083    LDFLAGS="$LDFLAGS -L$ai_p"
85084    PHP_RPATHS="$PHP_RPATHS $ai_p"
85085
85086  fi
85087
85088
85089      fi
85090
85091  fi
85092
85093    ;;
85094    esac
85095  done
85096
85097  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zip_compression_method_supported in -lzip" >&5
85098printf %s "checking for zip_compression_method_supported in -lzip... " >&6; }
85099if test ${ac_cv_lib_zip_zip_compression_method_supported+y}
85100then :
85101  printf %s "(cached) " >&6
85102else $as_nop
85103  ac_check_lib_save_LIBS=$LIBS
85104LIBS="-lzip  $LIBS"
85105cat confdefs.h - <<_ACEOF >conftest.$ac_ext
85106/* end confdefs.h.  */
85107
85108/* Override any GCC internal prototype to avoid an error.
85109   Use char because int might match the return type of a GCC
85110   builtin and then its argument prototype would still apply.  */
85111char zip_compression_method_supported ();
85112int
85113main (void)
85114{
85115return zip_compression_method_supported ();
85116  ;
85117  return 0;
85118}
85119_ACEOF
85120if ac_fn_c_try_link "$LINENO"
85121then :
85122  ac_cv_lib_zip_zip_compression_method_supported=yes
85123else $as_nop
85124  ac_cv_lib_zip_zip_compression_method_supported=no
85125fi
85126rm -f core conftest.err conftest.$ac_objext conftest.beam \
85127    conftest$ac_exeext conftest.$ac_ext
85128LIBS=$ac_check_lib_save_LIBS
85129fi
85130{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_zip_zip_compression_method_supported" >&5
85131printf "%s\n" "$ac_cv_lib_zip_zip_compression_method_supported" >&6; }
85132if test "x$ac_cv_lib_zip_zip_compression_method_supported" = xyes
85133then :
85134
85135    LDFLAGS=$save_old_LDFLAGS
85136    ext_shared=$save_ext_shared
85137
85138
85139printf "%s\n" "#define HAVE_METHOD_SUPPORTED 1" >>confdefs.h
85140
85141
85142
85143else $as_nop
85144
85145    LDFLAGS=$save_old_LDFLAGS
85146    ext_shared=$save_ext_shared
85147    unset ac_cv_lib_zip_zip_compression_method_supported
85148
85149
85150
85151fi
85152
85153
85154
85155printf "%s\n" "#define HAVE_ZIP 1" >>confdefs.h
85156
85157
85158  PHP_ZIP_SOURCES="php_zip.c zip_stream.c"
85159
85160  ext_builddir=ext/zip
85161  ext_srcdir=$abs_srcdir/ext/zip
85162  ext_dir=ext/zip
85163
85164  ac_extra=
85165
85166  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
85167    PHP_ZIP_SHARED=no
85168
85169
85170  case $ext_dir in
85171  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
85172  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
85173  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
85174  esac
85175
85176
85177
85178  b_c_pre=$php_c_pre
85179  b_cxx_pre=$php_cxx_pre
85180  b_c_meta=$php_c_meta
85181  b_cxx_meta=$php_cxx_meta
85182  b_c_post=$php_c_post
85183  b_cxx_post=$php_cxx_post
85184  b_lo=$php_lo
85185
85186
85187  old_IFS=$IFS
85188  for ac_src in $PHP_ZIP_SOURCES; do
85189
85190      IFS=.
85191      set $ac_src
85192      ac_obj=$1
85193      IFS=$old_IFS
85194
85195      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
85196
85197      case $ac_src in
85198        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85199        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85200        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85201        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
85202      esac
85203
85204      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
85205
85206    cat >>Makefile.objects<<EOF
85207-include $ac_bdir$ac_obj.dep
85208$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
85209	$ac_comp
85210EOF
85211  done
85212
85213
85214    EXT_STATIC="$EXT_STATIC zip;$ext_dir"
85215    if test "$ext_shared" != "nocli"; then
85216      EXT_CLI_STATIC="$EXT_CLI_STATIC zip;$ext_dir"
85217    fi
85218  else
85219    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
85220      PHP_ZIP_SHARED=yes
85221
85222  case $ext_dir in
85223  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
85224  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
85225  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
85226  esac
85227
85228
85229
85230  b_c_pre=$shared_c_pre
85231  b_cxx_pre=$shared_cxx_pre
85232  b_c_meta=$shared_c_meta
85233  b_cxx_meta=$shared_cxx_meta
85234  b_c_post=$shared_c_post
85235  b_cxx_post=$shared_cxx_post
85236  b_lo=$shared_lo
85237
85238
85239  old_IFS=$IFS
85240  for ac_src in $PHP_ZIP_SOURCES; do
85241
85242      IFS=.
85243      set $ac_src
85244      ac_obj=$1
85245      IFS=$old_IFS
85246
85247      shared_objects_zip="$shared_objects_zip $ac_bdir$ac_obj.lo"
85248
85249      case $ac_src in
85250        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85251        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85252        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85253        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
85254      esac
85255
85256      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
85257
85258    cat >>Makefile.objects<<EOF
85259-include $ac_bdir$ac_obj.dep
85260$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
85261	$ac_comp
85262EOF
85263  done
85264
85265
85266  install_modules="install-modules"
85267  suffix=la
85268
85269  case $host_alias in
85270    *aix*)
85271      additional_flags="-Wl,-G"
85272      ;;
85273  esac
85274
85275  if test "x" = "xyes"; then
85276    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/zip.$suffix"
85277  else
85278    PHP_MODULES="$PHP_MODULES \$(phplibdir)/zip.$suffix"
85279  fi
85280
85281  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_zip"
85282
85283  cat >>Makefile.objects<<EOF
85284\$(phplibdir)/zip.$suffix: $ext_builddir/zip.$suffix
85285	\$(LIBTOOL) --mode=install cp $ext_builddir/zip.$suffix \$(phplibdir)
85286
85287$ext_builddir/zip.$suffix: \$(shared_objects_zip) \$(ZIP_SHARED_DEPENDENCIES)
85288	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_zip) \$(ZIP_SHARED_LIBADD)
85289
85290EOF
85291
85292
85293printf "%s\n" "#define COMPILE_DL_ZIP 1" >>confdefs.h
85294
85295    fi
85296  fi
85297
85298  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
85299    PHP_ZIP_SHARED=no
85300    case "$PHP_SAPI" in
85301      cgi|embed|phpdbg)
85302
85303
85304  case $ext_dir in
85305  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
85306  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
85307  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
85308  esac
85309
85310
85311
85312  b_c_pre=$php_c_pre
85313  b_cxx_pre=$php_cxx_pre
85314  b_c_meta=$php_c_meta
85315  b_cxx_meta=$php_cxx_meta
85316  b_c_post=$php_c_post
85317  b_cxx_post=$php_cxx_post
85318  b_lo=$php_lo
85319
85320
85321  old_IFS=$IFS
85322  for ac_src in $PHP_ZIP_SOURCES; do
85323
85324      IFS=.
85325      set $ac_src
85326      ac_obj=$1
85327      IFS=$old_IFS
85328
85329      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
85330
85331      case $ac_src in
85332        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85333        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85334        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85335        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
85336      esac
85337
85338      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
85339
85340    cat >>Makefile.objects<<EOF
85341-include $ac_bdir$ac_obj.dep
85342$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
85343	$ac_comp
85344EOF
85345  done
85346
85347
85348        EXT_STATIC="$EXT_STATIC zip;$ext_dir"
85349        ;;
85350      *)
85351
85352
85353  case $ext_dir in
85354  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
85355  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
85356  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
85357  esac
85358
85359
85360
85361  b_c_pre=$php_c_pre
85362  b_cxx_pre=$php_cxx_pre
85363  b_c_meta=$php_c_meta
85364  b_cxx_meta=$php_cxx_meta
85365  b_c_post=$php_c_post
85366  b_cxx_post=$php_cxx_post
85367  b_lo=$php_lo
85368
85369
85370  old_IFS=$IFS
85371  for ac_src in $PHP_ZIP_SOURCES; do
85372
85373      IFS=.
85374      set $ac_src
85375      ac_obj=$1
85376      IFS=$old_IFS
85377
85378      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
85379
85380      case $ac_src in
85381        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85382        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85383        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
85384        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
85385      esac
85386
85387      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
85388
85389    cat >>Makefile.objects<<EOF
85390-include $ac_bdir$ac_obj.dep
85391$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
85392	$ac_comp
85393EOF
85394  done
85395
85396
85397        ;;
85398    esac
85399    EXT_CLI_STATIC="$EXT_CLI_STATIC zip;$ext_dir"
85400  fi
85401
85402
85403    BUILD_DIR="$BUILD_DIR $ext_builddir"
85404
85405
85406
85407  if test "$ext_builddir" = "."; then
85408    PHP_PECL_EXTENSION=zip
85409
85410  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
85411
85412  fi
85413
85414
85415
85416  PHP_VAR_SUBST="$PHP_VAR_SUBST ZIP_SHARED_LIBADD"
85417
85418
85419
85420  src=$ext_srcdir/Makefile.frag
85421  ac_srcdir=$ext_srcdir
85422  ac_builddir=$ext_builddir
85423  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
85424
85425fi
85426
85427
85428
85429
85430
85431php_enable_mysqlnd=no
85432
85433{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable mysqlnd" >&5
85434printf %s "checking whether to enable mysqlnd... " >&6; }
85435# Check whether --enable-mysqlnd was given.
85436if test ${enable_mysqlnd+y}
85437then :
85438  enableval=$enable_mysqlnd; PHP_MYSQLND=$enableval
85439else $as_nop
85440
85441  PHP_MYSQLND=no
85442  test "$PHP_ENABLE_ALL" && PHP_MYSQLND=$PHP_ENABLE_ALL
85443
85444fi
85445
85446
85447
85448ext_output="yes, shared"
85449ext_shared=yes
85450case $PHP_MYSQLND in
85451shared,*)
85452  PHP_MYSQLND=`echo "$PHP_MYSQLND"|$SED 's/^shared,//'`
85453  ;;
85454shared)
85455  PHP_MYSQLND=yes
85456  ;;
85457no)
85458  ext_output=no
85459  ext_shared=no
85460  ;;
85461*)
85462  ext_output=yes
85463  ext_shared=no
85464  ;;
85465esac
85466
85467
85468
85469{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
85470printf "%s\n" "$ext_output" >&6; }
85471
85472
85473
85474
85475
85476php_enable_mysqlnd_compression_support=yes
85477
85478{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to disable compressed protocol support in mysqlnd" >&5
85479printf %s "checking whether to disable compressed protocol support in mysqlnd... " >&6; }
85480# Check whether --enable-mysqlnd_compression_support was given.
85481if test ${enable_mysqlnd_compression_support+y}
85482then :
85483  enableval=$enable_mysqlnd_compression_support; PHP_MYSQLND_COMPRESSION_SUPPORT=$enableval
85484else $as_nop
85485
85486  PHP_MYSQLND_COMPRESSION_SUPPORT=yes
85487
85488
85489fi
85490
85491
85492ext_output=$PHP_MYSQLND_COMPRESSION_SUPPORT
85493{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
85494printf "%s\n" "$ext_output" >&6; }
85495
85496
85497
85498
85499if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes"; then
85500  mysqlnd_ps_sources="mysqlnd_ps.c mysqlnd_ps_codec.c"
85501  mysqlnd_base_sources="mysqlnd_connection.c mysqlnd_alloc.c mysqlnd_charset.c mysqlnd_wireprotocol.c \
85502                   mysqlnd_loaddata.c mysqlnd_reverse_api.c mysqlnd_vio.c mysqlnd_protocol_frame_codec.c \
85503                   mysqlnd_statistics.c mysqlnd_driver.c mysqlnd_ext_plugin.c mysqlnd_auth.c \
85504				   mysqlnd_result.c mysqlnd_result_meta.c mysqlnd_debug.c mysqlnd_commands.c \
85505				   mysqlnd_block_alloc.c mysqlnd_read_buffer.c mysqlnd_plugin.c php_mysqlnd.c"
85506
85507
85508  if test "$PHP_MYSQLND_COMPRESSION_SUPPORT" != "no"; then
85509
85510pkg_failed=no
85511{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zlib" >&5
85512printf %s "checking for zlib... " >&6; }
85513
85514if test -n "$ZLIB_CFLAGS"; then
85515    pkg_cv_ZLIB_CFLAGS="$ZLIB_CFLAGS"
85516 elif test -n "$PKG_CONFIG"; then
85517    if test -n "$PKG_CONFIG" && \
85518    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib\""; } >&5
85519  ($PKG_CONFIG --exists --print-errors "zlib") 2>&5
85520  ac_status=$?
85521  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
85522  test $ac_status = 0; }; then
85523  pkg_cv_ZLIB_CFLAGS=`$PKG_CONFIG --cflags "zlib" 2>/dev/null`
85524		      test "x$?" != "x0" && pkg_failed=yes
85525else
85526  pkg_failed=yes
85527fi
85528 else
85529    pkg_failed=untried
85530fi
85531if test -n "$ZLIB_LIBS"; then
85532    pkg_cv_ZLIB_LIBS="$ZLIB_LIBS"
85533 elif test -n "$PKG_CONFIG"; then
85534    if test -n "$PKG_CONFIG" && \
85535    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"zlib\""; } >&5
85536  ($PKG_CONFIG --exists --print-errors "zlib") 2>&5
85537  ac_status=$?
85538  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
85539  test $ac_status = 0; }; then
85540  pkg_cv_ZLIB_LIBS=`$PKG_CONFIG --libs "zlib" 2>/dev/null`
85541		      test "x$?" != "x0" && pkg_failed=yes
85542else
85543  pkg_failed=yes
85544fi
85545 else
85546    pkg_failed=untried
85547fi
85548
85549
85550
85551if test $pkg_failed = yes; then
85552        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
85553printf "%s\n" "no" >&6; }
85554
85555if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
85556        _pkg_short_errors_supported=yes
85557else
85558        _pkg_short_errors_supported=no
85559fi
85560        if test $_pkg_short_errors_supported = yes; then
85561	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "zlib" 2>&1`
85562        else
85563	        ZLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "zlib" 2>&1`
85564        fi
85565	# Put the nasty error message in config.log where it belongs
85566	echo "$ZLIB_PKG_ERRORS" >&5
85567
85568	as_fn_error $? "Package requirements (zlib) were not met:
85569
85570$ZLIB_PKG_ERRORS
85571
85572Consider adjusting the PKG_CONFIG_PATH environment variable if you
85573installed software in a non-standard prefix.
85574
85575Alternatively, you may set the environment variables ZLIB_CFLAGS
85576and ZLIB_LIBS to avoid the need to call pkg-config.
85577See the pkg-config man page for more details." "$LINENO" 5
85578elif test $pkg_failed = untried; then
85579        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
85580printf "%s\n" "no" >&6; }
85581	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
85582printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
85583as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
85584is in your PATH or set the PKG_CONFIG environment variable to the full
85585path to pkg-config.
85586
85587Alternatively, you may set the environment variables ZLIB_CFLAGS
85588and ZLIB_LIBS to avoid the need to call pkg-config.
85589See the pkg-config man page for more details.
85590
85591To get pkg-config, see <http://pkg-config.freedesktop.org/>.
85592See \`config.log' for more details" "$LINENO" 5; }
85593else
85594	ZLIB_CFLAGS=$pkg_cv_ZLIB_CFLAGS
85595	ZLIB_LIBS=$pkg_cv_ZLIB_LIBS
85596        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
85597printf "%s\n" "yes" >&6; }
85598
85599fi
85600
85601  for ac_i in $ZLIB_LIBS; do
85602    case $ac_i in
85603    -pthread)
85604      if test "$ext_shared" = "yes"; then
85605        MYSQLND_SHARED_LIBADD="$MYSQLND_SHARED_LIBADD -pthread"
85606      else
85607
85608
85609  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85610
85611  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
85612  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85613    eval "EXTRA_LDFLAGS$unique=set"
85614    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
85615  fi
85616
85617
85618
85619  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85620
85621  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
85622  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85623    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
85624    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
85625  fi
85626
85627      fi
85628    ;;
85629    -l*)
85630      ac_ii=`echo $ac_i|cut -c 3-`
85631
85632
85633  case $ac_ii in
85634  c|c_r) ;;
85635  *)
85636    if test "$ext_shared" = "yes"; then
85637        MYSQLND_SHARED_LIBADD="$MYSQLND_SHARED_LIBADD -l$ac_ii"
85638    else
85639
85640
85641  case $ac_ii in
85642  c|c_r) ;;
85643  *)
85644      LIBS="$LIBS -l$ac_ii"
85645   ;;
85646  esac
85647
85648
85649    fi
85650   ;;
85651  esac
85652
85653
85654    ;;
85655    -L*)
85656      ac_ii=`echo $ac_i|cut -c 3-`
85657
85658  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
85659
85660  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
85661    ai_p=$ac_ii
85662  else
85663
85664    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
85665
85666    ep_realdir=`(cd "$ep_dir" && pwd)`
85667    ai_p="$ep_realdir"/`basename "$ac_ii"`
85668  fi
85669
85670
85671      if test "$ext_shared" = "yes"; then
85672        MYSQLND_SHARED_LIBADD="-L$ai_p $MYSQLND_SHARED_LIBADD"
85673        test -n "$ld_runpath_switch" && MYSQLND_SHARED_LIBADD="$ld_runpath_switch$ai_p $MYSQLND_SHARED_LIBADD"
85674      else
85675
85676
85677
85678  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
85679
85680  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
85681  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85682    eval "LIBPATH$unique=set"
85683
85684    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
85685    LDFLAGS="$LDFLAGS -L$ai_p"
85686    PHP_RPATHS="$PHP_RPATHS $ai_p"
85687
85688  fi
85689
85690
85691      fi
85692
85693  fi
85694
85695    ;;
85696    esac
85697  done
85698
85699
85700  for ac_i in $ZLIB_CFLAGS; do
85701    case $ac_i in
85702    -I*)
85703      ac_ii=`echo $ac_i|cut -c 3-`
85704
85705  if test "$ac_ii" != "/usr/include"; then
85706
85707  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
85708    ai_p=$ac_ii
85709  else
85710
85711    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
85712
85713    ep_realdir=`(cd "$ep_dir" && pwd)`
85714    ai_p="$ep_realdir"/`basename "$ac_ii"`
85715  fi
85716
85717
85718
85719  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
85720
85721  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
85722  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85723    eval "INCLUDEPATH$unique=set"
85724
85725      if test ""; then
85726        INCLUDES="-I$ai_p $INCLUDES"
85727      else
85728        INCLUDES="$INCLUDES -I$ai_p"
85729      fi
85730
85731  fi
85732
85733  fi
85734
85735    ;;
85736    esac
85737  done
85738
85739
85740printf "%s\n" "#define MYSQLND_COMPRESSION_ENABLED 1" >>confdefs.h
85741
85742  fi
85743
85744
85745printf "%s\n" "#define MYSQLND_SSL_SUPPORTED 1" >>confdefs.h
85746
85747
85748  test -z "$PHP_OPENSSL" && PHP_OPENSSL=no
85749
85750  if test "$PHP_OPENSSL" != "no" || test "$PHP_OPENSSL_DIR" != "no"; then
85751
85752  found_openssl=no
85753
85754
85755pkg_failed=no
85756{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for openssl >= 1.0.2" >&5
85757printf %s "checking for openssl >= 1.0.2... " >&6; }
85758
85759if test -n "$OPENSSL_CFLAGS"; then
85760    pkg_cv_OPENSSL_CFLAGS="$OPENSSL_CFLAGS"
85761 elif test -n "$PKG_CONFIG"; then
85762    if test -n "$PKG_CONFIG" && \
85763    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
85764  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
85765  ac_status=$?
85766  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
85767  test $ac_status = 0; }; then
85768  pkg_cv_OPENSSL_CFLAGS=`$PKG_CONFIG --cflags "openssl >= 1.0.2" 2>/dev/null`
85769		      test "x$?" != "x0" && pkg_failed=yes
85770else
85771  pkg_failed=yes
85772fi
85773 else
85774    pkg_failed=untried
85775fi
85776if test -n "$OPENSSL_LIBS"; then
85777    pkg_cv_OPENSSL_LIBS="$OPENSSL_LIBS"
85778 elif test -n "$PKG_CONFIG"; then
85779    if test -n "$PKG_CONFIG" && \
85780    { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openssl >= 1.0.2\""; } >&5
85781  ($PKG_CONFIG --exists --print-errors "openssl >= 1.0.2") 2>&5
85782  ac_status=$?
85783  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
85784  test $ac_status = 0; }; then
85785  pkg_cv_OPENSSL_LIBS=`$PKG_CONFIG --libs "openssl >= 1.0.2" 2>/dev/null`
85786		      test "x$?" != "x0" && pkg_failed=yes
85787else
85788  pkg_failed=yes
85789fi
85790 else
85791    pkg_failed=untried
85792fi
85793
85794
85795
85796if test $pkg_failed = yes; then
85797        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
85798printf "%s\n" "no" >&6; }
85799
85800if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
85801        _pkg_short_errors_supported=yes
85802else
85803        _pkg_short_errors_supported=no
85804fi
85805        if test $_pkg_short_errors_supported = yes; then
85806	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
85807        else
85808	        OPENSSL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openssl >= 1.0.2" 2>&1`
85809        fi
85810	# Put the nasty error message in config.log where it belongs
85811	echo "$OPENSSL_PKG_ERRORS" >&5
85812
85813	as_fn_error $? "Package requirements (openssl >= 1.0.2) were not met:
85814
85815$OPENSSL_PKG_ERRORS
85816
85817Consider adjusting the PKG_CONFIG_PATH environment variable if you
85818installed software in a non-standard prefix.
85819
85820Alternatively, you may set the environment variables OPENSSL_CFLAGS
85821and OPENSSL_LIBS to avoid the need to call pkg-config.
85822See the pkg-config man page for more details." "$LINENO" 5
85823elif test $pkg_failed = untried; then
85824        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
85825printf "%s\n" "no" >&6; }
85826	{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
85827printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
85828as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
85829is in your PATH or set the PKG_CONFIG environment variable to the full
85830path to pkg-config.
85831
85832Alternatively, you may set the environment variables OPENSSL_CFLAGS
85833and OPENSSL_LIBS to avoid the need to call pkg-config.
85834See the pkg-config man page for more details.
85835
85836To get pkg-config, see <http://pkg-config.freedesktop.org/>.
85837See \`config.log' for more details" "$LINENO" 5; }
85838else
85839	OPENSSL_CFLAGS=$pkg_cv_OPENSSL_CFLAGS
85840	OPENSSL_LIBS=$pkg_cv_OPENSSL_LIBS
85841        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
85842printf "%s\n" "yes" >&6; }
85843	found_openssl=yes
85844fi
85845
85846  if test "$found_openssl" = "yes"; then
85847
85848  for ac_i in $OPENSSL_LIBS; do
85849    case $ac_i in
85850    -pthread)
85851      if test "$ext_shared" = "yes"; then
85852        MYSQLND_SHARED_LIBADD="$MYSQLND_SHARED_LIBADD -pthread"
85853      else
85854
85855
85856  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85857
85858  cmd="echo $ac_n \"\$EXTRA_LDFLAGS$unique$ac_c\""
85859  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85860    eval "EXTRA_LDFLAGS$unique=set"
85861    EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ac_i"
85862  fi
85863
85864
85865
85866  unique=`echo $ac_i|$SED 's/[^a-zA-Z0-9]/_/g'`
85867
85868  cmd="echo $ac_n \"\$EXTRA_LDFLAGS_PROGRAM$unique$ac_c\""
85869  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85870    eval "EXTRA_LDFLAGS_PROGRAM$unique=set"
85871    EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $ac_i"
85872  fi
85873
85874      fi
85875    ;;
85876    -l*)
85877      ac_ii=`echo $ac_i|cut -c 3-`
85878
85879
85880  case $ac_ii in
85881  c|c_r) ;;
85882  *)
85883    if test "$ext_shared" = "yes"; then
85884        MYSQLND_SHARED_LIBADD="$MYSQLND_SHARED_LIBADD -l$ac_ii"
85885    else
85886
85887
85888  case $ac_ii in
85889  c|c_r) ;;
85890  *)
85891      LIBS="$LIBS -l$ac_ii"
85892   ;;
85893  esac
85894
85895
85896    fi
85897   ;;
85898  esac
85899
85900
85901    ;;
85902    -L*)
85903      ac_ii=`echo $ac_i|cut -c 3-`
85904
85905  if test "$ac_ii" != "/usr/$PHP_LIBDIR" && test "$ac_ii" != "/usr/lib"; then
85906
85907  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
85908    ai_p=$ac_ii
85909  else
85910
85911    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
85912
85913    ep_realdir=`(cd "$ep_dir" && pwd)`
85914    ai_p="$ep_realdir"/`basename "$ac_ii"`
85915  fi
85916
85917
85918      if test "$ext_shared" = "yes"; then
85919        MYSQLND_SHARED_LIBADD="-L$ai_p $MYSQLND_SHARED_LIBADD"
85920        test -n "$ld_runpath_switch" && MYSQLND_SHARED_LIBADD="$ld_runpath_switch$ai_p $MYSQLND_SHARED_LIBADD"
85921      else
85922
85923
85924
85925  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
85926
85927  cmd="echo $ac_n \"\$LIBPATH$unique$ac_c\""
85928  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85929    eval "LIBPATH$unique=set"
85930
85931    test -n "$ld_runpath_switch" && LDFLAGS="$LDFLAGS $ld_runpath_switch$ai_p"
85932    LDFLAGS="$LDFLAGS -L$ai_p"
85933    PHP_RPATHS="$PHP_RPATHS $ai_p"
85934
85935  fi
85936
85937
85938      fi
85939
85940  fi
85941
85942    ;;
85943    esac
85944  done
85945
85946
85947  for ac_i in $OPENSSL_CFLAGS; do
85948    case $ac_i in
85949    -I*)
85950      ac_ii=`echo $ac_i|cut -c 3-`
85951
85952  if test "$ac_ii" != "/usr/include"; then
85953
85954  if test -z "$ac_ii" || echo "$ac_ii" | grep '^/' >/dev/null ; then
85955    ai_p=$ac_ii
85956  else
85957
85958    ep_dir=`echo $ac_ii|$SED 's%/*[^/][^/]*/*$%%'`
85959
85960    ep_realdir=`(cd "$ep_dir" && pwd)`
85961    ai_p="$ep_realdir"/`basename "$ac_ii"`
85962  fi
85963
85964
85965
85966  unique=`echo $ai_p|$SED 's/[^a-zA-Z0-9]/_/g'`
85967
85968  cmd="echo $ac_n \"\$INCLUDEPATH$unique$ac_c\""
85969  if test -n "$unique" && test "`eval $cmd`" = "" ; then
85970    eval "INCLUDEPATH$unique=set"
85971
85972      if test ""; then
85973        INCLUDES="-I$ai_p $INCLUDES"
85974      else
85975        INCLUDES="$INCLUDES -I$ai_p"
85976      fi
85977
85978  fi
85979
85980  fi
85981
85982    ;;
85983    esac
85984  done
85985
85986
85987printf "%s\n" "#define MYSQLND_HAVE_SSL 1" >>confdefs.h
85988
85989
85990  fi
85991
85992  fi
85993
85994  mysqlnd_sources="$mysqlnd_base_sources $mysqlnd_ps_sources"
85995
85996  ext_builddir=ext/mysqlnd
85997  ext_srcdir=$abs_srcdir/ext/mysqlnd
85998  ext_dir=ext/mysqlnd
85999
86000  ac_extra=`echo "-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1"|$SED s#@ext_srcdir@#$ext_srcdir#g|$SED s#@ext_builddir@#$ext_builddir#g`
86001
86002  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" != "cli"; then
86003    PHP_MYSQLND_SHARED=no
86004
86005
86006  case $ext_dir in
86007  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
86008  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
86009  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
86010  esac
86011
86012
86013
86014  b_c_pre=$php_c_pre
86015  b_cxx_pre=$php_cxx_pre
86016  b_c_meta=$php_c_meta
86017  b_cxx_meta=$php_cxx_meta
86018  b_c_post=$php_c_post
86019  b_cxx_post=$php_cxx_post
86020  b_lo=$php_lo
86021
86022
86023  old_IFS=$IFS
86024  for ac_src in $mysqlnd_sources; do
86025
86026      IFS=.
86027      set $ac_src
86028      ac_obj=$1
86029      IFS=$old_IFS
86030
86031      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
86032
86033      case $ac_src in
86034        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86035        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86036        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86037        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
86038      esac
86039
86040      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
86041
86042    cat >>Makefile.objects<<EOF
86043-include $ac_bdir$ac_obj.dep
86044$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
86045	$ac_comp
86046EOF
86047  done
86048
86049
86050    EXT_STATIC="$EXT_STATIC mysqlnd;$ext_dir"
86051    if test "$ext_shared" != "nocli"; then
86052      EXT_CLI_STATIC="$EXT_CLI_STATIC mysqlnd;$ext_dir"
86053    fi
86054  else
86055    if test "$ext_shared" = "shared" || test "$ext_shared" = "yes"; then
86056      PHP_MYSQLND_SHARED=yes
86057
86058  case $ext_dir in
86059  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
86060  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
86061  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
86062  esac
86063
86064
86065
86066  b_c_pre=$shared_c_pre
86067  b_cxx_pre=$shared_cxx_pre
86068  b_c_meta=$shared_c_meta
86069  b_cxx_meta=$shared_cxx_meta
86070  b_c_post=$shared_c_post
86071  b_cxx_post=$shared_cxx_post
86072  b_lo=$shared_lo
86073
86074
86075  old_IFS=$IFS
86076  for ac_src in $mysqlnd_sources; do
86077
86078      IFS=.
86079      set $ac_src
86080      ac_obj=$1
86081      IFS=$old_IFS
86082
86083      shared_objects_mysqlnd="$shared_objects_mysqlnd $ac_bdir$ac_obj.lo"
86084
86085      case $ac_src in
86086        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86087        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86088        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86089        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -DZEND_COMPILE_DL_EXT=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
86090      esac
86091
86092      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
86093
86094    cat >>Makefile.objects<<EOF
86095-include $ac_bdir$ac_obj.dep
86096$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
86097	$ac_comp
86098EOF
86099  done
86100
86101
86102  install_modules="install-modules"
86103  suffix=la
86104
86105  case $host_alias in
86106    *aix*)
86107      additional_flags="-Wl,-G"
86108      ;;
86109  esac
86110
86111  if test "x" = "xyes"; then
86112    PHP_ZEND_EX="$PHP_ZEND_EX \$(phplibdir)/mysqlnd.$suffix"
86113  else
86114    PHP_MODULES="$PHP_MODULES \$(phplibdir)/mysqlnd.$suffix"
86115  fi
86116
86117  PHP_VAR_SUBST="$PHP_VAR_SUBST shared_objects_mysqlnd"
86118
86119  cat >>Makefile.objects<<EOF
86120\$(phplibdir)/mysqlnd.$suffix: $ext_builddir/mysqlnd.$suffix
86121	\$(LIBTOOL) --mode=install cp $ext_builddir/mysqlnd.$suffix \$(phplibdir)
86122
86123$ext_builddir/mysqlnd.$suffix: \$(shared_objects_mysqlnd) \$(MYSQLND_SHARED_DEPENDENCIES)
86124	\$(LIBTOOL) --mode=link \$(CC) -shared \$(COMMON_FLAGS) \$(CFLAGS_CLEAN) \$(EXTRA_CFLAGS) \$(LDFLAGS) $additional_flags -o \$@ -export-dynamic -avoid-version -prefer-pic -module -rpath \$(phplibdir) \$(EXTRA_LDFLAGS) \$(shared_objects_mysqlnd) \$(MYSQLND_SHARED_LIBADD)
86125
86126EOF
86127
86128
86129printf "%s\n" "#define COMPILE_DL_MYSQLND 1" >>confdefs.h
86130
86131    fi
86132  fi
86133
86134  if test "$ext_shared" != "shared" && test "$ext_shared" != "yes" && test "" = "cli"; then
86135    PHP_MYSQLND_SHARED=no
86136    case "$PHP_SAPI" in
86137      cgi|embed|phpdbg)
86138
86139
86140  case $ext_dir in
86141  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
86142  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
86143  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
86144  esac
86145
86146
86147
86148  b_c_pre=$php_c_pre
86149  b_cxx_pre=$php_cxx_pre
86150  b_c_meta=$php_c_meta
86151  b_cxx_meta=$php_cxx_meta
86152  b_c_post=$php_c_post
86153  b_cxx_post=$php_cxx_post
86154  b_lo=$php_lo
86155
86156
86157  old_IFS=$IFS
86158  for ac_src in $mysqlnd_sources; do
86159
86160      IFS=.
86161      set $ac_src
86162      ac_obj=$1
86163      IFS=$old_IFS
86164
86165      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
86166
86167      case $ac_src in
86168        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86169        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86170        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86171        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
86172      esac
86173
86174      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
86175
86176    cat >>Makefile.objects<<EOF
86177-include $ac_bdir$ac_obj.dep
86178$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
86179	$ac_comp
86180EOF
86181  done
86182
86183
86184        EXT_STATIC="$EXT_STATIC mysqlnd;$ext_dir"
86185        ;;
86186      *)
86187
86188
86189  case $ext_dir in
86190  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
86191  /*) ac_srcdir=`echo "$ext_dir"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
86192  *) ac_srcdir="$abs_srcdir/$ext_dir/"; ac_bdir="$ext_dir/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
86193  esac
86194
86195
86196
86197  b_c_pre=$php_c_pre
86198  b_cxx_pre=$php_cxx_pre
86199  b_c_meta=$php_c_meta
86200  b_cxx_meta=$php_cxx_meta
86201  b_c_post=$php_c_post
86202  b_cxx_post=$php_cxx_post
86203  b_lo=$php_lo
86204
86205
86206  old_IFS=$IFS
86207  for ac_src in $mysqlnd_sources; do
86208
86209      IFS=.
86210      set $ac_src
86211      ac_obj=$1
86212      IFS=$old_IFS
86213
86214      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
86215
86216      case $ac_src in
86217        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86218        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86219        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86220        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta $ac_extra -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
86221      esac
86222
86223      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
86224
86225    cat >>Makefile.objects<<EOF
86226-include $ac_bdir$ac_obj.dep
86227$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
86228	$ac_comp
86229EOF
86230  done
86231
86232
86233        ;;
86234    esac
86235    EXT_CLI_STATIC="$EXT_CLI_STATIC mysqlnd;$ext_dir"
86236  fi
86237
86238
86239    BUILD_DIR="$BUILD_DIR $ext_builddir"
86240
86241
86242
86243  if test "$ext_builddir" = "."; then
86244    PHP_PECL_EXTENSION=mysqlnd
86245
86246  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_PECL_EXTENSION"
86247
86248  fi
86249
86250
86251
86252    $php_shtool mkdir -p ext/mysqlnd
86253
86254
86255
86256
86257    for header_file in ext/mysqlnd/; do
86258
86259
86260  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
86261
86262  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
86263  if test -n "$unique" && test "`eval $cmd`" = "" ; then
86264    eval "INSTALLHEADERS$unique=set"
86265
86266        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
86267
86268  fi
86269
86270    done
86271
86272
86273fi
86274
86275if test "$PHP_MYSQLND" != "no" || test "$PHP_MYSQLND_ENABLED" = "yes" || test "$PHP_MYSQLI" != "no"; then
86276
86277
86278    $php_shtool mkdir -p ext/mysqlnd
86279
86280
86281fi
86282
86283
86284
86285
86286case $host_alias in
86287  i[3456]86-*-linux-* | x86_64-*-linux-*)
86288	{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking linker support for -zcommon-page-size=2097152" >&5
86289printf %s "checking linker support for -zcommon-page-size=2097152... " >&6; }
86290    save_LDFLAGS=$LDFLAGS
86291    LDFLAGS="$LDFLAGS -Wl,-zcommon-page-size=2097152 -Wl,-zmax-page-size=2097152"
86292    if test "$cross_compiling" = yes
86293then :
86294  ac_cv_common_page_size=no
86295else $as_nop
86296  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86297/* end confdefs.h.  */
86298int main() {return 0;}
86299_ACEOF
86300if ac_fn_c_try_run "$LINENO"
86301then :
86302  ac_cv_common_page_size=yes
86303else $as_nop
86304  ac_cv_common_page_size=no
86305fi
86306rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
86307  conftest.$ac_objext conftest.beam conftest.$ac_ext
86308fi
86309
86310    LDFLAGS=$save_LDFLAGS
86311    if test "$ac_cv_common_page_size" = "yes"; then
86312        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86313printf "%s\n" "yes" >&6; }
86314        EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM -Wl,-zcommon-page-size=2097152 -Wl,-zmax-page-size=2097152"
86315    else
86316        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86317printf "%s\n" "no" >&6; }
86318        { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking linker support for -zmax-page-size=2097152" >&5
86319printf %s "checking linker support for -zmax-page-size=2097152... " >&6; }
86320        save_LDFLAGS=$LDFLAGS
86321        LDFLAGS="$LDFLAGS -Wl,-zmax-page-size=2097152"
86322        if test "$cross_compiling" = yes
86323then :
86324  ac_cv_max_page_size=no
86325else $as_nop
86326  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86327/* end confdefs.h.  */
86328int main() {return 0;}
86329_ACEOF
86330if ac_fn_c_try_run "$LINENO"
86331then :
86332  ac_cv_max_page_size=yes
86333else $as_nop
86334  ac_cv_max_page_size=no
86335fi
86336rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
86337  conftest.$ac_objext conftest.beam conftest.$ac_ext
86338fi
86339
86340        LDFLAGS=$save_LDFLAGS
86341        if test "$ac_cv_max_page_size" = "yes"; then
86342            { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86343printf "%s\n" "yes" >&6; }
86344            EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM -Wl,-zmax-page-size=2097152"
86345        else
86346            { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86347printf "%s\n" "no" >&6; }
86348        fi
86349    fi
86350    ;;
86351esac
86352
86353enable_shared=yes
86354enable_static=yes
86355
86356case $php_sapi_module in
86357  shared)
86358    if test "$PHP_CGI" = "no" && test "$PHP_CLI" = "no" && test "$PHP_FPM" = "no" && test "$PHP_LITESPEED" = "no" && test "$PHP_PHPDBG" = "no"; then
86359      enable_static=no
86360    fi
86361    case $with_pic in
86362      yes)
86363        standard_libtool_flag='-prefer-pic'
86364        ;;
86365      no)
86366        standard_libtool_flag='-prefer-non-pic'
86367        ;;
86368    esac
86369    EXTRA_LDFLAGS="$EXTRA_LDFLAGS -avoid-version -module"
86370    ;;
86371  *)
86372    standard_libtool_flag='-prefer-non-pic -static'
86373    if test -z "$PHP_MODULES" && test -z "$PHP_ZEND_EX"; then
86374      enable_shared=no
86375    fi
86376    ;;
86377esac
86378
86379EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS"
86380
86381if test "$ac_cv_lib_crypt_crypt" = "yes"; then
86382  EXTRA_LIBS="-lcrypt $EXTRA_LIBS -lcrypt"
86383fi
86384
86385unset LIBS LDFLAGS
86386
86387
86388
86389# Check whether --enable- was given.
86390if test ${enable_+y}
86391then :
86392  enableval=$enable_;
86393fi
86394
86395
86396
86397  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
86398printf "%s\n" "" >&6; }
86399  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring PEAR${T_ME}" >&5
86400printf "%s\n" "${T_MD}Configuring PEAR${T_ME}" >&6; }
86401
86402
86403if test -z "$with_pear" && test "$enable_pear" = "no"; then
86404  with_pear=no
86405fi
86406
86407if test "$PHP_CLI" = "no"; then
86408  with_pear=no
86409fi
86410
86411
86412php_with_pear=no
86413
86414{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to install PEAR" >&5
86415printf %s "checking whether to install PEAR... " >&6; }
86416
86417# Check whether --with-pear was given.
86418if test ${with_pear+y}
86419then :
86420  withval=$with_pear; PHP_PEAR=$withval
86421else $as_nop
86422
86423  PHP_PEAR=no
86424  test "$PHP_ENABLE_ALL" && PHP_PEAR=$PHP_ENABLE_ALL
86425
86426fi
86427
86428
86429
86430ext_output="yes, shared"
86431ext_shared=yes
86432case $PHP_PEAR in
86433shared,*)
86434  PHP_PEAR=`echo "$PHP_PEAR"|$SED 's/^shared,//'`
86435  ;;
86436shared)
86437  PHP_PEAR=yes
86438  ;;
86439no)
86440  ext_output=no
86441  ext_shared=no
86442  ;;
86443*)
86444  ext_output=yes
86445  ext_shared=no
86446  ;;
86447esac
86448
86449
86450
86451{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ext_output" >&5
86452printf "%s\n" "$ext_output" >&6; }
86453
86454
86455
86456
86457if test "$PHP_PEAR" != "no"; then
86458
86459    if test "$PHP_XML" = "no"; then
86460    pear_error_msg="$pear_error_msg
86461                    PEAR requires XML to be enabled.     Add --enable-xml to the configure line. (or --without-pear)"
86462  fi
86463
86464  if test "$pear_error_msg"; then
86465    as_fn_error $? "$pear_error_msg" "$LINENO" 5
86466  fi
86467
86468  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: The --with-pear option is deprecated" >&5
86469printf "%s\n" "$as_me: WARNING: The --with-pear option is deprecated" >&2;}
86470
86471  install_pear="install-pear"
86472  PEAR_INSTALLDIR=$PHP_PEAR
86473
86474  if test "$PHP_PEAR" = "yes"; then
86475    case $PHP_LAYOUT in
86476      GNU) PEAR_INSTALLDIR=$datadir/pear;;
86477      *)   PEAR_INSTALLDIR=$libdir/php;;
86478    esac
86479  fi
86480
86481
86482  src=$abs_srcdir/pear/Makefile.frag
86483  ac_srcdir=$abs_srcdir/pear
86484  ac_builddir=pear
86485  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
86486
86487fi
86488
86489
86490# Check whether --enable-fiber-asm was given.
86491if test ${enable_fiber_asm+y}
86492then :
86493  enableval=$enable_fiber_asm; fiber_asm=$enableval
86494else $as_nop
86495  fiber_asm='yes'
86496fi
86497
86498
86499
86500# Check whether --enable- was given.
86501if test ${enable_+y}
86502then :
86503  enableval=$enable_;
86504fi
86505
86506
86507
86508  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
86509printf "%s\n" "" >&6; }
86510  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring Zend${T_ME}" >&5
86511printf "%s\n" "${T_MD}Configuring Zend${T_ME}" >&6; }
86512
86513
86514case $host_cpu in #(
86515  x86_64*|amd64*) :
86516    fiber_cpu="x86_64" ;; #(
86517  x86*|amd*|i?86*|pentium) :
86518    fiber_cpu="i386" ;; #(
86519  aarch64*|arm64*) :
86520    fiber_cpu="arm64" ;; #(
86521  arm*) :
86522    fiber_cpu="arm32" ;; #(
86523  ppc64*|powerpc64*) :
86524    fiber_cpu="ppc64" ;; #(
86525  ppc*|powerpc*) :
86526    fiber_cpu="ppc32" ;; #(
86527  s390x*) :
86528    fiber_cpu="s390x" ;; #(
86529  mips64*) :
86530    fiber_cpu="mips64" ;; #(
86531  mips*) :
86532    fiber_cpu="mips32" ;; #(
86533  *) :
86534    fiber_cpu="unknown"
86535 ;;
86536esac
86537
86538case $host_os in #(
86539  darwin*) :
86540    fiber_os="mac" ;; #(
86541  aix*|os400*) :
86542    fiber_os="aix" ;; #(
86543  *) :
86544    fiber_os="other"
86545 ;;
86546esac
86547
86548case $fiber_cpu in #(
86549  x86_64) :
86550    fiber_asm_file_prefix="x86_64_sysv" ;; #(
86551  i386) :
86552    fiber_asm_file_prefix="i386_sysv" ;; #(
86553  arm64) :
86554    fiber_asm_file_prefix="arm64_aapcs" ;; #(
86555  arm32) :
86556    fiber_asm_file_prefix="arm_aapcs" ;; #(
86557  ppc64) :
86558    fiber_asm_file_prefix="ppc64_sysv" ;; #(
86559  ppc32) :
86560    fiber_asm_file_prefix="ppc32_sysv" ;; #(
86561  s390x) :
86562    fiber_asm_file_prefix="s390x_sysv" ;; #(
86563  mips64) :
86564    fiber_asm_file_prefix="mips64_n64" ;; #(
86565  mips32) :
86566    fiber_asm_file_prefix="mips32_o32" ;; #(
86567  *) :
86568    fiber_asm_file_prefix="unknown"
86569 ;;
86570esac
86571
86572if test "$fiber_os" = 'mac'; then
86573  fiber_asm_file="combined_sysv_macho_gas"
86574elif test "$fiber_os" = 'aix'; then
86575  # AIX uses a different calling convention (shared with non-_CALL_ELF Linux).
86576  # The AIX assembler isn't GNU, but the file is compatible.
86577  fiber_asm_file="${fiber_asm_file_prefix}_xcoff_gas"
86578elif test "$fiber_asm_file_prefix" != 'unknown'; then
86579  fiber_asm_file="${fiber_asm_file_prefix}_elf_gas"
86580else
86581  fiber_asm="no"
86582fi
86583
86584if test "$fiber_asm" = 'yes'; then
86585  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fiber switching context" >&5
86586printf %s "checking for fiber switching context... " >&6; }
86587
86588printf "%s\n" "#define ZEND_FIBER_ASM 1" >>confdefs.h
86589
86590
86591
86592  case Zend/asm in
86593  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
86594  /*) ac_srcdir=`echo "Zend/asm"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
86595  *) ac_srcdir="$abs_srcdir/Zend/asm/"; ac_bdir="Zend/asm/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
86596  esac
86597
86598
86599
86600  b_c_pre=$php_c_pre
86601  b_cxx_pre=$php_cxx_pre
86602  b_c_meta=$php_c_meta
86603  b_cxx_meta=$php_cxx_meta
86604  b_c_post=$php_c_post
86605  b_cxx_post=$php_cxx_post
86606  b_lo=$php_lo
86607
86608
86609  old_IFS=$IFS
86610  for ac_src in make_${fiber_asm_file}.S jump_${fiber_asm_file}.S; do
86611
86612      IFS=.
86613      set $ac_src
86614      ac_obj=$1
86615      IFS=$old_IFS
86616
86617      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
86618
86619      case $ac_src in
86620        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86621        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86622        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
86623        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta  -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
86624      esac
86625
86626      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
86627
86628    cat >>Makefile.objects<<EOF
86629-include $ac_bdir$ac_obj.dep
86630$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
86631	$ac_comp
86632EOF
86633  done
86634
86635
86636  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $fiber_asm_file" >&5
86637printf "%s\n" "$fiber_asm_file" >&6; }
86638else
86639  if test "$fiber_os" = 'mac'; then
86640
86641printf "%s\n" "#define _XOPEN_SOURCE 1" >>confdefs.h
86642
86643  fi
86644  ac_fn_c_check_header_compile "$LINENO" "ucontext.h" "ac_cv_header_ucontext_h" "$ac_includes_default"
86645if test "x$ac_cv_header_ucontext_h" = xyes
86646then :
86647
86648
86649printf "%s\n" "#define ZEND_FIBER_UCONTEXT 1" >>confdefs.h
86650
86651
86652else $as_nop
86653
86654       as_fn_error $? "fibers not available on this platform" "$LINENO" 5
86655
86656fi
86657
86658fi
86659
86660
86661
86662
86663ac_fn_c_check_header_compile "$LINENO" "cpuid.h" "ac_cv_header_cpuid_h" "$ac_includes_default"
86664if test "x$ac_cv_header_cpuid_h" = xyes
86665then :
86666  printf "%s\n" "#define HAVE_CPUID_H 1" >>confdefs.h
86667
86668fi
86669
86670
86671
86672
86673ac_fn_c_check_func "$LINENO" "getpid" "ac_cv_func_getpid"
86674if test "x$ac_cv_func_getpid" = xyes
86675then :
86676  printf "%s\n" "#define HAVE_GETPID 1" >>confdefs.h
86677
86678fi
86679ac_fn_c_check_func "$LINENO" "kill" "ac_cv_func_kill"
86680if test "x$ac_cv_func_kill" = xyes
86681then :
86682  printf "%s\n" "#define HAVE_KILL 1" >>confdefs.h
86683
86684fi
86685ac_fn_c_check_func "$LINENO" "sigsetjmp" "ac_cv_func_sigsetjmp"
86686if test "x$ac_cv_func_sigsetjmp" = xyes
86687then :
86688  printf "%s\n" "#define HAVE_SIGSETJMP 1" >>confdefs.h
86689
86690fi
86691
86692
86693
86694  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable _FPU_SETCW" >&5
86695printf %s "checking for usable _FPU_SETCW... " >&6; }
86696  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86697/* end confdefs.h.  */
86698
86699    #include <fpu_control.h>
86700
86701int
86702main (void)
86703{
86704
86705    fpu_control_t fpu_oldcw, fpu_cw;
86706    volatile double result;
86707    double a = 2877.0;
86708    volatile double b = 1000000.0;
86709
86710    _FPU_GETCW(fpu_oldcw);
86711    fpu_cw = (fpu_oldcw & ~_FPU_EXTENDED & ~_FPU_SINGLE) | _FPU_DOUBLE;
86712    _FPU_SETCW(fpu_cw);
86713    result = a / b;
86714    _FPU_SETCW(fpu_oldcw);
86715
86716  ;
86717  return 0;
86718}
86719_ACEOF
86720if ac_fn_c_try_link "$LINENO"
86721then :
86722  ac_cfp_have__fpu_setcw=yes
86723else $as_nop
86724  ac_cfp_have__fpu_setcw=no
86725fi
86726rm -f core conftest.err conftest.$ac_objext conftest.beam \
86727    conftest$ac_exeext conftest.$ac_ext
86728  if test "$ac_cfp_have__fpu_setcw" = "yes" ; then
86729
86730printf "%s\n" "#define HAVE__FPU_SETCW 1" >>confdefs.h
86731
86732    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86733printf "%s\n" "yes" >&6; }
86734  else
86735    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86736printf "%s\n" "no" >&6; }
86737  fi
86738
86739  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable fpsetprec" >&5
86740printf %s "checking for usable fpsetprec... " >&6; }
86741  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86742/* end confdefs.h.  */
86743
86744    #include <machine/ieeefp.h>
86745
86746int
86747main (void)
86748{
86749
86750    fp_prec_t fpu_oldprec;
86751    volatile double result;
86752    double a = 2877.0;
86753    volatile double b = 1000000.0;
86754
86755    fpu_oldprec = fpgetprec();
86756    fpsetprec(FP_PD);
86757    result = a / b;
86758    fpsetprec(fpu_oldprec);
86759
86760  ;
86761  return 0;
86762}
86763_ACEOF
86764if ac_fn_c_try_link "$LINENO"
86765then :
86766  ac_cfp_have_fpsetprec=yes
86767else $as_nop
86768  ac_cfp_have_fpsetprec=no
86769fi
86770rm -f core conftest.err conftest.$ac_objext conftest.beam \
86771    conftest$ac_exeext conftest.$ac_ext
86772  if test "$ac_cfp_have_fpsetprec" = "yes" ; then
86773
86774printf "%s\n" "#define HAVE_FPSETPREC 1" >>confdefs.h
86775
86776    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86777printf "%s\n" "yes" >&6; }
86778  else
86779    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86780printf "%s\n" "no" >&6; }
86781  fi
86782
86783  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable _controlfp" >&5
86784printf %s "checking for usable _controlfp... " >&6; }
86785  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86786/* end confdefs.h.  */
86787
86788    #include <float.h>
86789
86790int
86791main (void)
86792{
86793
86794    unsigned int fpu_oldcw;
86795    volatile double result;
86796    double a = 2877.0;
86797    volatile double b = 1000000.0;
86798
86799    fpu_oldcw = _controlfp(0, 0);
86800    _controlfp(_PC_53, _MCW_PC);
86801    result = a / b;
86802    _controlfp(fpu_oldcw, _MCW_PC);
86803
86804  ;
86805  return 0;
86806}
86807_ACEOF
86808if ac_fn_c_try_link "$LINENO"
86809then :
86810  ac_cfp_have__controlfp=yes
86811else $as_nop
86812  ac_cfp_have__controlfp=no
86813fi
86814rm -f core conftest.err conftest.$ac_objext conftest.beam \
86815    conftest$ac_exeext conftest.$ac_ext
86816  if test "$ac_cfp_have__controlfp" = "yes" ; then
86817
86818printf "%s\n" "#define HAVE__CONTROLFP 1" >>confdefs.h
86819
86820    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86821printf "%s\n" "yes" >&6; }
86822  else
86823    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86824printf "%s\n" "no" >&6; }
86825  fi
86826
86827  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable _controlfp_s" >&5
86828printf %s "checking for usable _controlfp_s... " >&6; }
86829  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86830/* end confdefs.h.  */
86831
86832   #include <float.h>
86833
86834int
86835main (void)
86836{
86837
86838    unsigned int fpu_oldcw, fpu_cw;
86839    volatile double result;
86840    double a = 2877.0;
86841    volatile double b = 1000000.0;
86842
86843    _controlfp_s(&fpu_cw, 0, 0);
86844    fpu_oldcw = fpu_cw;
86845    _controlfp_s(&fpu_cw, _PC_53, _MCW_PC);
86846    result = a / b;
86847    _controlfp_s(&fpu_cw, fpu_oldcw, _MCW_PC);
86848
86849  ;
86850  return 0;
86851}
86852_ACEOF
86853if ac_fn_c_try_link "$LINENO"
86854then :
86855  ac_cfp_have__controlfp_s=yes
86856else $as_nop
86857  ac_cfp_have__controlfp_s=no
86858fi
86859rm -f core conftest.err conftest.$ac_objext conftest.beam \
86860    conftest$ac_exeext conftest.$ac_ext
86861  if test "$ac_cfp_have__controlfp_s" = "yes" ; then
86862
86863printf "%s\n" "#define HAVE__CONTROLFP_S 1" >>confdefs.h
86864
86865    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86866printf "%s\n" "yes" >&6; }
86867  else
86868    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86869printf "%s\n" "no" >&6; }
86870  fi
86871
86872  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether FPU control word can be manipulated by inline assembler" >&5
86873printf %s "checking whether FPU control word can be manipulated by inline assembler... " >&6; }
86874  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86875/* end confdefs.h.  */
86876
86877    /* nothing */
86878
86879int
86880main (void)
86881{
86882
86883    unsigned int oldcw, cw;
86884    volatile double result;
86885    double a = 2877.0;
86886    volatile double b = 1000000.0;
86887
86888    __asm__ __volatile__ ("fnstcw %0" : "=m" (*&oldcw));
86889    cw = (oldcw & ~0x0 & ~0x300) | 0x200;
86890    __asm__ __volatile__ ("fldcw %0" : : "m" (*&cw));
86891
86892    result = a / b;
86893
86894    __asm__ __volatile__ ("fldcw %0" : : "m" (*&oldcw));
86895
86896  ;
86897  return 0;
86898}
86899_ACEOF
86900if ac_fn_c_try_link "$LINENO"
86901then :
86902  ac_cfp_have_fpu_inline_asm_x86=yes
86903else $as_nop
86904  ac_cfp_have_fpu_inline_asm_x86=no
86905fi
86906rm -f core conftest.err conftest.$ac_objext conftest.beam \
86907    conftest$ac_exeext conftest.$ac_ext
86908  if test "$ac_cfp_have_fpu_inline_asm_x86" = "yes" ; then
86909
86910printf "%s\n" "#define HAVE_FPU_INLINE_ASM_X86 1" >>confdefs.h
86911
86912    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86913printf "%s\n" "yes" >&6; }
86914  else
86915    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86916printf "%s\n" "no" >&6; }
86917  fi
86918
86919
86920{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether double cast to long preserves least significant bits" >&5
86921printf %s "checking whether double cast to long preserves least significant bits... " >&6; }
86922
86923if test "$cross_compiling" = yes
86924then :
86925
86926  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86927printf "%s\n" "no" >&6; }
86928
86929else $as_nop
86930  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
86931/* end confdefs.h.  */
86932
86933#include <limits.h>
86934#include <stdlib.h>
86935
86936int main()
86937{
86938	if (sizeof(long) == 4) {
86939		double d = (double) LONG_MIN * LONG_MIN + 2e9;
86940
86941		if ((long) d == 2e9 && (long) -d == -2e9) {
86942			return 0;
86943		}
86944	} else if (sizeof(long) == 8) {
86945		double correct = 18e18 - ((double) LONG_MIN * -2); /* Subtract ULONG_MAX + 1 */
86946
86947		if ((long) 18e18 == correct) { /* On 64-bit, only check between LONG_MAX and ULONG_MAX */
86948			return 0;
86949		}
86950	}
86951	return 1;
86952}
86953
86954_ACEOF
86955if ac_fn_c_try_run "$LINENO"
86956then :
86957
86958
86959printf "%s\n" "#define ZEND_DVAL_TO_LVAL_CAST_OK 1" >>confdefs.h
86960
86961  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
86962printf "%s\n" "yes" >&6; }
86963
86964else $as_nop
86965
86966  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
86967printf "%s\n" "no" >&6; }
86968
86969fi
86970rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
86971  conftest.$ac_objext conftest.beam conftest.$ac_ext
86972fi
86973
86974
86975
86976ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
86977if test "x$ac_cv_header_dlfcn_h" = xyes
86978then :
86979  printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h
86980
86981fi
86982
86983
86984{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether dlsym() requires a leading underscore in symbol names" >&5
86985printf %s "checking whether dlsym() requires a leading underscore in symbol names... " >&6; }
86986if test "$cross_compiling" = yes; then :
86987
86988else
86989  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
86990  lt_status=$lt_dlunknown
86991  cat > conftest.$ac_ext <<EOF
86992#line 86992 "configure"
86993#include "confdefs.h"
86994
86995#if HAVE_DLFCN_H
86996#include <dlfcn.h>
86997#endif
86998
86999#include <stdio.h>
87000#include <stdlib.h>
87001
87002#ifdef RTLD_GLOBAL
87003#  define LT_DLGLOBAL		RTLD_GLOBAL
87004#else
87005#  ifdef DL_GLOBAL
87006#    define LT_DLGLOBAL		DL_GLOBAL
87007#  else
87008#    define LT_DLGLOBAL		0
87009#  endif
87010#endif
87011
87012/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
87013   find out it does not work in some platform. */
87014#ifndef LT_DLLAZY_OR_NOW
87015#  ifdef RTLD_LAZY
87016#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
87017#  else
87018#    ifdef DL_LAZY
87019#      define LT_DLLAZY_OR_NOW		DL_LAZY
87020#    else
87021#      ifdef RTLD_NOW
87022#        define LT_DLLAZY_OR_NOW	RTLD_NOW
87023#      else
87024#        ifdef DL_NOW
87025#          define LT_DLLAZY_OR_NOW	DL_NOW
87026#        else
87027#          define LT_DLLAZY_OR_NOW	0
87028#        endif
87029#      endif
87030#    endif
87031#  endif
87032#endif
87033
87034void fnord() { int i=42;}
87035int main ()
87036{
87037  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
87038  int status = $lt_dlunknown;
87039
87040  if (self)
87041    {
87042      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
87043      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
87044      /* dlclose (self); */
87045    }
87046  else
87047    puts (dlerror ());
87048
87049    return (status);
87050}
87051EOF
87052  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
87053  (eval $ac_link) 2>&5
87054  ac_status=$?
87055  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
87056  test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
87057    (./conftest; exit; ) >&5 2>/dev/null
87058    lt_status=$?
87059    case x$lt_status in
87060      x$lt_dlno_uscore)
87061  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
87062printf "%s\n" "no" >&6; }
87063 ;;
87064      x$lt_dlneed_uscore)
87065  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
87066printf "%s\n" "yes" >&6; }
87067
87068printf "%s\n" "#define DLSYM_NEEDS_UNDERSCORE 1" >>confdefs.h
87069
87070 ;;
87071      x$lt_dlunknown|x*)
87072  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
87073printf "%s\n" "no" >&6; }
87074 ;;
87075    esac
87076  else :
87077    # compilation failed
87078
87079  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
87080printf "%s\n" "no" >&6; }
87081
87082  fi
87083fi
87084rm -fr conftest*
87085
87086
87087
87088
87089{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable thread-safety" >&5
87090printf %s "checking whether to enable thread-safety... " >&6; }
87091{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ZEND_ZTS" >&5
87092printf "%s\n" "$ZEND_ZTS" >&6; }
87093
87094{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable Zend debugging" >&5
87095printf %s "checking whether to enable Zend debugging... " >&6; }
87096{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ZEND_DEBUG" >&5
87097printf "%s\n" "$ZEND_DEBUG" >&6; }
87098
87099if test "$ZEND_DEBUG" = "yes"; then
87100
87101printf "%s\n" "#define ZEND_DEBUG 1" >>confdefs.h
87102
87103  echo " $CFLAGS" | grep ' -g' >/dev/null || DEBUG_CFLAGS="-g"
87104  if test "$CFLAGS" = "-g -O2"; then
87105  	CFLAGS=-g
87106  fi
87107else
87108
87109printf "%s\n" "#define ZEND_DEBUG 0" >>confdefs.h
87110
87111fi
87112
87113test -n "$GCC" && CFLAGS="-Wall -Wextra -Wno-strict-aliasing -Wno-unused-parameter -Wno-sign-compare $CFLAGS"
87114{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wno-clobbered" >&5
87115printf %s "checking whether C compiler accepts -Wno-clobbered... " >&6; }
87116if test ${ax_cv_check_cflags__Werror__Wno_clobbered+y}
87117then :
87118  printf %s "(cached) " >&6
87119else $as_nop
87120
87121  ax_check_save_flags=$CFLAGS
87122  CFLAGS="$CFLAGS -Werror -Wno-clobbered"
87123  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87124/* end confdefs.h.  */
87125
87126int
87127main (void)
87128{
87129
87130  ;
87131  return 0;
87132}
87133_ACEOF
87134if ac_fn_c_try_compile "$LINENO"
87135then :
87136  ax_cv_check_cflags__Werror__Wno_clobbered=yes
87137else $as_nop
87138  ax_cv_check_cflags__Werror__Wno_clobbered=no
87139fi
87140rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87141  CFLAGS=$ax_check_save_flags
87142fi
87143{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wno_clobbered" >&5
87144printf "%s\n" "$ax_cv_check_cflags__Werror__Wno_clobbered" >&6; }
87145if test "x$ax_cv_check_cflags__Werror__Wno_clobbered" = xyes
87146then :
87147  CFLAGS="-Wno-clobbered $CFLAGS"
87148else $as_nop
87149  :
87150fi
87151
87152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wimplicit-fallthrough=1" >&5
87153printf %s "checking whether C compiler accepts -Wimplicit-fallthrough=1... " >&6; }
87154if test ${ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1+y}
87155then :
87156  printf %s "(cached) " >&6
87157else $as_nop
87158
87159  ax_check_save_flags=$CFLAGS
87160  CFLAGS="$CFLAGS -Werror -Wimplicit-fallthrough=1"
87161  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87162/* end confdefs.h.  */
87163
87164int
87165main (void)
87166{
87167
87168  ;
87169  return 0;
87170}
87171_ACEOF
87172if ac_fn_c_try_compile "$LINENO"
87173then :
87174  ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1=yes
87175else $as_nop
87176  ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1=no
87177fi
87178rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87179  CFLAGS=$ax_check_save_flags
87180fi
87181{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1" >&5
87182printf "%s\n" "$ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1" >&6; }
87183if test "x$ax_cv_check_cflags__Werror__Wimplicit_fallthrough_1" = xyes
87184then :
87185  CFLAGS="$CFLAGS -Wimplicit-fallthrough=1"
87186else $as_nop
87187  :
87188fi
87189
87190{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wduplicated-cond" >&5
87191printf %s "checking whether C compiler accepts -Wduplicated-cond... " >&6; }
87192if test ${ax_cv_check_cflags__Werror__Wduplicated_cond+y}
87193then :
87194  printf %s "(cached) " >&6
87195else $as_nop
87196
87197  ax_check_save_flags=$CFLAGS
87198  CFLAGS="$CFLAGS -Werror -Wduplicated-cond"
87199  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87200/* end confdefs.h.  */
87201
87202int
87203main (void)
87204{
87205
87206  ;
87207  return 0;
87208}
87209_ACEOF
87210if ac_fn_c_try_compile "$LINENO"
87211then :
87212  ax_cv_check_cflags__Werror__Wduplicated_cond=yes
87213else $as_nop
87214  ax_cv_check_cflags__Werror__Wduplicated_cond=no
87215fi
87216rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87217  CFLAGS=$ax_check_save_flags
87218fi
87219{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wduplicated_cond" >&5
87220printf "%s\n" "$ax_cv_check_cflags__Werror__Wduplicated_cond" >&6; }
87221if test "x$ax_cv_check_cflags__Werror__Wduplicated_cond" = xyes
87222then :
87223  CFLAGS="-Wduplicated-cond $CFLAGS"
87224else $as_nop
87225  :
87226fi
87227
87228{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wlogical-op" >&5
87229printf %s "checking whether C compiler accepts -Wlogical-op... " >&6; }
87230if test ${ax_cv_check_cflags__Werror__Wlogical_op+y}
87231then :
87232  printf %s "(cached) " >&6
87233else $as_nop
87234
87235  ax_check_save_flags=$CFLAGS
87236  CFLAGS="$CFLAGS -Werror -Wlogical-op"
87237  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87238/* end confdefs.h.  */
87239
87240int
87241main (void)
87242{
87243
87244  ;
87245  return 0;
87246}
87247_ACEOF
87248if ac_fn_c_try_compile "$LINENO"
87249then :
87250  ax_cv_check_cflags__Werror__Wlogical_op=yes
87251else $as_nop
87252  ax_cv_check_cflags__Werror__Wlogical_op=no
87253fi
87254rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87255  CFLAGS=$ax_check_save_flags
87256fi
87257{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wlogical_op" >&5
87258printf "%s\n" "$ax_cv_check_cflags__Werror__Wlogical_op" >&6; }
87259if test "x$ax_cv_check_cflags__Werror__Wlogical_op" = xyes
87260then :
87261  CFLAGS="-Wlogical-op $CFLAGS"
87262else $as_nop
87263  :
87264fi
87265
87266{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wformat-truncation" >&5
87267printf %s "checking whether C compiler accepts -Wformat-truncation... " >&6; }
87268if test ${ax_cv_check_cflags__Werror__Wformat_truncation+y}
87269then :
87270  printf %s "(cached) " >&6
87271else $as_nop
87272
87273  ax_check_save_flags=$CFLAGS
87274  CFLAGS="$CFLAGS -Werror -Wformat-truncation"
87275  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87276/* end confdefs.h.  */
87277
87278int
87279main (void)
87280{
87281
87282  ;
87283  return 0;
87284}
87285_ACEOF
87286if ac_fn_c_try_compile "$LINENO"
87287then :
87288  ax_cv_check_cflags__Werror__Wformat_truncation=yes
87289else $as_nop
87290  ax_cv_check_cflags__Werror__Wformat_truncation=no
87291fi
87292rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87293  CFLAGS=$ax_check_save_flags
87294fi
87295{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wformat_truncation" >&5
87296printf "%s\n" "$ax_cv_check_cflags__Werror__Wformat_truncation" >&6; }
87297if test "x$ax_cv_check_cflags__Werror__Wformat_truncation" = xyes
87298then :
87299  CFLAGS="-Wformat-truncation $CFLAGS"
87300else $as_nop
87301  :
87302fi
87303
87304{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Wstrict-prototypes" >&5
87305printf %s "checking whether C compiler accepts -Wstrict-prototypes... " >&6; }
87306if test ${ax_cv_check_cflags__Werror__Wstrict_prototypes+y}
87307then :
87308  printf %s "(cached) " >&6
87309else $as_nop
87310
87311  ax_check_save_flags=$CFLAGS
87312  CFLAGS="$CFLAGS -Werror -Wstrict-prototypes"
87313  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87314/* end confdefs.h.  */
87315
87316int
87317main (void)
87318{
87319
87320  ;
87321  return 0;
87322}
87323_ACEOF
87324if ac_fn_c_try_compile "$LINENO"
87325then :
87326  ax_cv_check_cflags__Werror__Wstrict_prototypes=yes
87327else $as_nop
87328  ax_cv_check_cflags__Werror__Wstrict_prototypes=no
87329fi
87330rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87331  CFLAGS=$ax_check_save_flags
87332fi
87333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__Wstrict_prototypes" >&5
87334printf "%s\n" "$ax_cv_check_cflags__Werror__Wstrict_prototypes" >&6; }
87335if test "x$ax_cv_check_cflags__Werror__Wstrict_prototypes" = xyes
87336then :
87337  CFLAGS="-Wstrict-prototypes $CFLAGS"
87338else $as_nop
87339  :
87340fi
87341
87342{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-common" >&5
87343printf %s "checking whether C compiler accepts -fno-common... " >&6; }
87344if test ${ax_cv_check_cflags__Werror__fno_common+y}
87345then :
87346  printf %s "(cached) " >&6
87347else $as_nop
87348
87349  ax_check_save_flags=$CFLAGS
87350  CFLAGS="$CFLAGS -Werror -fno-common"
87351  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87352/* end confdefs.h.  */
87353
87354int
87355main (void)
87356{
87357
87358  ;
87359  return 0;
87360}
87361_ACEOF
87362if ac_fn_c_try_compile "$LINENO"
87363then :
87364  ax_cv_check_cflags__Werror__fno_common=yes
87365else $as_nop
87366  ax_cv_check_cflags__Werror__fno_common=no
87367fi
87368rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87369  CFLAGS=$ax_check_save_flags
87370fi
87371{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags__Werror__fno_common" >&5
87372printf "%s\n" "$ax_cv_check_cflags__Werror__fno_common" >&6; }
87373if test "x$ax_cv_check_cflags__Werror__fno_common" = xyes
87374then :
87375  CFLAGS="-fno-common $CFLAGS"
87376else $as_nop
87377  :
87378fi
87379
87380
87381test -n "$DEBUG_CFLAGS" && CFLAGS="$CFLAGS $DEBUG_CFLAGS"
87382
87383if test "$ZEND_ZTS" = "yes"; then
87384
87385printf "%s\n" "#define ZTS 1" >>confdefs.h
87386
87387  CFLAGS="$CFLAGS -DZTS"
87388fi
87389
87390{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
87391printf %s "checking for inline... " >&6; }
87392if test ${ac_cv_c_inline+y}
87393then :
87394  printf %s "(cached) " >&6
87395else $as_nop
87396  ac_cv_c_inline=no
87397for ac_kw in inline __inline__ __inline; do
87398  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87399/* end confdefs.h.  */
87400#ifndef __cplusplus
87401typedef int foo_t;
87402static $ac_kw foo_t static_foo (void) {return 0; }
87403$ac_kw foo_t foo (void) {return 0; }
87404#endif
87405
87406_ACEOF
87407if ac_fn_c_try_compile "$LINENO"
87408then :
87409  ac_cv_c_inline=$ac_kw
87410fi
87411rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
87412  test "$ac_cv_c_inline" != no && break
87413done
87414
87415fi
87416{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
87417printf "%s\n" "$ac_cv_c_inline" >&6; }
87418
87419case $ac_cv_c_inline in
87420  inline | yes) ;;
87421  *)
87422    case $ac_cv_c_inline in
87423      no) ac_val=;;
87424      *) ac_val=$ac_cv_c_inline;;
87425    esac
87426    cat >>confdefs.h <<_ACEOF
87427#ifndef __cplusplus
87428#define inline $ac_val
87429#endif
87430_ACEOF
87431    ;;
87432esac
87433
87434
87435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking target system is Darwin" >&5
87436printf %s "checking target system is Darwin... " >&6; }
87437if echo "$target" | grep "darwin" > /dev/null; then
87438
87439printf "%s\n" "#define DARWIN 1" >>confdefs.h
87440
87441  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
87442printf "%s\n" "yes" >&6; }
87443else
87444  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
87445printf "%s\n" "no" >&6; }
87446fi
87447
87448{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MM alignment and log values" >&5
87449printf %s "checking for MM alignment and log values... " >&6; }
87450
87451if test "$cross_compiling" = yes
87452then :
87453
87454
87455printf "%s\n" "#define ZEND_MM_ALIGNMENT 8" >>confdefs.h
87456
87457
87458printf "%s\n" "#define ZEND_MM_ALIGNMENT_LOG2 3" >>confdefs.h
87459
87460
87461else $as_nop
87462  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87463/* end confdefs.h.  */
87464
87465#include <stdio.h>
87466#include <stdlib.h>
87467
87468typedef union _mm_align_test {
87469  void *ptr;
87470  double dbl;
87471  long lng;
87472} mm_align_test;
87473
87474#if (defined (__GNUC__) && __GNUC__ >= 2)
87475#define ZEND_MM_ALIGNMENT (__alignof__ (mm_align_test))
87476#else
87477#define ZEND_MM_ALIGNMENT (sizeof(mm_align_test))
87478#endif
87479
87480int main()
87481{
87482  int i = ZEND_MM_ALIGNMENT;
87483  int zeros = 0;
87484  FILE *fp;
87485
87486  while (i & ~0x1) {
87487    zeros++;
87488    i = i >> 1;
87489  }
87490
87491  fp = fopen("conftest.zend", "w");
87492  fprintf(fp, "%d %d\n", ZEND_MM_ALIGNMENT, zeros);
87493  fclose(fp);
87494
87495  return 0;
87496}
87497
87498_ACEOF
87499if ac_fn_c_try_run "$LINENO"
87500then :
87501
87502  LIBZEND_MM_ALIGN=`cat conftest.zend | cut -d ' ' -f 1`
87503  LIBZEND_MM_ALIGN_LOG2=`cat conftest.zend | cut -d ' ' -f 2`
87504
87505printf "%s\n" "#define ZEND_MM_ALIGNMENT $LIBZEND_MM_ALIGN" >>confdefs.h
87506
87507
87508printf "%s\n" "#define ZEND_MM_ALIGNMENT_LOG2 $LIBZEND_MM_ALIGN_LOG2" >>confdefs.h
87509
87510
87511fi
87512rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
87513  conftest.$ac_objext conftest.beam conftest.$ac_ext
87514fi
87515
87516
87517{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5
87518printf "%s\n" "done" >&6; }
87519
87520ac_fn_c_check_func "$LINENO" "mremap" "ac_cv_func_mremap"
87521if test "x$ac_cv_func_mremap" = xyes
87522then :
87523  printf "%s\n" "#define HAVE_MREMAP 1" >>confdefs.h
87524
87525fi
87526
87527
87528# Check whether --enable-zend-signals was given.
87529if test ${enable_zend_signals+y}
87530then :
87531  enableval=$enable_zend_signals; ZEND_SIGNALS=$enableval
87532else $as_nop
87533  ZEND_SIGNALS=yes
87534fi
87535
87536
87537
87538  for ac_func in sigaction
87539do :
87540  ac_fn_c_check_func "$LINENO" "sigaction" "ac_cv_func_sigaction"
87541if test "x$ac_cv_func_sigaction" = xyes
87542then :
87543  printf "%s\n" "#define HAVE_SIGACTION 1" >>confdefs.h
87544
87545else $as_nop
87546
87547  ZEND_SIGNALS=no
87548
87549fi
87550
87551done
87552if test "$ZEND_SIGNALS" = "yes"; then
87553
87554printf "%s\n" "#define ZEND_SIGNALS 1" >>confdefs.h
87555
87556	CFLAGS="$CFLAGS -DZEND_SIGNALS"
87557fi
87558
87559{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable zend signal handling" >&5
87560printf %s "checking whether to enable zend signal handling... " >&6; }
87561{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ZEND_SIGNALS" >&5
87562printf "%s\n" "$ZEND_SIGNALS" >&6; }
87563
87564
87565
87566INCLUDES="$INCLUDES -I\$(top_builddir)/TSRM"
87567INCLUDES="$INCLUDES -I\$(top_builddir)/Zend"
87568
87569if test "$abs_srcdir" != "$abs_builddir"; then
87570  INCLUDES="$INCLUDES -I\$(top_srcdir)/main -I\$(top_srcdir)/Zend"
87571  INCLUDES="$INCLUDES -I\$(top_srcdir)/TSRM -I\$(top_builddir)/"
87572fi
87573
87574ZEND_EXTRA_LIBS="$LIBS"
87575unset LIBS LDFLAGS
87576
87577
87578# Check whether --enable- was given.
87579if test ${enable_+y}
87580then :
87581  enableval=$enable_;
87582fi
87583
87584
87585
87586  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
87587printf "%s\n" "" >&6; }
87588  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring TSRM${T_ME}" >&5
87589printf "%s\n" "${T_MD}Configuring TSRM${T_ME}" >&6; }
87590
87591if test "$PHP_THREAD_SAFETY" = "yes"; then
87592
87593
87594{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthreads_cflags" >&5
87595printf %s "checking for pthreads_cflags... " >&6; }
87596if test ${ac_cv_pthreads_cflags+y}
87597then :
87598  printf %s "(cached) " >&6
87599else $as_nop
87600
87601ac_cv_pthreads_cflags=
87602if test "$pthreads_working" != "yes"; then
87603  for flag in -kthread -pthread -pthreads -mthreads -Kthread -threads -mt -qthreaded; do
87604    ac_save=$CFLAGS
87605    CFLAGS="$CFLAGS $flag"
87606
87607cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87608/* end confdefs.h.  */
87609
87610#include <pthread.h>
87611#include <stddef.h>
87612
87613void *thread_routine(void *data) {
87614    return data;
87615}
87616
87617int main() {
87618    pthread_t thd;
87619    pthread_mutexattr_t mattr;
87620    int data = 1;
87621    pthread_mutexattr_init(&mattr);
87622    return pthread_create(&thd, NULL, thread_routine, &data);
87623}
87624_ACEOF
87625if ac_fn_c_try_link "$LINENO"
87626then :
87627
87628  pthreads_checked=yes
87629
87630else $as_nop
87631
87632  pthreads_checked=no
87633
87634
87635fi
87636rm -f core conftest.err conftest.$ac_objext conftest.beam \
87637    conftest$ac_exeext conftest.$ac_ext
87638    CFLAGS=$ac_save
87639    if test "$pthreads_checked" = "yes"; then
87640      ac_cv_pthreads_cflags=$flag
87641      break
87642    fi
87643  done
87644fi
87645
87646fi
87647{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthreads_cflags" >&5
87648printf "%s\n" "$ac_cv_pthreads_cflags" >&6; }
87649
87650{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthreads_lib" >&5
87651printf %s "checking for pthreads_lib... " >&6; }
87652if test ${ac_cv_pthreads_lib+y}
87653then :
87654  printf %s "(cached) " >&6
87655else $as_nop
87656
87657ac_cv_pthreads_lib=
87658if test "$pthreads_working" != "yes"; then
87659 for lib in pthread pthreads c_r; do
87660    ac_save=$LIBS
87661    LIBS="$LIBS -l$lib"
87662
87663cat confdefs.h - <<_ACEOF >conftest.$ac_ext
87664/* end confdefs.h.  */
87665
87666#include <pthread.h>
87667#include <stddef.h>
87668
87669void *thread_routine(void *data) {
87670    return data;
87671}
87672
87673int main() {
87674    pthread_t thd;
87675    pthread_mutexattr_t mattr;
87676    int data = 1;
87677    pthread_mutexattr_init(&mattr);
87678    return pthread_create(&thd, NULL, thread_routine, &data);
87679}
87680_ACEOF
87681if ac_fn_c_try_link "$LINENO"
87682then :
87683
87684  pthreads_checked=yes
87685
87686else $as_nop
87687
87688  pthreads_checked=no
87689
87690
87691fi
87692rm -f core conftest.err conftest.$ac_objext conftest.beam \
87693    conftest$ac_exeext conftest.$ac_ext
87694    LIBS=$ac_save
87695    if test "$pthreads_checked" = "yes"; then
87696      ac_cv_pthreads_lib=$lib
87697      break
87698    fi
87699  done
87700fi
87701
87702fi
87703{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_pthreads_lib" >&5
87704printf "%s\n" "$ac_cv_pthreads_lib" >&6; }
87705
87706if test "x$ac_cv_pthreads_cflags" != "x" -o "x$ac_cv_pthreads_lib" != "x"; then
87707  pthreads_working="yes"
87708fi
87709
87710
87711if test "$pthreads_working" != "yes"; then
87712  as_fn_error $? "Your system seems to lack POSIX threads." "$LINENO" 5
87713fi
87714
87715
87716printf "%s\n" "#define PTHREADS 1" >>confdefs.h
87717
87718
87719{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for POSIX threads" >&5
87720printf %s "checking for POSIX threads... " >&6; }
87721{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
87722printf "%s\n" "yes" >&6; }
87723
87724fi
87725
87726EXTRA_LDFLAGS="$EXTRA_LDFLAGS $LDFLAGS"
87727EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $LDFLAGS"
87728EXTRA_LIBS="$EXTRA_LIBS $LIBS"
87729unset LIBS LDFLAGS
87730
87731test "$program_prefix" != NONE &&
87732  program_transform_name="s&^&$program_prefix&;$program_transform_name"
87733# Use a double $ so make ignores it.
87734test "$program_suffix" != NONE &&
87735  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
87736# Double any \ or $.
87737# By default was `s,x,x', remove it if useless.
87738ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
87739program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"`
87740
87741
87742test "$prefix" = "NONE" && prefix=/usr/local
87743test "$exec_prefix" = "NONE" && exec_prefix='${prefix}'
87744test "$program_prefix" = "NONE" && program_prefix=
87745test "$program_suffix" = "NONE" && program_suffix=
87746
87747case $libdir in
87748  '${exec_prefix}/lib')
87749    libdir=$libdir/php
87750    ;;
87751esac
87752case `eval echo $datadir` in
87753  '${prefix}/share')
87754    datadir=$datadir/php
87755    ;;
87756esac
87757
87758phplibdir=`pwd`/modules
87759$php_shtool mkdir -p $phplibdir
87760phptempdir=`pwd`/libs
87761
87762old_exec_prefix=$exec_prefix
87763old_libdir=$libdir
87764old_datadir=$datadir
87765exec_prefix=`eval echo $exec_prefix`
87766libdir=`eval echo $libdir`
87767datadir=`eval eval echo $datadir`
87768
87769ZEND_MODULE_API_NO=`$EGREP '#define ZEND_MODULE_API_NO ' $srcdir/Zend/zend_modules.h|"${SED}" 's/#define ZEND_MODULE_API_NO //'`
87770
87771if test -z "$EXTENSION_DIR"; then
87772  extbasedir=$ZEND_MODULE_API_NO
87773  if test "$oldstyleextdir" = "yes"; then
87774    if test "$PHP_DEBUG" = "1"; then
87775      part1=debug
87776    else
87777      part1=no-debug
87778    fi
87779    if test "$enable_zts" = "yes"; then
87780      part2=zts
87781    else
87782      part2=non-zts
87783    fi
87784    extbasedir=$part1-$part2-$extbasedir
87785    EXTENSION_DIR=$libdir/extensions/$extbasedir
87786  else
87787    if test "$enable_zts" = "yes"; then
87788      extbasedir=$extbasedir-zts
87789    fi
87790
87791    if test "$PHP_DEBUG" = "1"; then
87792      extbasedir=$extbasedir-debug
87793    fi
87794    EXTENSION_DIR=$libdir/$extbasedir
87795  fi
87796fi
87797
87798case $PHP_LAYOUT in
87799  GNU)
87800    datarootdir=$prefix/share
87801    ;;
87802  *)
87803    datarootdir=$prefix/php
87804    ;;
87805esac
87806
87807EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR`
87808EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR`
87809EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir`
87810EXPANDED_BINDIR=`eval echo $bindir`
87811EXPANDED_SBINDIR=`eval echo $sbindir`
87812EXPANDED_MANDIR=`eval echo $mandir`
87813EXPANDED_LIBDIR=$libdir
87814EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
87815EXPANDED_DATADIR=$datadir
87816EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
87817EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
87818INCLUDE_PATH=.:$EXPANDED_PEAR_INSTALLDIR
87819
87820exec_prefix=$old_exec_prefix
87821libdir=$old_libdir
87822datadir=$old_datadir
87823
87824
87825
87826
87827
87828
87829
87830
87831
87832
87833
87834
87835
87836
87837
87838  OLD_RPATHS=$PHP_RPATHS
87839  unset PHP_RPATHS
87840
87841  for i in $OLD_RPATHS; do
87842        PHP_LDFLAGS="$PHP_LDFLAGS -L$i"
87843        PHP_RPATHS="$PHP_RPATHS -R $i"
87844        NATIVE_RPATHS="$NATIVE_RPATHS $ld_runpath_switch$i"
87845  done
87846
87847  if test "$PHP_RPATH" = "no"; then
87848    unset PHP_RPATHS
87849    unset NATIVE_RPATHS
87850  fi
87851
87852
87853
87854  unset ac_new_flags
87855  for i in $PHP_LDFLAGS; do
87856    case $i in
87857    -L/usr/$PHP_LIBDIR|-L/usr/$PHP_LIBDIR/) ;;
87858    *) ac_new_flags="$ac_new_flags $i" ;;
87859    esac
87860  done
87861  PHP_LDFLAGS=$ac_new_flags
87862
87863
87864  unset ac_new_flags
87865  for i in $LDFLAGS; do
87866    case $i in
87867    -L/usr/$PHP_LIBDIR|-L/usr/$PHP_LIBDIR/) ;;
87868    *) ac_new_flags="$ac_new_flags $i" ;;
87869    esac
87870  done
87871  LDFLAGS=$ac_new_flags
87872
87873
87874EXTRA_LDFLAGS="$EXTRA_LDFLAGS $PHP_LDFLAGS"
87875EXTRA_LDFLAGS_PROGRAM="$EXTRA_LDFLAGS_PROGRAM $PHP_LDFLAGS"
87876
87877UNAME=`uname -a | xargs`
87878PHP_UNAME=${PHP_UNAME:-$UNAME}
87879
87880printf "%s\n" "#define PHP_UNAME \"$PHP_UNAME\"" >>confdefs.h
87881
87882PHP_OS=`uname | xargs`
87883
87884printf "%s\n" "#define PHP_OS \"$PHP_OS\"" >>confdefs.h
87885
87886PHP_BUILD_SYSTEM=${PHP_BUILD_SYSTEM:-$PHP_UNAME}
87887
87888printf "%s\n" "#define PHP_BUILD_SYSTEM \"$PHP_BUILD_SYSTEM\"" >>confdefs.h
87889
87890if test -n "${PHP_BUILD_PROVIDER}"; then
87891
87892printf "%s\n" "#define PHP_BUILD_PROVIDER \"$PHP_BUILD_PROVIDER\"" >>confdefs.h
87893
87894fi
87895if test -n "${PHP_BUILD_COMPILER}"; then
87896
87897printf "%s\n" "#define PHP_BUILD_COMPILER \"$PHP_BUILD_COMPILER\"" >>confdefs.h
87898
87899fi
87900if test -n "${PHP_BUILD_ARCH}"; then
87901
87902printf "%s\n" "#define PHP_BUILD_ARCH \"$PHP_BUILD_ARCH\"" >>confdefs.h
87903
87904fi
87905
87906
87907
87908
87909  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_INSTALLED_SAPIS"
87910
87911
87912
87913
87914  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FASTCGI_OBJS"
87915
87916
87917  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_SAPI_OBJS"
87918
87919
87920  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_BINARY_OBJS"
87921
87922
87923  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_GLOBAL_OBJS"
87924
87925
87926
87927  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_BINARIES"
87928
87929
87930  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_MODULES"
87931
87932
87933  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_ZEND_EX"
87934
87935
87936
87937  PHP_VAR_SUBST="$PHP_VAR_SUBST EXT_LIBS"
87938
87939
87940
87941
87942
87943  PHP_VAR_SUBST="$PHP_VAR_SUBST abs_builddir"
87944
87945
87946
87947
87948
87949  PHP_VAR_SUBST="$PHP_VAR_SUBST abs_srcdir"
87950
87951
87952
87953
87954  PHP_VAR_SUBST="$PHP_VAR_SUBST bindir"
87955
87956
87957  PHP_VAR_SUBST="$PHP_VAR_SUBST sbindir"
87958
87959
87960  PHP_VAR_SUBST="$PHP_VAR_SUBST exec_prefix"
87961
87962
87963
87964
87965  PHP_VAR_SUBST="$PHP_VAR_SUBST program_prefix"
87966
87967
87968
87969
87970
87971  PHP_VAR_SUBST="$PHP_VAR_SUBST program_suffix"
87972
87973
87974
87975  PHP_VAR_SUBST="$PHP_VAR_SUBST includedir"
87976
87977
87978  PHP_VAR_SUBST="$PHP_VAR_SUBST libdir"
87979
87980
87981  PHP_VAR_SUBST="$PHP_VAR_SUBST mandir"
87982
87983
87984  PHP_VAR_SUBST="$PHP_VAR_SUBST phplibdir"
87985
87986
87987  PHP_VAR_SUBST="$PHP_VAR_SUBST phptempdir"
87988
87989
87990  PHP_VAR_SUBST="$PHP_VAR_SUBST prefix"
87991
87992
87993  PHP_VAR_SUBST="$PHP_VAR_SUBST localstatedir"
87994
87995
87996  PHP_VAR_SUBST="$PHP_VAR_SUBST datadir"
87997
87998
87999  PHP_VAR_SUBST="$PHP_VAR_SUBST datarootdir"
88000
88001
88002  PHP_VAR_SUBST="$PHP_VAR_SUBST sysconfdir"
88003
88004
88005
88006  PHP_VAR_SUBST="$PHP_VAR_SUBST EXEEXT"
88007
88008
88009  PHP_VAR_SUBST="$PHP_VAR_SUBST CC"
88010
88011
88012  PHP_VAR_SUBST="$PHP_VAR_SUBST BUILD_CC"
88013
88014
88015  PHP_VAR_SUBST="$PHP_VAR_SUBST CFLAGS"
88016
88017
88018  PHP_VAR_SUBST="$PHP_VAR_SUBST CFLAGS_CLEAN"
88019
88020
88021  PHP_VAR_SUBST="$PHP_VAR_SUBST CPP"
88022
88023
88024  PHP_VAR_SUBST="$PHP_VAR_SUBST CPPFLAGS"
88025
88026
88027  PHP_VAR_SUBST="$PHP_VAR_SUBST CXX"
88028
88029
88030  PHP_VAR_SUBST="$PHP_VAR_SUBST CXXFLAGS"
88031
88032
88033  PHP_VAR_SUBST="$PHP_VAR_SUBST CXXFLAGS_CLEAN"
88034
88035
88036
88037
88038  PHP_VAR_SUBST="$PHP_VAR_SUBST DEBUG_CFLAGS"
88039
88040
88041
88042
88043
88044  PHP_VAR_SUBST="$PHP_VAR_SUBST EXTENSION_DIR"
88045
88046
88047
88048
88049
88050  PHP_VAR_SUBST="$PHP_VAR_SUBST EXTRA_LDFLAGS"
88051
88052
88053
88054
88055
88056  PHP_VAR_SUBST="$PHP_VAR_SUBST EXTRA_LDFLAGS_PROGRAM"
88057
88058
88059
88060
88061
88062  PHP_VAR_SUBST="$PHP_VAR_SUBST EXTRA_LIBS"
88063
88064
88065
88066
88067
88068  PHP_VAR_SUBST="$PHP_VAR_SUBST ZEND_EXTRA_LIBS"
88069
88070
88071
88072
88073
88074  PHP_VAR_SUBST="$PHP_VAR_SUBST INCLUDES"
88075
88076
88077
88078
88079
88080  PHP_VAR_SUBST="$PHP_VAR_SUBST EXTRA_INCLUDES"
88081
88082
88083
88084
88085
88086  PHP_VAR_SUBST="$PHP_VAR_SUBST INCLUDE_PATH"
88087
88088
88089
88090
88091
88092  PHP_VAR_SUBST="$PHP_VAR_SUBST INSTALL_IT"
88093
88094
88095
88096  PHP_VAR_SUBST="$PHP_VAR_SUBST LFLAGS"
88097
88098
88099  PHP_VAR_SUBST="$PHP_VAR_SUBST LIBTOOL"
88100
88101
88102  PHP_VAR_SUBST="$PHP_VAR_SUBST LN_S"
88103
88104
88105
88106
88107  PHP_VAR_SUBST="$PHP_VAR_SUBST NATIVE_RPATHS"
88108
88109
88110
88111
88112
88113  PHP_VAR_SUBST="$PHP_VAR_SUBST PEAR_INSTALLDIR"
88114
88115
88116
88117
88118
88119  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_LDFLAGS"
88120
88121
88122
88123
88124
88125  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_LIBS"
88126
88127
88128
88129  PHP_VAR_SUBST="$PHP_VAR_SUBST OVERALL_TARGET"
88130
88131
88132  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_RPATHS"
88133
88134
88135  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_SAPI"
88136
88137
88138
88139
88140  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_VERSION"
88141
88142
88143
88144
88145
88146  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_VERSION_ID"
88147
88148
88149
88150  PHP_VAR_SUBST="$PHP_VAR_SUBST SHELL"
88151
88152
88153  PHP_VAR_SUBST="$PHP_VAR_SUBST SHARED_LIBTOOL"
88154
88155
88156  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FRAMEWORKS"
88157
88158
88159  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_FRAMEWORKPATH"
88160
88161
88162  PHP_VAR_SUBST="$PHP_VAR_SUBST INSTALL_HEADERS"
88163
88164
88165old_CC=$CC
88166
88167if test "$PHP_THREAD_SAFETY" = "yes" && test -n "$ac_cv_pthreads_cflags"; then
88168  CXXFLAGS="$CXXFLAGS $ac_cv_pthreads_cflags"
88169  CPPFLAGS="$CPPFLAGS $ac_cv_pthreads_cflags"
88170fi
88171
88172if test "$PHP_WERROR" = "yes"; then
88173  CFLAGS="$CFLAGS -Werror"
88174  CXXFLAGS="$CXXFLAGS -Werror"
88175fi
88176
88177if test "$PHP_MEMORY_SANITIZER" = "yes" &&
88178   test "$PHP_ADDRESS_SANITIZER" = "yes"; then
88179   as_fn_error $? "MemorySanitizer and AddressSanitizer are mutually exclusive" "$LINENO" 5
88180fi
88181
88182if test "$PHP_MEMORY_SANITIZER" = "yes"; then
88183  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fsanitize=memory -fsanitize-memory-track-origins" >&5
88184printf %s "checking whether C compiler accepts -fsanitize=memory -fsanitize-memory-track-origins... " >&6; }
88185if test ${ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins+y}
88186then :
88187  printf %s "(cached) " >&6
88188else $as_nop
88189
88190  ax_check_save_flags=$CFLAGS
88191  CFLAGS="$CFLAGS  -fsanitize=memory -fsanitize-memory-track-origins"
88192  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
88193/* end confdefs.h.  */
88194
88195int
88196main (void)
88197{
88198
88199  ;
88200  return 0;
88201}
88202_ACEOF
88203if ac_fn_c_try_compile "$LINENO"
88204then :
88205  ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins=yes
88206else $as_nop
88207  ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins=no
88208fi
88209rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
88210  CFLAGS=$ax_check_save_flags
88211fi
88212{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins" >&5
88213printf "%s\n" "$ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins" >&6; }
88214if test "x$ax_cv_check_cflags___fsanitize_memory__fsanitize_memory_track_origins" = xyes
88215then :
88216
88217    CFLAGS="$CFLAGS -fsanitize=memory -fsanitize-memory-track-origins"
88218    CXXFLAGS="$CXXFLAGS -fsanitize=memory -fsanitize-memory-track-origins"
88219
88220else $as_nop
88221  as_fn_error $? "MemorySanitizer is not available" "$LINENO" 5
88222fi
88223
88224fi
88225
88226if test "$PHP_ADDRESS_SANITIZER" = "yes"; then
88227  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fsanitize=address" >&5
88228printf %s "checking whether C compiler accepts -fsanitize=address... " >&6; }
88229if test ${ax_cv_check_cflags___fsanitize_address+y}
88230then :
88231  printf %s "(cached) " >&6
88232else $as_nop
88233
88234  ax_check_save_flags=$CFLAGS
88235  CFLAGS="$CFLAGS  -fsanitize=address"
88236  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
88237/* end confdefs.h.  */
88238
88239int
88240main (void)
88241{
88242
88243  ;
88244  return 0;
88245}
88246_ACEOF
88247if ac_fn_c_try_compile "$LINENO"
88248then :
88249  ax_cv_check_cflags___fsanitize_address=yes
88250else $as_nop
88251  ax_cv_check_cflags___fsanitize_address=no
88252fi
88253rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
88254  CFLAGS=$ax_check_save_flags
88255fi
88256{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fsanitize_address" >&5
88257printf "%s\n" "$ax_cv_check_cflags___fsanitize_address" >&6; }
88258if test "x$ax_cv_check_cflags___fsanitize_address" = xyes
88259then :
88260
88261    CFLAGS="$CFLAGS -fsanitize=address -DZEND_TRACK_ARENA_ALLOC"
88262    CXXFLAGS="$CXXFLAGS -fsanitize=address -DZEND_TRACK_ARENA_ALLOC"
88263
88264else $as_nop
88265  as_fn_error $? "AddressSanitizer is not available" "$LINENO" 5
88266fi
88267
88268fi
88269
88270if test "$PHP_UNDEFINED_SANITIZER" = "yes"; then
88271  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fsanitize=undefined" >&5
88272printf %s "checking whether C compiler accepts -fsanitize=undefined... " >&6; }
88273if test ${ax_cv_check_cflags___fsanitize_undefined+y}
88274then :
88275  printf %s "(cached) " >&6
88276else $as_nop
88277
88278  ax_check_save_flags=$CFLAGS
88279  CFLAGS="$CFLAGS  -fsanitize=undefined"
88280  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
88281/* end confdefs.h.  */
88282
88283int
88284main (void)
88285{
88286
88287  ;
88288  return 0;
88289}
88290_ACEOF
88291if ac_fn_c_try_compile "$LINENO"
88292then :
88293  ax_cv_check_cflags___fsanitize_undefined=yes
88294else $as_nop
88295  ax_cv_check_cflags___fsanitize_undefined=no
88296fi
88297rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
88298  CFLAGS=$ax_check_save_flags
88299fi
88300{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fsanitize_undefined" >&5
88301printf "%s\n" "$ax_cv_check_cflags___fsanitize_undefined" >&6; }
88302if test "x$ax_cv_check_cflags___fsanitize_undefined" = xyes
88303then :
88304
88305    CFLAGS="$CFLAGS -fsanitize=undefined"
88306    CXXFLAGS="$CXXFLAGS -fsanitize=undefined"
88307
88308else $as_nop
88309  as_fn_error $? "UndefinedBehaviorSanitizer is not available" "$LINENO" 5
88310fi
88311
88312fi
88313
88314if test "$PHP_MEMORY_SANITIZER" = "yes" ||
88315   test "$PHP_ADDRESS_SANITIZER" = "yes" ||
88316   test "$PHP_UNDEFINED_SANITIZER" = "yes"; then
88317    CFLAGS="$CFLAGS -fno-omit-frame-pointer"
88318    CXXFLAGS="$CXXFLAGS -fno-omit-frame-pointer"
88319fi
88320
88321
88322
88323# Check whether --enable- was given.
88324if test ${enable_+y}
88325then :
88326  enableval=$enable_;
88327fi
88328
88329
88330
88331  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
88332printf "%s\n" "" >&6; }
88333  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Configuring libtool${T_ME}" >&5
88334printf "%s\n" "${T_MD}Configuring libtool${T_ME}" >&6; }
88335
88336
88337AR_FLAGS=cr
88338
88339
88340
88341# Check whether --enable-shared was given.
88342if test ${enable_shared+y}
88343then :
88344  enableval=$enable_shared;     p=${PACKAGE-default}
88345    case $enableval in
88346    yes) enable_shared=yes ;;
88347    no) enable_shared=no ;;
88348    *)
88349      enable_shared=no
88350      # Look at the argument we got.  We use all the common list separators.
88351      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
88352      for pkg in $enableval; do
88353	IFS="$lt_save_ifs"
88354	if test "X$pkg" = "X$p"; then
88355	  enable_shared=yes
88356	fi
88357      done
88358      IFS="$lt_save_ifs"
88359      ;;
88360    esac
88361else $as_nop
88362  enable_shared=yes
88363fi
88364
88365
88366# Check whether --enable-static was given.
88367if test ${enable_static+y}
88368then :
88369  enableval=$enable_static;     p=${PACKAGE-default}
88370    case $enableval in
88371    yes) enable_static=yes ;;
88372    no) enable_static=no ;;
88373    *)
88374     enable_static=no
88375      # Look at the argument we got.  We use all the common list separators.
88376      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
88377      for pkg in $enableval; do
88378	IFS="$lt_save_ifs"
88379	if test "X$pkg" = "X$p"; then
88380	  enable_static=yes
88381	fi
88382      done
88383      IFS="$lt_save_ifs"
88384      ;;
88385    esac
88386else $as_nop
88387  enable_static=yes
88388fi
88389
88390
88391# Check whether --enable-fast-install was given.
88392if test ${enable_fast_install+y}
88393then :
88394  enableval=$enable_fast_install;     p=${PACKAGE-default}
88395    case $enableval in
88396    yes) enable_fast_install=yes ;;
88397    no) enable_fast_install=no ;;
88398    *)
88399      enable_fast_install=no
88400      # Look at the argument we got.  We use all the common list separators.
88401      lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
88402      for pkg in $enableval; do
88403	IFS="$lt_save_ifs"
88404	if test "X$pkg" = "X$p"; then
88405	  enable_fast_install=yes
88406	fi
88407      done
88408      IFS="$lt_save_ifs"
88409      ;;
88410    esac
88411else $as_nop
88412  enable_fast_install=yes
88413fi
88414
88415
88416{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
88417printf %s "checking for a sed that does not truncate output... " >&6; }
88418if test ${lt_cv_path_SED+y}
88419then :
88420  printf %s "(cached) " >&6
88421else $as_nop
88422  # Loop through the user's path and test for sed and gsed.
88423# Then use that list of sed's as ones to test for truncation.
88424as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
88425for as_dir in $PATH
88426do
88427  IFS=$as_save_IFS
88428  test -z "$as_dir" && as_dir=.
88429  for lt_ac_prog in sed gsed; do
88430    for ac_exec_ext in '' $ac_executable_extensions; do
88431      if test -f "$as_dir/$lt_ac_prog$ac_exec_ext"; then
88432        lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
88433      fi
88434    done
88435  done
88436done
88437lt_ac_max=0
88438lt_ac_count=0
88439# Add /usr/xpg4/bin/sed as it is typically found on Solaris
88440# along with /bin/sed that truncates output.
88441for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
88442  test ! -f $lt_ac_sed && continue
88443  cat /dev/null > conftest.in
88444  lt_ac_count=0
88445  echo $ECHO_N "0123456789$ECHO_C" >conftest.in
88446  # Check for GNU sed and select it if it is found.
88447  if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
88448    lt_cv_path_SED=$lt_ac_sed
88449    break
88450  fi
88451  while true; do
88452    cat conftest.in conftest.in >conftest.tmp
88453    mv conftest.tmp conftest.in
88454    cp conftest.in conftest.nl
88455    echo >>conftest.nl
88456    $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
88457    cmp -s conftest.out conftest.nl || break
88458    # 10000 chars as input seems more than enough
88459    test $lt_ac_count -gt 10 && break
88460    lt_ac_count=`expr $lt_ac_count + 1`
88461    if test $lt_ac_count -gt $lt_ac_max; then
88462      lt_ac_max=$lt_ac_count
88463      lt_cv_path_SED=$lt_ac_sed
88464    fi
88465  done
88466done
88467
88468fi
88469
88470SED=$lt_cv_path_SED
88471{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
88472printf "%s\n" "$SED" >&6; }
88473
88474
88475# Check whether --with-gnu-ld was given.
88476if test ${with_gnu_ld+y}
88477then :
88478  withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
88479else $as_nop
88480  with_gnu_ld=no
88481fi
88482
88483ac_prog=ld
88484if test "$GCC" = yes; then
88485  # Check if gcc -print-prog-name=ld gives a path.
88486  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
88487printf %s "checking for ld used by $CC... " >&6; }
88488  case $host in
88489  *-*-mingw*)
88490    # gcc leaves a trailing carriage return which upsets mingw
88491    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
88492  *)
88493    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
88494  esac
88495  case $ac_prog in
88496    # Accept absolute paths.
88497    [\\/]* | ?:[\\/]*)
88498      re_direlt='/[^/][^/]*/\.\./'
88499      # Canonicalize the pathname of ld
88500      ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
88501      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
88502	ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
88503      done
88504      test -z "$LD" && LD="$ac_prog"
88505      ;;
88506  "")
88507    # If it fails, then pretend we aren't using GCC.
88508    ac_prog=ld
88509    ;;
88510  *)
88511    # If it is relative, then search for the first ld in PATH.
88512    with_gnu_ld=unknown
88513    ;;
88514  esac
88515elif test "$with_gnu_ld" = yes; then
88516  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
88517printf %s "checking for GNU ld... " >&6; }
88518else
88519  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
88520printf %s "checking for non-GNU ld... " >&6; }
88521fi
88522if test ${lt_cv_path_LD+y}
88523then :
88524  printf %s "(cached) " >&6
88525else $as_nop
88526  if test -z "$LD"; then
88527  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
88528  for ac_dir in $PATH; do
88529    IFS="$lt_save_ifs"
88530    test -z "$ac_dir" && ac_dir=.
88531    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
88532      lt_cv_path_LD="$ac_dir/$ac_prog"
88533      # Check to see if the program is GNU ld.  I'd rather use --version,
88534      # but apparently some variants of GNU ld only accept -v.
88535      # Break only if it was the GNU/non-GNU ld that we prefer.
88536      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
88537      *GNU* | *'with BFD'*)
88538	test "$with_gnu_ld" != no && break
88539	;;
88540      *)
88541	test "$with_gnu_ld" != yes && break
88542	;;
88543      esac
88544    fi
88545  done
88546  IFS="$lt_save_ifs"
88547else
88548  lt_cv_path_LD="$LD" # Let the user override the test with a path.
88549fi
88550fi
88551
88552LD="$lt_cv_path_LD"
88553if test -n "$LD"; then
88554  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
88555printf "%s\n" "$LD" >&6; }
88556else
88557  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
88558printf "%s\n" "no" >&6; }
88559fi
88560test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
88561{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
88562printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
88563if test ${lt_cv_prog_gnu_ld+y}
88564then :
88565  printf %s "(cached) " >&6
88566else $as_nop
88567  # I'd rather use --version here, but apparently some GNU lds only accept -v.
88568case `$LD -v 2>&1 </dev/null` in
88569*GNU* | *'with BFD'*)
88570  lt_cv_prog_gnu_ld=yes
88571  ;;
88572*)
88573  lt_cv_prog_gnu_ld=no
88574  ;;
88575esac
88576fi
88577{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
88578printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; }
88579with_gnu_ld=$lt_cv_prog_gnu_ld
88580
88581
88582{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
88583printf %s "checking for $LD option to reload object files... " >&6; }
88584if test ${lt_cv_ld_reload_flag+y}
88585then :
88586  printf %s "(cached) " >&6
88587else $as_nop
88588  lt_cv_ld_reload_flag='-r'
88589fi
88590{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
88591printf "%s\n" "$lt_cv_ld_reload_flag" >&6; }
88592reload_flag=$lt_cv_ld_reload_flag
88593case $reload_flag in
88594"" | " "*) ;;
88595*) reload_flag=" $reload_flag" ;;
88596esac
88597reload_cmds='$LD$reload_flag -o $output$reload_objs'
88598case $host_os in
88599  darwin*)
88600    if test "$GCC" = yes; then
88601      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
88602    else
88603      reload_cmds='$LD$reload_flag -o $output$reload_objs'
88604    fi
88605    ;;
88606esac
88607
88608{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BSD-compatible nm" >&5
88609printf %s "checking for BSD-compatible nm... " >&6; }
88610if test ${lt_cv_path_NM+y}
88611then :
88612  printf %s "(cached) " >&6
88613else $as_nop
88614  if test -n "$NM"; then
88615  # Let the user override the test.
88616  lt_cv_path_NM="$NM"
88617else
88618  lt_nm_to_check="${ac_tool_prefix}nm"
88619  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
88620    lt_nm_to_check="$lt_nm_to_check nm"
88621  fi
88622  for lt_tmp_nm in $lt_nm_to_check; do
88623    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
88624    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
88625      IFS="$lt_save_ifs"
88626      test -z "$ac_dir" && ac_dir=.
88627      tmp_nm="$ac_dir/$lt_tmp_nm"
88628      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
88629	# Check to see if the nm accepts a BSD-compat flag.
88630	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
88631	#   nm: unknown option "B" ignored
88632	# Tru64's nm complains that /dev/null is an invalid object file
88633	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
88634	*/dev/null* | *'Invalid file or object type'*)
88635	  lt_cv_path_NM="$tmp_nm -B"
88636	  break
88637	  ;;
88638	*)
88639	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
88640	  */dev/null*)
88641	    lt_cv_path_NM="$tmp_nm -p"
88642	    break
88643	    ;;
88644	  *)
88645	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
88646	    continue # so that we can try to find one that supports BSD flags
88647	    ;;
88648	  esac
88649	  ;;
88650	esac
88651      fi
88652    done
88653    IFS="$lt_save_ifs"
88654  done
88655  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
88656fi
88657fi
88658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
88659printf "%s\n" "$lt_cv_path_NM" >&6; }
88660NM="$lt_cv_path_NM"
88661
88662{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
88663printf %s "checking how to recognize dependent libraries... " >&6; }
88664if test ${lt_cv_deplibs_check_method+y}
88665then :
88666  printf %s "(cached) " >&6
88667else $as_nop
88668  lt_cv_file_magic_cmd='$MAGIC_CMD'
88669lt_cv_file_magic_test_file=
88670lt_cv_deplibs_check_method='unknown'
88671# Need to set the preceding variable on all platforms that support
88672# interlibrary dependencies.
88673# 'none' -- dependencies not supported.
88674# `unknown' -- same as none, but documents that we really don't know.
88675# 'pass_all' -- all dependencies passed with no checks.
88676# 'test_compile' -- check by making test program.
88677# 'file_magic [[regex]]' -- check by looking for files in library path
88678# which responds to the $file_magic_cmd with a given extended regex.
88679# If you have `file' or equivalent on your system and you're not sure
88680# whether `pass_all' will *always* work, you probably want this one.
88681
88682case $host_os in
88683aix[4-9]*)
88684  lt_cv_deplibs_check_method=pass_all
88685  ;;
88686
88687beos* | haiku*)
88688  lt_cv_deplibs_check_method=pass_all
88689  ;;
88690
88691bsdi[45]*)
88692  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
88693  lt_cv_file_magic_cmd='/usr/bin/file -L'
88694  lt_cv_file_magic_test_file=/shlib/libc.so
88695  ;;
88696
88697cygwin*)
88698  # func_win32_libid is a shell function defined in ltmain.sh
88699  lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
88700  lt_cv_file_magic_cmd='func_win32_libid'
88701  ;;
88702
88703mingw* | pw32*)
88704  # Base MSYS/MinGW do not provide the 'file' command needed by
88705  # func_win32_libid shell function, so use a weaker test based on 'objdump',
88706  # unless we find 'file', for example because we are cross-compiling.
88707  if ( file / ) >/dev/null 2>&1; then
88708    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
88709    lt_cv_file_magic_cmd='func_win32_libid'
88710  else
88711    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
88712    lt_cv_file_magic_cmd='$OBJDUMP -f'
88713  fi
88714  ;;
88715
88716darwin* | rhapsody*)
88717  lt_cv_deplibs_check_method=pass_all
88718  ;;
88719
88720freebsd* | dragonfly*)
88721  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
88722    case $host_cpu in
88723    i*86 )
88724      # Not sure whether the presence of OpenBSD here was a mistake.
88725      # Let's accept both of them until this is cleared up.
88726      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
88727      lt_cv_file_magic_cmd=/usr/bin/file
88728      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
88729      ;;
88730    esac
88731  else
88732    lt_cv_deplibs_check_method=pass_all
88733  fi
88734  ;;
88735
88736gnu*)
88737  lt_cv_deplibs_check_method=pass_all
88738  ;;
88739
88740hpux10.20* | hpux11*)
88741  lt_cv_file_magic_cmd=/usr/bin/file
88742  case $host_cpu in
88743  ia64*)
88744    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
88745    lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
88746    ;;
88747  hppa*64*)
88748    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
88749    lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
88750    ;;
88751  *)
88752    lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
88753    lt_cv_file_magic_test_file=/usr/lib/libc.sl
88754    ;;
88755  esac
88756  ;;
88757
88758interix[3-9]*)
88759  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
88760  lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
88761  ;;
88762
88763irix5* | irix6* | nonstopux*)
88764  case $LD in
88765  *-32|*"-32 ") libmagic=32-bit;;
88766  *-n32|*"-n32 ") libmagic=N32;;
88767  *-64|*"-64 ") libmagic=64-bit;;
88768  *) libmagic=never-match;;
88769  esac
88770  lt_cv_deplibs_check_method=pass_all
88771  ;;
88772
88773# This must be Linux ELF.
88774linux* | k*bsd*-gnu)
88775  lt_cv_deplibs_check_method=pass_all
88776  ;;
88777
88778netbsd*)
88779  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
88780    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
88781  else
88782    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
88783  fi
88784  ;;
88785
88786newos6*)
88787  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
88788  lt_cv_file_magic_cmd=/usr/bin/file
88789  lt_cv_file_magic_test_file=/usr/lib/libnls.so
88790  ;;
88791
88792nto-qnx*)
88793  lt_cv_deplibs_check_method=unknown
88794  ;;
88795
88796openbsd*)
88797  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
88798    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
88799  else
88800    lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
88801  fi
88802  ;;
88803
88804osf3* | osf4* | osf5*)
88805  lt_cv_deplibs_check_method=pass_all
88806  ;;
88807
88808rdos*)
88809  lt_cv_deplibs_check_method=pass_all
88810  ;;
88811
88812solaris*)
88813  lt_cv_deplibs_check_method=pass_all
88814  ;;
88815
88816sysv4 | sysv4.3*)
88817  case $host_vendor in
88818  motorola)
88819    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]'
88820    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
88821    ;;
88822  ncr)
88823    lt_cv_deplibs_check_method=pass_all
88824    ;;
88825  sequent)
88826    lt_cv_file_magic_cmd='/bin/file'
88827    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
88828    ;;
88829  sni)
88830    lt_cv_file_magic_cmd='/bin/file'
88831    lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
88832    lt_cv_file_magic_test_file=/lib/libc.so
88833    ;;
88834  siemens)
88835    lt_cv_deplibs_check_method=pass_all
88836    ;;
88837  pc)
88838    lt_cv_deplibs_check_method=pass_all
88839    ;;
88840  esac
88841  ;;
88842
88843sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
88844  lt_cv_deplibs_check_method=pass_all
88845  ;;
88846esac
88847
88848fi
88849{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
88850printf "%s\n" "$lt_cv_deplibs_check_method" >&6; }
88851file_magic_cmd=$lt_cv_file_magic_cmd
88852deplibs_check_method=$lt_cv_deplibs_check_method
88853test -z "$deplibs_check_method" && deplibs_check_method=unknown
88854
88855
88856
88857
88858# If no C compiler was specified, use CC.
88859LTCC=${LTCC-"$CC"}
88860
88861# If no C compiler flags were specified, use CFLAGS.
88862LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
88863
88864# Allow CC to be a program name with arguments.
88865compiler=$CC
88866
88867#AC_ARG_ENABLE([libtool-lock],
88868#[  --disable-libtool-lock  avoid locking (might break parallel builds)])
88869#test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
88870
88871# Some flags need to be propagated to the compiler or linker for good
88872# libtool support.
88873case $host in
88874ia64-*-hpux*)
88875  # Find out which ABI we are using.
88876  echo 'int i;' > conftest.$ac_ext
88877  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
88878  (eval $ac_compile) 2>&5
88879  ac_status=$?
88880  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
88881  test $ac_status = 0; }; then
88882    case `/usr/bin/file conftest.$ac_objext` in
88883    *ELF-32*)
88884      HPUX_IA64_MODE="32"
88885      ;;
88886    *ELF-64*)
88887      HPUX_IA64_MODE="64"
88888      ;;
88889    esac
88890  fi
88891  rm -rf conftest*
88892  ;;
88893*-*-irix6*)
88894  # Find out which ABI we are using.
88895  echo '#line 88895 "configure"' > conftest.$ac_ext
88896  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
88897  (eval $ac_compile) 2>&5
88898  ac_status=$?
88899  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
88900  test $ac_status = 0; }; then
88901   if test "$lt_cv_prog_gnu_ld" = yes; then
88902    case `/usr/bin/file conftest.$ac_objext` in
88903    *32-bit*)
88904      LD="${LD-ld} -melf32bsmip"
88905      ;;
88906    *N32*)
88907      LD="${LD-ld} -melf32bmipn32"
88908      ;;
88909    *64-bit*)
88910      LD="${LD-ld} -melf64bmip"
88911      ;;
88912    esac
88913   else
88914    case `/usr/bin/file conftest.$ac_objext` in
88915    *32-bit*)
88916      LD="${LD-ld} -32"
88917      ;;
88918    *N32*)
88919      LD="${LD-ld} -n32"
88920      ;;
88921    *64-bit*)
88922      LD="${LD-ld} -64"
88923      ;;
88924    esac
88925   fi
88926  fi
88927  rm -rf conftest*
88928  ;;
88929
88930x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
88931s390*-*linux*|sparc*-*linux*)
88932  # Find out which ABI we are using.
88933  echo 'int i;' > conftest.$ac_ext
88934  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
88935  (eval $ac_compile) 2>&5
88936  ac_status=$?
88937  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
88938  test $ac_status = 0; }; then
88939    case `/usr/bin/file conftest.o` in
88940    *32-bit*)
88941      case $host in
88942        x86_64-*kfreebsd*-gnu)
88943          LD="${LD-ld} -m elf_i386_fbsd"
88944          ;;
88945        x86_64-*linux*)
88946          LD="${LD-ld} -m elf_i386"
88947          ;;
88948        powerpc64le-*linux*)
88949          LD="${LD-ld} -m elf32lppclinux"
88950          ;;
88951        powerpc64-*linux*)
88952          LD="${LD-ld} -m elf32ppclinux"
88953          ;;
88954        s390x-*linux*)
88955          LD="${LD-ld} -m elf_s390"
88956          ;;
88957        sparc64-*linux*)
88958          LD="${LD-ld} -m elf32_sparc"
88959          ;;
88960      esac
88961      ;;
88962    *64-bit*)
88963      case $host in
88964        x86_64-*kfreebsd*-gnu)
88965          LD="${LD-ld} -m elf_x86_64_fbsd"
88966          ;;
88967        x86_64-*linux*)
88968          LD="${LD-ld} -m elf_x86_64"
88969          ;;
88970        powerpcle-*linux*)
88971          LD="${LD-ld} -m elf64lppc"
88972          ;;
88973        powerpc-*linux*)
88974          LD="${LD-ld} -m elf64ppc"
88975          ;;
88976        s390*-*linux*)
88977          LD="${LD-ld} -m elf64_s390"
88978          ;;
88979        sparc*-*linux*)
88980          LD="${LD-ld} -m elf64_sparc"
88981          ;;
88982      esac
88983      ;;
88984    esac
88985  fi
88986  rm -rf conftest*
88987  ;;
88988
88989*-*-sco3.2v5*)
88990  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
88991  SAVE_CFLAGS="$CFLAGS"
88992  CFLAGS="$CFLAGS -belf"
88993  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
88994printf %s "checking whether the C compiler needs -belf... " >&6; }
88995if test ${lt_cv_cc_needs_belf+y}
88996then :
88997  printf %s "(cached) " >&6
88998else $as_nop
88999
89000     ac_ext=c
89001ac_cpp='$CPP $CPPFLAGS'
89002ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
89003ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
89004ac_compiler_gnu=$ac_cv_c_compiler_gnu
89005
89006     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
89007/* end confdefs.h.  */
89008
89009int
89010main (void)
89011{
89012
89013  ;
89014  return 0;
89015}
89016_ACEOF
89017if ac_fn_c_try_link "$LINENO"
89018then :
89019  lt_cv_cc_needs_belf=yes
89020else $as_nop
89021  lt_cv_cc_needs_belf=no
89022fi
89023rm -f core conftest.err conftest.$ac_objext conftest.beam \
89024    conftest$ac_exeext conftest.$ac_ext
89025     ac_ext=c
89026ac_cpp='$CPP $CPPFLAGS'
89027ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
89028ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
89029ac_compiler_gnu=$ac_cv_c_compiler_gnu
89030
89031fi
89032{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
89033printf "%s\n" "$lt_cv_cc_needs_belf" >&6; }
89034  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
89035    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
89036    CFLAGS="$SAVE_CFLAGS"
89037  fi
89038  ;;
89039sparc*-*solaris*)
89040  # Find out which ABI we are using.
89041  echo 'int i;' > conftest.$ac_ext
89042  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
89043  (eval $ac_compile) 2>&5
89044  ac_status=$?
89045  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
89046  test $ac_status = 0; }; then
89047    case `/usr/bin/file conftest.o` in
89048    *64-bit*)
89049      case $lt_cv_prog_gnu_ld in
89050      yes*) LD="${LD-ld} -m elf64_sparc" ;;
89051      *)
89052        if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
89053	  LD="${LD-ld} -64"
89054	fi
89055	;;
89056      esac
89057      ;;
89058    esac
89059  fi
89060  rm -rf conftest*
89061  ;;
89062
89063
89064esac
89065
89066need_locks="$enable_libtool_lock"
89067
89068
89069
89070
89071if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
89072    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
89073    (test "X$CXX" != "Xg++"))) ; then
89074  ac_ext=cpp
89075ac_cpp='$CXXCPP $CPPFLAGS'
89076ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
89077ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
89078ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
89079{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
89080printf %s "checking how to run the C++ preprocessor... " >&6; }
89081if test -z "$CXXCPP"; then
89082  if test ${ac_cv_prog_CXXCPP+y}
89083then :
89084  printf %s "(cached) " >&6
89085else $as_nop
89086      # Double quotes because $CXX needs to be expanded
89087    for CXXCPP in "$CXX -E" cpp /lib/cpp
89088    do
89089      ac_preproc_ok=false
89090for ac_cxx_preproc_warn_flag in '' yes
89091do
89092  # Use a header file that comes with gcc, so configuring glibc
89093  # with a fresh cross-compiler works.
89094  # On the NeXT, cc -E runs the code through the compiler's parser,
89095  # not just through cpp. "Syntax error" is here to catch this case.
89096  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
89097/* end confdefs.h.  */
89098#include <limits.h>
89099		     Syntax error
89100_ACEOF
89101if ac_fn_cxx_try_cpp "$LINENO"
89102then :
89103
89104else $as_nop
89105  # Broken: fails on valid input.
89106continue
89107fi
89108rm -f conftest.err conftest.i conftest.$ac_ext
89109
89110  # OK, works on sane cases.  Now check whether nonexistent headers
89111  # can be detected and how.
89112  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
89113/* end confdefs.h.  */
89114#include <ac_nonexistent.h>
89115_ACEOF
89116if ac_fn_cxx_try_cpp "$LINENO"
89117then :
89118  # Broken: success on invalid input.
89119continue
89120else $as_nop
89121  # Passes both tests.
89122ac_preproc_ok=:
89123break
89124fi
89125rm -f conftest.err conftest.i conftest.$ac_ext
89126
89127done
89128# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
89129rm -f conftest.i conftest.err conftest.$ac_ext
89130if $ac_preproc_ok
89131then :
89132  break
89133fi
89134
89135    done
89136    ac_cv_prog_CXXCPP=$CXXCPP
89137
89138fi
89139  CXXCPP=$ac_cv_prog_CXXCPP
89140else
89141  ac_cv_prog_CXXCPP=$CXXCPP
89142fi
89143{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
89144printf "%s\n" "$CXXCPP" >&6; }
89145ac_preproc_ok=false
89146for ac_cxx_preproc_warn_flag in '' yes
89147do
89148  # Use a header file that comes with gcc, so configuring glibc
89149  # with a fresh cross-compiler works.
89150  # On the NeXT, cc -E runs the code through the compiler's parser,
89151  # not just through cpp. "Syntax error" is here to catch this case.
89152  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
89153/* end confdefs.h.  */
89154#include <limits.h>
89155		     Syntax error
89156_ACEOF
89157if ac_fn_cxx_try_cpp "$LINENO"
89158then :
89159
89160else $as_nop
89161  # Broken: fails on valid input.
89162continue
89163fi
89164rm -f conftest.err conftest.i conftest.$ac_ext
89165
89166  # OK, works on sane cases.  Now check whether nonexistent headers
89167  # can be detected and how.
89168  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
89169/* end confdefs.h.  */
89170#include <ac_nonexistent.h>
89171_ACEOF
89172if ac_fn_cxx_try_cpp "$LINENO"
89173then :
89174  # Broken: success on invalid input.
89175continue
89176else $as_nop
89177  # Passes both tests.
89178ac_preproc_ok=:
89179break
89180fi
89181rm -f conftest.err conftest.i conftest.$ac_ext
89182
89183done
89184# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
89185rm -f conftest.i conftest.err conftest.$ac_ext
89186if $ac_preproc_ok
89187then :
89188
89189else $as_nop
89190  { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
89191printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
89192as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
89193See \`config.log' for more details" "$LINENO" 5; }
89194fi
89195
89196ac_ext=cpp
89197ac_cpp='$CXXCPP $CPPFLAGS'
89198ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
89199ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
89200ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
89201
89202fi
89203
89204
89205# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
89206# find the maximum length of command line arguments
89207{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
89208printf %s "checking the maximum length of command line arguments... " >&6; }
89209if test ${lt_cv_sys_max_cmd_len+y}
89210then :
89211  printf %s "(cached) " >&6
89212else $as_nop
89213    i=0
89214  teststring="ABCD"
89215
89216  case $build_os in
89217  msdosdjgpp*)
89218    # On DJGPP, this test can blow up pretty badly due to problems in libc
89219    # (any single argument exceeding 2000 bytes causes a buffer overrun
89220    # during glob expansion).  Even if it were fixed, the result of this
89221    # check would be larger than it should be.
89222    lt_cv_sys_max_cmd_len=12288;    # 12K is about right
89223    ;;
89224
89225  gnu*)
89226    # Under GNU Hurd, this test is not required because there is
89227    # no limit to the length of command line arguments.
89228    # Libtool will interpret -1 as no limit whatsoever
89229    lt_cv_sys_max_cmd_len=-1;
89230    ;;
89231
89232  cygwin* | mingw*)
89233    # On Win9x/ME, this test blows up -- it succeeds, but takes
89234    # about 5 minutes as the teststring grows exponentially.
89235    # Worse, since 9x/ME are not pre-emptively multitasking,
89236    # you end up with a "frozen" computer, even though with patience
89237    # the test eventually succeeds (with a max line length of 256k).
89238    # Instead, let's just punt: use the minimum linelength reported by
89239    # all of the supported platforms: 8192 (on NT/2K/XP).
89240    lt_cv_sys_max_cmd_len=8192;
89241    ;;
89242
89243  amigaos*)
89244    # On AmigaOS with pdksh, this test takes hours, literally.
89245    # So we just punt and use a minimum line length of 8192.
89246    lt_cv_sys_max_cmd_len=8192;
89247    ;;
89248
89249  netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
89250    # This has been around since 386BSD, at least.  Likely further.
89251    if test -x /sbin/sysctl; then
89252      lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
89253    elif test -x /usr/sbin/sysctl; then
89254      lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
89255    else
89256      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
89257    fi
89258    # And add a safety zone
89259    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
89260    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
89261    ;;
89262
89263  interix*)
89264    # We know the value 262144 and hardcode it with a safety zone (like BSD)
89265    lt_cv_sys_max_cmd_len=196608
89266    ;;
89267
89268  osf*)
89269    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
89270    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
89271    # nice to cause kernel panics so lets avoid the loop below.
89272    # First set a reasonable default.
89273    lt_cv_sys_max_cmd_len=16384
89274    #
89275    if test -x /sbin/sysconfig; then
89276      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
89277        *1*) lt_cv_sys_max_cmd_len=-1 ;;
89278      esac
89279    fi
89280    ;;
89281  sco3.2v5*)
89282    lt_cv_sys_max_cmd_len=102400
89283    ;;
89284  sysv5* | sco5v6* | sysv4.2uw2*)
89285    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
89286    if test -n "$kargmax"; then
89287      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ 	]//'`
89288    else
89289      lt_cv_sys_max_cmd_len=32768
89290    fi
89291    ;;
89292  *)
89293    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
89294    if test -n "$lt_cv_sys_max_cmd_len"; then
89295      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
89296      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
89297    else
89298      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
89299      while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
89300	       = "XX$teststring") >/dev/null 2>&1 &&
89301	      new_result=`expr "X$teststring" : ".*" 2>&1` &&
89302	      lt_cv_sys_max_cmd_len=$new_result &&
89303	      test $i != 17 # 1/2 MB should be enough
89304      do
89305        i=`expr $i + 1`
89306        teststring=$teststring$teststring
89307      done
89308      teststring=
89309      # Add a significant safety factor because C++ compilers can tack on massive
89310      # amounts of additional arguments before passing them to the linker.
89311      # It appears as though 1/2 is a usable value.
89312      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
89313    fi
89314    ;;
89315  esac
89316
89317fi
89318
89319if test -n $lt_cv_sys_max_cmd_len ; then
89320  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
89321printf "%s\n" "$lt_cv_sys_max_cmd_len" >&6; }
89322else
89323  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5
89324printf "%s\n" "none" >&6; }
89325fi
89326
89327
89328
89329
89330
89331# Check for command to grab the raw symbol name followed by C symbol from nm.
89332{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
89333printf %s "checking command to parse $NM output from $compiler object... " >&6; }
89334if test ${lt_cv_sys_global_symbol_pipe+y}
89335then :
89336  printf %s "(cached) " >&6
89337else $as_nop
89338
89339# These are sane defaults that work on at least a few old systems.
89340# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
89341
89342# Character class describing NM global symbol codes.
89343symcode='[BCDEGRST]'
89344
89345# Regexp to match symbols that can be accessed directly from C.
89346sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
89347
89348# Transform an extracted symbol line into a proper C declaration
89349lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
89350
89351# Transform an extracted symbol line into symbol name and symbol address
89352lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
89353
89354# Define system-specific variables.
89355case $host_os in
89356aix*)
89357  symcode='[BCDT]'
89358  ;;
89359cygwin* | mingw* | pw32*)
89360  symcode='[ABCDGISTW]'
89361  ;;
89362hpux*) # Its linker distinguishes data from code symbols
89363  if test "$host_cpu" = ia64; then
89364    symcode='[ABCDEGRST]'
89365  fi
89366  lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
89367  lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
89368  ;;
89369linux* | k*bsd*-gnu)
89370  if test "$host_cpu" = ia64; then
89371    symcode='[ABCDGIRSTW]'
89372    lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
89373    lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
89374  fi
89375  ;;
89376irix* | nonstopux*)
89377  symcode='[BCDEGRST]'
89378  ;;
89379osf*)
89380  symcode='[BCDEGQRST]'
89381  ;;
89382solaris*)
89383  symcode='[BDRT]'
89384  ;;
89385sco3.2v5*)
89386  symcode='[DT]'
89387  ;;
89388sysv4.2uw2*)
89389  symcode='[DT]'
89390  ;;
89391sysv5* | sco5v6* | unixware* | OpenUNIX*)
89392  symcode='[ABDT]'
89393  ;;
89394sysv4)
89395  symcode='[DFNSTU]'
89396  ;;
89397esac
89398
89399# Handle CRLF in mingw tool chain
89400opt_cr=
89401case $build_os in
89402mingw*)
89403  opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
89404  ;;
89405esac
89406
89407# If we're using GNU nm, then use its standard symbol codes.
89408case `$NM -V 2>&1` in
89409*GNU* | *'with BFD'*)
89410  symcode='[ABCDGIRSTW]' ;;
89411esac
89412
89413# Try without a prefix undercore, then with it.
89414for ac_symprfx in "" "_"; do
89415
89416  # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
89417  symxfrm="\\1 $ac_symprfx\\2 \\2"
89418
89419  # Write the raw and C identifiers.
89420  lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ 	]\($symcode$symcode*\)[ 	][ 	]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
89421
89422  # Check to see that the pipe works correctly.
89423  pipe_works=no
89424
89425  rm -f conftest*
89426  cat > conftest.$ac_ext <<EOF
89427#ifdef __cplusplus
89428extern "C" {
89429#endif
89430char nm_test_var;
89431void nm_test_func(){}
89432#ifdef __cplusplus
89433}
89434#endif
89435int main(){nm_test_var='a';nm_test_func();return(0);}
89436EOF
89437
89438  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
89439  (eval $ac_compile) 2>&5
89440  ac_status=$?
89441  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
89442  test $ac_status = 0; }; then
89443    # Now try to grab the symbols.
89444    nlist=conftest.nm
89445    if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\""; } >&5
89446  (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
89447  ac_status=$?
89448  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
89449  test $ac_status = 0; } && test -s "$nlist"; then
89450      # Try sorting and uniquifying the output.
89451      if sort "$nlist" | uniq > "$nlist"T; then
89452	mv -f "$nlist"T "$nlist"
89453      else
89454	rm -f "$nlist"T
89455      fi
89456
89457      # Make sure that we snagged all the symbols we need.
89458      if grep ' nm_test_var$' "$nlist" >/dev/null; then
89459	if grep ' nm_test_func$' "$nlist" >/dev/null; then
89460	  cat <<EOF > conftest.$ac_ext
89461#ifdef __cplusplus
89462extern "C" {
89463#endif
89464
89465EOF
89466	  # Now generate the symbol file.
89467	  eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
89468
89469	  cat <<EOF >> conftest.$ac_ext
89470#if defined (__STDC__) && __STDC__
89471# define lt_ptr_t void *
89472#else
89473# define lt_ptr_t char *
89474# define const
89475#endif
89476
89477/* The mapping between symbol names and symbols. */
89478const struct {
89479  const char *name;
89480  lt_ptr_t address;
89481}
89482lt_preloaded_symbols[] =
89483{
89484EOF
89485	  $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
89486	  cat <<\EOF >> conftest.$ac_ext
89487  {0, (lt_ptr_t) 0}
89488};
89489
89490#ifdef __cplusplus
89491}
89492#endif
89493EOF
89494	  # Now try linking the two files.
89495	  mv conftest.$ac_objext conftstm.$ac_objext
89496	  lt_save_LIBS="$LIBS"
89497	  lt_save_CFLAGS="$CFLAGS"
89498	  LIBS="conftstm.$ac_objext"
89499	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
89500	  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
89501  (eval $ac_link) 2>&5
89502  ac_status=$?
89503  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
89504  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
89505	    pipe_works=yes
89506	  fi
89507	  LIBS="$lt_save_LIBS"
89508	  CFLAGS="$lt_save_CFLAGS"
89509	else
89510	  echo "cannot find nm_test_func in $nlist" >&5
89511	fi
89512      else
89513	echo "cannot find nm_test_var in $nlist" >&5
89514      fi
89515    else
89516      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
89517    fi
89518  else
89519    echo "$progname: failed program was:" >&5
89520    cat conftest.$ac_ext >&5
89521  fi
89522  rm -rf conftest* conftst*
89523
89524  # Do not use the global_symbol_pipe unless it works.
89525  if test "$pipe_works" = yes; then
89526    break
89527  else
89528    lt_cv_sys_global_symbol_pipe=
89529  fi
89530done
89531
89532fi
89533
89534if test -z "$lt_cv_sys_global_symbol_pipe"; then
89535  lt_cv_sys_global_symbol_to_cdecl=
89536fi
89537if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
89538  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5
89539printf "%s\n" "failed" >&6; }
89540else
89541  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5
89542printf "%s\n" "ok" >&6; }
89543fi
89544
89545{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
89546printf %s "checking for objdir... " >&6; }
89547if test ${lt_cv_objdir+y}
89548then :
89549  printf %s "(cached) " >&6
89550else $as_nop
89551  rm -f .libs 2>/dev/null
89552mkdir .libs 2>/dev/null
89553if test -d .libs; then
89554  lt_cv_objdir=.libs
89555else
89556  # MS-DOS does not allow filenames that begin with a dot.
89557  lt_cv_objdir=_libs
89558fi
89559rmdir .libs 2>/dev/null
89560fi
89561{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
89562printf "%s\n" "$lt_cv_objdir" >&6; }
89563objdir=$lt_cv_objdir
89564
89565
89566
89567
89568
89569case $host_os in
89570aix3*)
89571  # AIX sometimes has problems with the GCC collect2 program.  For some
89572  # reason, if we set the COLLECT_NAMES environment variable, the problems
89573  # vanish in a puff of smoke.
89574  if test "X${COLLECT_NAMES+set}" != Xset; then
89575    COLLECT_NAMES=
89576    export COLLECT_NAMES
89577  fi
89578  ;;
89579esac
89580
89581# Sed substitution that helps us do robust quoting.  It backslashifies
89582# metacharacters that are still active within double-quoted strings.
89583Xsed='sed -e 1s/^X//'
89584sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
89585
89586# Same as above, but do not quote variable references.
89587double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
89588
89589# Sed substitution to delay expansion of an escaped shell variable in a
89590# double_quote_subst'ed string.
89591delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
89592
89593# Sed substitution to avoid accidental globbing in evaled expressions
89594no_glob_subst='s/\*/\\\*/g'
89595
89596# Constants:
89597rm="rm -f"
89598
89599# Global variables:
89600default_ofile=libtool
89601can_build_shared=yes
89602
89603# All known linkers require a `.a' archive for static linking (except MSVC,
89604# which needs '.lib').
89605libext=a
89606ltmain="$ac_aux_dir/ltmain.sh"
89607ofile="$default_ofile"
89608with_gnu_ld="$lt_cv_prog_gnu_ld"
89609
89610if test -n "$ac_tool_prefix"; then
89611  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
89612set dummy ${ac_tool_prefix}ar; ac_word=$2
89613{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89614printf %s "checking for $ac_word... " >&6; }
89615if test ${ac_cv_prog_AR+y}
89616then :
89617  printf %s "(cached) " >&6
89618else $as_nop
89619  if test -n "$AR"; then
89620  ac_cv_prog_AR="$AR" # Let the user override the test.
89621else
89622as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89623for as_dir in $PATH
89624do
89625  IFS=$as_save_IFS
89626  case $as_dir in #(((
89627    '') as_dir=./ ;;
89628    */) ;;
89629    *) as_dir=$as_dir/ ;;
89630  esac
89631    for ac_exec_ext in '' $ac_executable_extensions; do
89632  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89633    ac_cv_prog_AR="${ac_tool_prefix}ar"
89634    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89635    break 2
89636  fi
89637done
89638  done
89639IFS=$as_save_IFS
89640
89641fi
89642fi
89643AR=$ac_cv_prog_AR
89644if test -n "$AR"; then
89645  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
89646printf "%s\n" "$AR" >&6; }
89647else
89648  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89649printf "%s\n" "no" >&6; }
89650fi
89651
89652
89653fi
89654if test -z "$ac_cv_prog_AR"; then
89655  ac_ct_AR=$AR
89656  # Extract the first word of "ar", so it can be a program name with args.
89657set dummy ar; ac_word=$2
89658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89659printf %s "checking for $ac_word... " >&6; }
89660if test ${ac_cv_prog_ac_ct_AR+y}
89661then :
89662  printf %s "(cached) " >&6
89663else $as_nop
89664  if test -n "$ac_ct_AR"; then
89665  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
89666else
89667as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89668for as_dir in $PATH
89669do
89670  IFS=$as_save_IFS
89671  case $as_dir in #(((
89672    '') as_dir=./ ;;
89673    */) ;;
89674    *) as_dir=$as_dir/ ;;
89675  esac
89676    for ac_exec_ext in '' $ac_executable_extensions; do
89677  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89678    ac_cv_prog_ac_ct_AR="ar"
89679    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89680    break 2
89681  fi
89682done
89683  done
89684IFS=$as_save_IFS
89685
89686fi
89687fi
89688ac_ct_AR=$ac_cv_prog_ac_ct_AR
89689if test -n "$ac_ct_AR"; then
89690  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
89691printf "%s\n" "$ac_ct_AR" >&6; }
89692else
89693  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89694printf "%s\n" "no" >&6; }
89695fi
89696
89697  if test "x$ac_ct_AR" = x; then
89698    AR="false"
89699  else
89700    case $cross_compiling:$ac_tool_warned in
89701yes:)
89702{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
89703printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
89704ac_tool_warned=yes ;;
89705esac
89706    AR=$ac_ct_AR
89707  fi
89708else
89709  AR="$ac_cv_prog_AR"
89710fi
89711
89712if test -n "$ac_tool_prefix"; then
89713  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
89714set dummy ${ac_tool_prefix}ranlib; ac_word=$2
89715{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89716printf %s "checking for $ac_word... " >&6; }
89717if test ${ac_cv_prog_RANLIB+y}
89718then :
89719  printf %s "(cached) " >&6
89720else $as_nop
89721  if test -n "$RANLIB"; then
89722  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
89723else
89724as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89725for as_dir in $PATH
89726do
89727  IFS=$as_save_IFS
89728  case $as_dir in #(((
89729    '') as_dir=./ ;;
89730    */) ;;
89731    *) as_dir=$as_dir/ ;;
89732  esac
89733    for ac_exec_ext in '' $ac_executable_extensions; do
89734  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89735    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
89736    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89737    break 2
89738  fi
89739done
89740  done
89741IFS=$as_save_IFS
89742
89743fi
89744fi
89745RANLIB=$ac_cv_prog_RANLIB
89746if test -n "$RANLIB"; then
89747  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
89748printf "%s\n" "$RANLIB" >&6; }
89749else
89750  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89751printf "%s\n" "no" >&6; }
89752fi
89753
89754
89755fi
89756if test -z "$ac_cv_prog_RANLIB"; then
89757  ac_ct_RANLIB=$RANLIB
89758  # Extract the first word of "ranlib", so it can be a program name with args.
89759set dummy ranlib; ac_word=$2
89760{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89761printf %s "checking for $ac_word... " >&6; }
89762if test ${ac_cv_prog_ac_ct_RANLIB+y}
89763then :
89764  printf %s "(cached) " >&6
89765else $as_nop
89766  if test -n "$ac_ct_RANLIB"; then
89767  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
89768else
89769as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89770for as_dir in $PATH
89771do
89772  IFS=$as_save_IFS
89773  case $as_dir in #(((
89774    '') as_dir=./ ;;
89775    */) ;;
89776    *) as_dir=$as_dir/ ;;
89777  esac
89778    for ac_exec_ext in '' $ac_executable_extensions; do
89779  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89780    ac_cv_prog_ac_ct_RANLIB="ranlib"
89781    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89782    break 2
89783  fi
89784done
89785  done
89786IFS=$as_save_IFS
89787
89788fi
89789fi
89790ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
89791if test -n "$ac_ct_RANLIB"; then
89792  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
89793printf "%s\n" "$ac_ct_RANLIB" >&6; }
89794else
89795  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89796printf "%s\n" "no" >&6; }
89797fi
89798
89799  if test "x$ac_ct_RANLIB" = x; then
89800    RANLIB=":"
89801  else
89802    case $cross_compiling:$ac_tool_warned in
89803yes:)
89804{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
89805printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
89806ac_tool_warned=yes ;;
89807esac
89808    RANLIB=$ac_ct_RANLIB
89809  fi
89810else
89811  RANLIB="$ac_cv_prog_RANLIB"
89812fi
89813
89814if test -n "$ac_tool_prefix"; then
89815  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
89816set dummy ${ac_tool_prefix}strip; ac_word=$2
89817{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89818printf %s "checking for $ac_word... " >&6; }
89819if test ${ac_cv_prog_STRIP+y}
89820then :
89821  printf %s "(cached) " >&6
89822else $as_nop
89823  if test -n "$STRIP"; then
89824  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
89825else
89826as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89827for as_dir in $PATH
89828do
89829  IFS=$as_save_IFS
89830  case $as_dir in #(((
89831    '') as_dir=./ ;;
89832    */) ;;
89833    *) as_dir=$as_dir/ ;;
89834  esac
89835    for ac_exec_ext in '' $ac_executable_extensions; do
89836  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89837    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
89838    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89839    break 2
89840  fi
89841done
89842  done
89843IFS=$as_save_IFS
89844
89845fi
89846fi
89847STRIP=$ac_cv_prog_STRIP
89848if test -n "$STRIP"; then
89849  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
89850printf "%s\n" "$STRIP" >&6; }
89851else
89852  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89853printf "%s\n" "no" >&6; }
89854fi
89855
89856
89857fi
89858if test -z "$ac_cv_prog_STRIP"; then
89859  ac_ct_STRIP=$STRIP
89860  # Extract the first word of "strip", so it can be a program name with args.
89861set dummy strip; ac_word=$2
89862{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
89863printf %s "checking for $ac_word... " >&6; }
89864if test ${ac_cv_prog_ac_ct_STRIP+y}
89865then :
89866  printf %s "(cached) " >&6
89867else $as_nop
89868  if test -n "$ac_ct_STRIP"; then
89869  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
89870else
89871as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
89872for as_dir in $PATH
89873do
89874  IFS=$as_save_IFS
89875  case $as_dir in #(((
89876    '') as_dir=./ ;;
89877    */) ;;
89878    *) as_dir=$as_dir/ ;;
89879  esac
89880    for ac_exec_ext in '' $ac_executable_extensions; do
89881  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
89882    ac_cv_prog_ac_ct_STRIP="strip"
89883    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
89884    break 2
89885  fi
89886done
89887  done
89888IFS=$as_save_IFS
89889
89890fi
89891fi
89892ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
89893if test -n "$ac_ct_STRIP"; then
89894  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
89895printf "%s\n" "$ac_ct_STRIP" >&6; }
89896else
89897  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
89898printf "%s\n" "no" >&6; }
89899fi
89900
89901  if test "x$ac_ct_STRIP" = x; then
89902    STRIP=":"
89903  else
89904    case $cross_compiling:$ac_tool_warned in
89905yes:)
89906{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
89907printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
89908ac_tool_warned=yes ;;
89909esac
89910    STRIP=$ac_ct_STRIP
89911  fi
89912else
89913  STRIP="$ac_cv_prog_STRIP"
89914fi
89915
89916
89917old_CC="$CC"
89918old_CFLAGS="$CFLAGS"
89919
89920# Set sane defaults for various variables
89921test -z "$AR" && AR=ar
89922test -z "$AR_FLAGS" && AR_FLAGS=cru
89923test -z "$AS" && AS=as
89924test -z "$CC" && CC=cc
89925test -z "$LTCC" && LTCC=$CC
89926test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
89927test -z "$DLLTOOL" && DLLTOOL=dlltool
89928test -z "$LD" && LD=ld
89929test -z "$LN_S" && LN_S="ln -s"
89930test -z "$MAGIC_CMD" && MAGIC_CMD=file
89931test -z "$NM" && NM=nm
89932test -z "$SED" && SED=sed
89933test -z "$OBJDUMP" && OBJDUMP=objdump
89934test -z "$RANLIB" && RANLIB=:
89935test -z "$STRIP" && STRIP=:
89936test -z "$ac_objext" && ac_objext=o
89937
89938# Determine commands to create old-style static archives.
89939old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
89940old_postinstall_cmds='chmod 644 $oldlib'
89941old_postuninstall_cmds=
89942
89943if test -n "$RANLIB"; then
89944  case $host_os in
89945  openbsd*)
89946    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
89947    ;;
89948  *)
89949    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
89950    ;;
89951  esac
89952  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
89953fi
89954
89955for cc_temp in $compiler""; do
89956  case $cc_temp in
89957    compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
89958    distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
89959    \-*) ;;
89960    *) break;;
89961  esac
89962done
89963cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
89964
89965
89966# Only perform the check for file, if the check method requires it
89967case $deplibs_check_method in
89968file_magic*)
89969  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
89970    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
89971printf %s "checking for ${ac_tool_prefix}file... " >&6; }
89972if test ${lt_cv_path_MAGIC_CMD+y}
89973then :
89974  printf %s "(cached) " >&6
89975else $as_nop
89976  case $MAGIC_CMD in
89977[\\/*] |  ?:[\\/]*)
89978  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
89979  ;;
89980*)
89981  lt_save_MAGIC_CMD="$MAGIC_CMD"
89982  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
89983  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
89984  for ac_dir in $ac_dummy; do
89985    IFS="$lt_save_ifs"
89986    test -z "$ac_dir" && ac_dir=.
89987    if test -f $ac_dir/${ac_tool_prefix}file; then
89988      lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
89989      if test -n "$file_magic_test_file"; then
89990	case $deplibs_check_method in
89991	"file_magic "*)
89992	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
89993	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
89994	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
89995	    $EGREP "$file_magic_regex" > /dev/null; then
89996	    :
89997	  else
89998	    cat <<EOF 1>&2
89999
90000*** Warning: the command libtool uses to detect shared libraries,
90001*** $file_magic_cmd, produces output that libtool cannot recognize.
90002*** The result is that libtool may fail to recognize shared libraries
90003*** as such.  This will affect the creation of libtool libraries that
90004*** depend on shared libraries, but programs linked with such libtool
90005*** libraries will work regardless of this problem.  Nevertheless, you
90006*** may want to report the problem to your system manager and/or to
90007*** bug-libtool@gnu.org
90008
90009EOF
90010	  fi ;;
90011	esac
90012      fi
90013      break
90014    fi
90015  done
90016  IFS="$lt_save_ifs"
90017  MAGIC_CMD="$lt_save_MAGIC_CMD"
90018  ;;
90019esac
90020fi
90021
90022MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
90023if test -n "$MAGIC_CMD"; then
90024  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
90025printf "%s\n" "$MAGIC_CMD" >&6; }
90026else
90027  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90028printf "%s\n" "no" >&6; }
90029fi
90030
90031if test -z "$lt_cv_path_MAGIC_CMD"; then
90032  if test -n "$ac_tool_prefix"; then
90033    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for file" >&5
90034printf %s "checking for file... " >&6; }
90035if test ${lt_cv_path_MAGIC_CMD+y}
90036then :
90037  printf %s "(cached) " >&6
90038else $as_nop
90039  case $MAGIC_CMD in
90040[\\/*] |  ?:[\\/]*)
90041  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
90042  ;;
90043*)
90044  lt_save_MAGIC_CMD="$MAGIC_CMD"
90045  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
90046  ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
90047  for ac_dir in $ac_dummy; do
90048    IFS="$lt_save_ifs"
90049    test -z "$ac_dir" && ac_dir=.
90050    if test -f $ac_dir/file; then
90051      lt_cv_path_MAGIC_CMD="$ac_dir/file"
90052      if test -n "$file_magic_test_file"; then
90053	case $deplibs_check_method in
90054	"file_magic "*)
90055	  file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
90056	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
90057	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
90058	    $EGREP "$file_magic_regex" > /dev/null; then
90059	    :
90060	  else
90061	    cat <<EOF 1>&2
90062
90063*** Warning: the command libtool uses to detect shared libraries,
90064*** $file_magic_cmd, produces output that libtool cannot recognize.
90065*** The result is that libtool may fail to recognize shared libraries
90066*** as such.  This will affect the creation of libtool libraries that
90067*** depend on shared libraries, but programs linked with such libtool
90068*** libraries will work regardless of this problem.  Nevertheless, you
90069*** may want to report the problem to your system manager and/or to
90070*** bug-libtool@gnu.org
90071
90072EOF
90073	  fi ;;
90074	esac
90075      fi
90076      break
90077    fi
90078  done
90079  IFS="$lt_save_ifs"
90080  MAGIC_CMD="$lt_save_MAGIC_CMD"
90081  ;;
90082esac
90083fi
90084
90085MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
90086if test -n "$MAGIC_CMD"; then
90087  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
90088printf "%s\n" "$MAGIC_CMD" >&6; }
90089else
90090  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90091printf "%s\n" "no" >&6; }
90092fi
90093
90094  else
90095    MAGIC_CMD=:
90096  fi
90097fi
90098
90099  fi
90100  ;;
90101esac
90102
90103
90104  case $host_os in
90105    rhapsody* | darwin*)
90106    if test -n "$ac_tool_prefix"; then
90107  # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
90108set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
90109{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
90110printf %s "checking for $ac_word... " >&6; }
90111if test ${ac_cv_prog_DSYMUTIL+y}
90112then :
90113  printf %s "(cached) " >&6
90114else $as_nop
90115  if test -n "$DSYMUTIL"; then
90116  ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
90117else
90118as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
90119for as_dir in $PATH
90120do
90121  IFS=$as_save_IFS
90122  case $as_dir in #(((
90123    '') as_dir=./ ;;
90124    */) ;;
90125    *) as_dir=$as_dir/ ;;
90126  esac
90127    for ac_exec_ext in '' $ac_executable_extensions; do
90128  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
90129    ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
90130    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
90131    break 2
90132  fi
90133done
90134  done
90135IFS=$as_save_IFS
90136
90137fi
90138fi
90139DSYMUTIL=$ac_cv_prog_DSYMUTIL
90140if test -n "$DSYMUTIL"; then
90141  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
90142printf "%s\n" "$DSYMUTIL" >&6; }
90143else
90144  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90145printf "%s\n" "no" >&6; }
90146fi
90147
90148
90149fi
90150if test -z "$ac_cv_prog_DSYMUTIL"; then
90151  ac_ct_DSYMUTIL=$DSYMUTIL
90152  # Extract the first word of "dsymutil", so it can be a program name with args.
90153set dummy dsymutil; ac_word=$2
90154{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
90155printf %s "checking for $ac_word... " >&6; }
90156if test ${ac_cv_prog_ac_ct_DSYMUTIL+y}
90157then :
90158  printf %s "(cached) " >&6
90159else $as_nop
90160  if test -n "$ac_ct_DSYMUTIL"; then
90161  ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
90162else
90163as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
90164for as_dir in $PATH
90165do
90166  IFS=$as_save_IFS
90167  case $as_dir in #(((
90168    '') as_dir=./ ;;
90169    */) ;;
90170    *) as_dir=$as_dir/ ;;
90171  esac
90172    for ac_exec_ext in '' $ac_executable_extensions; do
90173  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
90174    ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
90175    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
90176    break 2
90177  fi
90178done
90179  done
90180IFS=$as_save_IFS
90181
90182fi
90183fi
90184ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
90185if test -n "$ac_ct_DSYMUTIL"; then
90186  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
90187printf "%s\n" "$ac_ct_DSYMUTIL" >&6; }
90188else
90189  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90190printf "%s\n" "no" >&6; }
90191fi
90192
90193  if test "x$ac_ct_DSYMUTIL" = x; then
90194    DSYMUTIL=":"
90195  else
90196    case $cross_compiling:$ac_tool_warned in
90197yes:)
90198{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
90199printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
90200ac_tool_warned=yes ;;
90201esac
90202    DSYMUTIL=$ac_ct_DSYMUTIL
90203  fi
90204else
90205  DSYMUTIL="$ac_cv_prog_DSYMUTIL"
90206fi
90207
90208    if test -n "$ac_tool_prefix"; then
90209  # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
90210set dummy ${ac_tool_prefix}nmedit; ac_word=$2
90211{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
90212printf %s "checking for $ac_word... " >&6; }
90213if test ${ac_cv_prog_NMEDIT+y}
90214then :
90215  printf %s "(cached) " >&6
90216else $as_nop
90217  if test -n "$NMEDIT"; then
90218  ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
90219else
90220as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
90221for as_dir in $PATH
90222do
90223  IFS=$as_save_IFS
90224  case $as_dir in #(((
90225    '') as_dir=./ ;;
90226    */) ;;
90227    *) as_dir=$as_dir/ ;;
90228  esac
90229    for ac_exec_ext in '' $ac_executable_extensions; do
90230  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
90231    ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
90232    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
90233    break 2
90234  fi
90235done
90236  done
90237IFS=$as_save_IFS
90238
90239fi
90240fi
90241NMEDIT=$ac_cv_prog_NMEDIT
90242if test -n "$NMEDIT"; then
90243  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
90244printf "%s\n" "$NMEDIT" >&6; }
90245else
90246  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90247printf "%s\n" "no" >&6; }
90248fi
90249
90250
90251fi
90252if test -z "$ac_cv_prog_NMEDIT"; then
90253  ac_ct_NMEDIT=$NMEDIT
90254  # Extract the first word of "nmedit", so it can be a program name with args.
90255set dummy nmedit; ac_word=$2
90256{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
90257printf %s "checking for $ac_word... " >&6; }
90258if test ${ac_cv_prog_ac_ct_NMEDIT+y}
90259then :
90260  printf %s "(cached) " >&6
90261else $as_nop
90262  if test -n "$ac_ct_NMEDIT"; then
90263  ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
90264else
90265as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
90266for as_dir in $PATH
90267do
90268  IFS=$as_save_IFS
90269  case $as_dir in #(((
90270    '') as_dir=./ ;;
90271    */) ;;
90272    *) as_dir=$as_dir/ ;;
90273  esac
90274    for ac_exec_ext in '' $ac_executable_extensions; do
90275  if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
90276    ac_cv_prog_ac_ct_NMEDIT="nmedit"
90277    printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
90278    break 2
90279  fi
90280done
90281  done
90282IFS=$as_save_IFS
90283
90284fi
90285fi
90286ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
90287if test -n "$ac_ct_NMEDIT"; then
90288  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
90289printf "%s\n" "$ac_ct_NMEDIT" >&6; }
90290else
90291  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
90292printf "%s\n" "no" >&6; }
90293fi
90294
90295  if test "x$ac_ct_NMEDIT" = x; then
90296    NMEDIT=":"
90297  else
90298    case $cross_compiling:$ac_tool_warned in
90299yes:)
90300{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
90301printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
90302ac_tool_warned=yes ;;
90303esac
90304    NMEDIT=$ac_ct_NMEDIT
90305  fi
90306else
90307  NMEDIT="$ac_cv_prog_NMEDIT"
90308fi
90309
90310
90311    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
90312printf %s "checking for -single_module linker flag... " >&6; }
90313if test ${lt_cv_apple_cc_single_mod+y}
90314then :
90315  printf %s "(cached) " >&6
90316else $as_nop
90317  lt_cv_apple_cc_single_mod=no
90318      if test -z "${LT_MULTI_MODULE}"; then
90319   # By default we will add the -single_module flag. You can override
90320   # by either setting the environment variable LT_MULTI_MODULE
90321   # non-empty at configure time, or by adding -multi_module to the
90322   # link flags.
90323   echo "int foo(void){return 1;}" > conftest.c
90324   $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
90325     -dynamiclib ${wl}-single_module conftest.c
90326   if test -f libconftest.dylib; then
90327     lt_cv_apple_cc_single_mod=yes
90328     rm -rf libconftest.dylib*
90329   fi
90330   rm conftest.c
90331      fi
90332fi
90333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
90334printf "%s\n" "$lt_cv_apple_cc_single_mod" >&6; }
90335    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
90336printf %s "checking for -exported_symbols_list linker flag... " >&6; }
90337if test ${lt_cv_ld_exported_symbols_list+y}
90338then :
90339  printf %s "(cached) " >&6
90340else $as_nop
90341  lt_cv_ld_exported_symbols_list=no
90342      save_LDFLAGS=$LDFLAGS
90343      echo "_main" > conftest.sym
90344      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
90345
90346cat > conftest.$ac_ext <<EOF
90347#line 90347 "configure"
90348#include "confdefs.h"
90349int main() {
90350; return 0; }
90351EOF
90352if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
90353  (eval $ac_link) 2>&5
90354  ac_status=$?
90355  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
90356  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
90357 lt_cv_ld_exported_symbols_list=yes
90358  rm -rf conftest*
90359else
90360  echo "configure: failed program was:" >&5
90361  cat conftest.$ac_ext >&6
90362lt_cv_ld_exported_symbols_list=no
90363  rm -rf conftest*
90364fi
90365rm -f conftest*
90366   LDFLAGS="$save_LDFLAGS"
90367
90368fi
90369{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
90370printf "%s\n" "$lt_cv_ld_exported_symbols_list" >&6; }
90371    case $host_os in
90372    rhapsody* | darwin1.[0123])
90373      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
90374    darwin1.*)
90375     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
90376    darwin*)
90377      # if running on 10.5 or later, the deployment target defaults
90378      # to the OS version, if on x86, and 10.4, the deployment
90379      # target defaults to 10.4. Don't you love it?
90380      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
90381   10.0,*86*-darwin8*|10.0,*-darwin[91]*)
90382     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
90383   10.[012]*)
90384     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
90385   *)
90386     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
90387      esac
90388    ;;
90389  esac
90390    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
90391      _lt_dar_single_mod='$single_module'
90392    fi
90393    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
90394      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
90395    else
90396      _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
90397    fi
90398    if test "$DSYMUTIL" != ":"; then
90399      _lt_dsymutil="~$DSYMUTIL \$lib || :"
90400    else
90401      _lt_dsymutil=
90402    fi
90403    ;;
90404  esac
90405
90406
90407enable_dlopen=no
90408enable_win32_dll=no
90409
90410# Check whether --enable-libtool-lock was given.
90411if test ${enable_libtool_lock+y}
90412then :
90413  enableval=$enable_libtool_lock;
90414fi
90415
90416test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
90417
90418
90419# Check whether --with-pic was given.
90420if test ${with_pic+y}
90421then :
90422  withval=$with_pic; pic_mode="$withval"
90423else $as_nop
90424  pic_mode=default
90425fi
90426
90427test -z "$pic_mode" && pic_mode=default
90428
90429# Use C for the default configuration in the libtool script
90430tagname=
90431lt_save_CC="$CC"
90432
90433ac_ext=c
90434ac_cpp='$CPP $CPPFLAGS'
90435ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
90436ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
90437ac_compiler_gnu=$ac_cv_c_compiler_gnu
90438
90439
90440# Source file extension for C test sources.
90441ac_ext=c
90442
90443# Object file extension for compiled C test sources.
90444objext=o
90445objext=$objext
90446
90447# Code to be used in simple compile tests
90448lt_simple_compile_test_code="int some_variable = 0;"
90449
90450# Code to be used in simple link tests
90451lt_simple_link_test_code='int main(){return(0);}'
90452
90453
90454# If no C compiler was specified, use CC.
90455LTCC=${LTCC-"$CC"}
90456
90457# If no C compiler flags were specified, use CFLAGS.
90458LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
90459
90460# Allow CC to be a program name with arguments.
90461compiler=$CC
90462
90463
90464# save warnings/boilerplate of simple test code
90465ac_outfile=conftest.$ac_objext
90466echo "$lt_simple_compile_test_code" >conftest.$ac_ext
90467eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
90468_lt_compiler_boilerplate=`cat conftest.err`
90469$rm conftest*
90470
90471ac_outfile=conftest.$ac_objext
90472echo "$lt_simple_link_test_code" >conftest.$ac_ext
90473eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
90474_lt_linker_boilerplate=`cat conftest.err`
90475$rm -r conftest*
90476
90477
90478## CAVEAT EMPTOR:
90479## There is no encapsulation within the following macros, do not change
90480## the running order or otherwise move them around unless you know exactly
90481## what you are doing...
90482
90483lt_prog_compiler_no_builtin_flag=
90484
90485if test "$GCC" = yes; then
90486  lt_prog_compiler_no_builtin_flag=' -fno-builtin'
90487
90488
90489{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
90490printf %s "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
90491if test ${lt_cv_prog_compiler_rtti_exceptions+y}
90492then :
90493  printf %s "(cached) " >&6
90494else $as_nop
90495  lt_cv_prog_compiler_rtti_exceptions=no
90496  ac_outfile=conftest.$ac_objext
90497   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
90498   lt_compiler_flag="-fno-rtti -fno-exceptions"
90499   # Insert the option either (1) after the last *FLAGS variable, or
90500   # (2) before a word containing "conftest.", or (3) at the end.
90501   # Note that $ac_compile itself does not contain backslashes and begins
90502   # with a dollar sign (not a hyphen), so the echo should work correctly.
90503   # The option is referenced via a variable to avoid confusing sed.
90504   lt_compile=`echo "$ac_compile" | $SED \
90505   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
90506   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
90507   -e 's:$: $lt_compiler_flag:'`
90508   (eval echo "\"configure:90508: $lt_compile\"" >&5)
90509   (eval "$lt_compile" 2>conftest.err)
90510   ac_status=$?
90511   cat conftest.err >&5
90512   echo "configure:90512: \$? = $ac_status" >&5
90513   if (exit $ac_status) && test -s "$ac_outfile"; then
90514     # The compiler can only warn and ignore the option if not recognized
90515     # So say no if there are warnings other than the usual output.
90516     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
90517     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
90518     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
90519       lt_cv_prog_compiler_rtti_exceptions=yes
90520     fi
90521   fi
90522   $rm conftest*
90523
90524fi
90525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
90526printf "%s\n" "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
90527
90528if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
90529    lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
90530else
90531    :
90532fi
90533
90534fi
90535
90536lt_prog_compiler_wl=
90537lt_prog_compiler_pic=
90538lt_prog_compiler_static=
90539
90540{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
90541printf %s "checking for $compiler option to produce PIC... " >&6; }
90542
90543  if test "$GCC" = yes; then
90544    lt_prog_compiler_wl='-Wl,'
90545    lt_prog_compiler_static='-static'
90546
90547    case $host_os in
90548      aix*)
90549      # All AIX code is PIC.
90550      if test "$host_cpu" = ia64; then
90551	# AIX 5 now supports IA64 processor
90552	lt_prog_compiler_static='-Bstatic'
90553      fi
90554      ;;
90555
90556    amigaos*)
90557      # FIXME: we need at least 68020 code to build shared libraries, but
90558      # adding the `-m68020' flag to GCC prevents building anything better,
90559      # like `-m68040'.
90560      lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
90561      ;;
90562
90563    beos* | haiku* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
90564      # PIC is the default for these OSes.
90565      ;;
90566
90567    mingw* | cygwin* | pw32* | os2*)
90568      # This hack is so that the source file can tell whether it is being
90569      # built for inclusion in a dll (and should export symbols for example).
90570      # Although the cygwin gcc ignores -fPIC, still need this for old-style
90571      # (--disable-auto-import) libraries
90572	  lt_prog_compiler_pic='-DDLL_EXPORT'
90573      ;;
90574
90575    darwin* | rhapsody*)
90576      # PIC is the default on this platform
90577      # Common symbols not allowed in MH_DYLIB files
90578      lt_prog_compiler_pic='-fno-common'
90579      ;;
90580
90581    interix[3-9]*)
90582      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
90583      # Instead, we relocate shared libraries at runtime.
90584      ;;
90585
90586    msdosdjgpp*)
90587      # Just because we use GCC doesn't mean we suddenly get shared libraries
90588      # on systems that don't support them.
90589      lt_prog_compiler_can_build_shared=no
90590      enable_shared=no
90591      ;;
90592
90593    sysv4*MP*)
90594      if test -d /usr/nec; then
90595	lt_prog_compiler_pic=-Kconform_pic
90596      fi
90597      ;;
90598
90599    hpux*)
90600      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
90601      # not for PA HP-UX.
90602      case $host_cpu in
90603      hppa*64*|ia64*)
90604	# +Z the default
90605	;;
90606      *)
90607	lt_prog_compiler_pic='-fPIC'
90608	;;
90609      esac
90610      ;;
90611
90612    *)
90613      lt_prog_compiler_pic='-fPIC'
90614      ;;
90615    esac
90616  else
90617    # PORTME Check for flag to pass linker flags through the system compiler.
90618    case $host_os in
90619    aix*)
90620      lt_prog_compiler_wl='-Wl,'
90621      if test "$host_cpu" = ia64; then
90622	# AIX 5 now supports IA64 processor
90623	lt_prog_compiler_static='-Bstatic'
90624      else
90625	lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
90626      fi
90627      ;;
90628      darwin*)
90629        # PIC is the default on this platform
90630        # Common symbols not allowed in MH_DYLIB files
90631       case $cc_basename in
90632         xlc*)
90633         lt_prog_compiler_pic='-qnocommon'
90634         lt_prog_compiler_wl='-Wl,'
90635         ;;
90636       esac
90637       ;;
90638
90639    mingw* | cygwin* | pw32* | os2*)
90640      # This hack is so that the source file can tell whether it is being
90641      # built for inclusion in a dll (and should export symbols for example).
90642	  lt_prog_compiler_pic='-DDLL_EXPORT'
90643      ;;
90644
90645    hpux9* | hpux10* | hpux11*)
90646      lt_prog_compiler_wl='-Wl,'
90647      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
90648      # not for PA HP-UX.
90649      case $host_cpu in
90650      hppa*64*|ia64*)
90651	# +Z the default
90652	;;
90653      *)
90654	lt_prog_compiler_pic='+Z'
90655	;;
90656      esac
90657      # Is there a better lt_prog_compiler_static that works with the bundled CC?
90658      lt_prog_compiler_static='${wl}-a ${wl}archive'
90659      ;;
90660
90661    irix5* | irix6* | nonstopux*)
90662      lt_prog_compiler_wl='-Wl,'
90663      # PIC (with -KPIC) is the default.
90664      lt_prog_compiler_static='-non_shared'
90665      ;;
90666
90667    newsos6)
90668      lt_prog_compiler_pic='-KPIC'
90669      lt_prog_compiler_static='-Bstatic'
90670      ;;
90671
90672    linux* | k*bsd*-gnu)
90673      case $cc_basename in
90674      # old Intel for x86_64 which still supported -KPIC.
90675      ecc*)
90676        lt_prog_compiler_wl='-Wl,'
90677        lt_prog_compiler_pic='-KPIC'
90678        lt_prog_compiler_static='-static'
90679        ;;
90680      # icc used to be incompatible with GCC.
90681      # ICC 10 doesn't accept -KPIC any more.
90682      icc*)
90683        lt_prog_compiler_wl='-Wl,'
90684        lt_prog_compiler_pic='-fPIC'
90685        lt_prog_compiler_static='-static'
90686        ;;
90687      pgcc* | pgf77* | pgf90* | pgf95*)
90688        # Portland Group compilers (*not* the Pentium gcc compiler,
90689	# which looks to be a dead project)
90690	lt_prog_compiler_wl='-Wl,'
90691	lt_prog_compiler_pic='-fpic'
90692	lt_prog_compiler_static='-Bstatic'
90693        ;;
90694      ccc*)
90695        lt_prog_compiler_wl='-Wl,'
90696        # All Alpha code is PIC.
90697        lt_prog_compiler_static='-non_shared'
90698        ;;
90699      *)
90700        case `$CC -V 2>&1 | sed 5q` in
90701	*Sun\ C*)
90702	  # Sun C 5.9
90703	  lt_prog_compiler_pic='-KPIC'
90704	  lt_prog_compiler_static='-Bstatic'
90705	  lt_prog_compiler_wl='-Wl,'
90706	  ;;
90707	*Sun\ F*)
90708	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
90709	  lt_prog_compiler_pic='-KPIC'
90710	  lt_prog_compiler_static='-Bstatic'
90711	  lt_prog_compiler_wl=''
90712	  ;;
90713	esac
90714	;;
90715      esac
90716      ;;
90717
90718    osf3* | osf4* | osf5*)
90719      lt_prog_compiler_wl='-Wl,'
90720      # All OSF/1 code is PIC.
90721      lt_prog_compiler_static='-non_shared'
90722      ;;
90723
90724    rdos*)
90725      lt_prog_compiler_static='-non_shared'
90726      ;;
90727
90728    solaris*)
90729      lt_prog_compiler_pic='-KPIC'
90730      lt_prog_compiler_static='-Bstatic'
90731      case $cc_basename in
90732      f77* | f90* | f95*)
90733	lt_prog_compiler_wl='-Qoption ld ';;
90734      *)
90735	lt_prog_compiler_wl='-Wl,';;
90736      esac
90737      ;;
90738
90739    sunos4*)
90740      lt_prog_compiler_wl='-Qoption ld '
90741      lt_prog_compiler_pic='-PIC'
90742      lt_prog_compiler_static='-Bstatic'
90743      ;;
90744
90745    sysv4 | sysv4.2uw2* | sysv4.3*)
90746      lt_prog_compiler_wl='-Wl,'
90747      lt_prog_compiler_pic='-KPIC'
90748      lt_prog_compiler_static='-Bstatic'
90749      ;;
90750
90751    sysv4*MP*)
90752      if test -d /usr/nec ;then
90753	lt_prog_compiler_pic='-Kconform_pic'
90754	lt_prog_compiler_static='-Bstatic'
90755      fi
90756      ;;
90757
90758    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
90759      lt_prog_compiler_wl='-Wl,'
90760      lt_prog_compiler_pic='-KPIC'
90761      lt_prog_compiler_static='-Bstatic'
90762      ;;
90763
90764    unicos*)
90765      lt_prog_compiler_wl='-Wl,'
90766      lt_prog_compiler_can_build_shared=no
90767      ;;
90768
90769    uts4*)
90770      lt_prog_compiler_pic='-pic'
90771      lt_prog_compiler_static='-Bstatic'
90772      ;;
90773
90774    *)
90775      lt_prog_compiler_can_build_shared=no
90776      ;;
90777    esac
90778  fi
90779
90780{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
90781printf "%s\n" "$lt_prog_compiler_pic" >&6; }
90782
90783#
90784# Check to make sure the PIC flag actually works.
90785#
90786if test -n "$lt_prog_compiler_pic"; then
90787
90788{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
90789printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
90790if test ${lt_cv_prog_compiler_pic_works+y}
90791then :
90792  printf %s "(cached) " >&6
90793else $as_nop
90794  lt_cv_prog_compiler_pic_works=no
90795  ac_outfile=conftest.$ac_objext
90796   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
90797   lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
90798   # Insert the option either (1) after the last *FLAGS variable, or
90799   # (2) before a word containing "conftest.", or (3) at the end.
90800   # Note that $ac_compile itself does not contain backslashes and begins
90801   # with a dollar sign (not a hyphen), so the echo should work correctly.
90802   # The option is referenced via a variable to avoid confusing sed.
90803   lt_compile=`echo "$ac_compile" | $SED \
90804   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
90805   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
90806   -e 's:$: $lt_compiler_flag:'`
90807   (eval echo "\"configure:90807: $lt_compile\"" >&5)
90808   (eval "$lt_compile" 2>conftest.err)
90809   ac_status=$?
90810   cat conftest.err >&5
90811   echo "configure:90811: \$? = $ac_status" >&5
90812   if (exit $ac_status) && test -s "$ac_outfile"; then
90813     # The compiler can only warn and ignore the option if not recognized
90814     # So say no if there are warnings other than the usual output.
90815     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
90816     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
90817     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
90818       lt_cv_prog_compiler_pic_works=yes
90819     fi
90820   fi
90821   $rm conftest*
90822
90823fi
90824{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
90825printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; }
90826
90827if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
90828    case $lt_prog_compiler_pic in
90829     "" | " "*) ;;
90830     *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
90831     esac
90832else
90833    lt_prog_compiler_pic=
90834     lt_prog_compiler_can_build_shared=no
90835fi
90836
90837fi
90838case $host_os in
90839  # For platforms which do not support PIC, -DPIC is meaningless:
90840  *djgpp*)
90841    lt_prog_compiler_pic=
90842    ;;
90843  *)
90844    lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
90845    ;;
90846esac
90847
90848#
90849# Check to make sure the static flag actually works.
90850#
90851wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
90852{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
90853printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
90854if test ${lt_cv_prog_compiler_static_works+y}
90855then :
90856  printf %s "(cached) " >&6
90857else $as_nop
90858  lt_cv_prog_compiler_static_works=no
90859   save_LDFLAGS="$LDFLAGS"
90860   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
90861   echo "$lt_simple_link_test_code" > conftest.$ac_ext
90862   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
90863     # The linker can only warn and ignore the option if not recognized
90864     # So say no if there are warnings
90865     if test -s conftest.err; then
90866       # Append any errors to the config.log.
90867       cat conftest.err 1>&5
90868       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
90869       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
90870       if diff conftest.exp conftest.er2 >/dev/null; then
90871         lt_cv_prog_compiler_static_works=yes
90872       fi
90873     else
90874       lt_cv_prog_compiler_static_works=yes
90875     fi
90876   fi
90877   $rm -r conftest*
90878   LDFLAGS="$save_LDFLAGS"
90879
90880fi
90881{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
90882printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; }
90883
90884if test x"$lt_cv_prog_compiler_static_works" = xyes; then
90885    :
90886else
90887    lt_prog_compiler_static=
90888fi
90889
90890
90891{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
90892printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
90893if test ${lt_cv_prog_compiler_c_o+y}
90894then :
90895  printf %s "(cached) " >&6
90896else $as_nop
90897  lt_cv_prog_compiler_c_o=no
90898   $rm -r conftest 2>/dev/null
90899   mkdir conftest
90900   cd conftest
90901   mkdir out
90902   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
90903
90904   lt_compiler_flag="-o out/conftest2.$ac_objext"
90905   # Insert the option either (1) after the last *FLAGS variable, or
90906   # (2) before a word containing "conftest.", or (3) at the end.
90907   # Note that $ac_compile itself does not contain backslashes and begins
90908   # with a dollar sign (not a hyphen), so the echo should work correctly.
90909   lt_compile=`echo "$ac_compile" | $SED \
90910   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
90911   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
90912   -e 's:$: $lt_compiler_flag:'`
90913   (eval echo "\"configure:90913: $lt_compile\"" >&5)
90914   (eval "$lt_compile" 2>out/conftest.err)
90915   ac_status=$?
90916   cat out/conftest.err >&5
90917   echo "configure:90917: \$? = $ac_status" >&5
90918   if (exit $ac_status) && test -s out/conftest2.$ac_objext
90919   then
90920     # The compiler can only warn and ignore the option if not recognized
90921     # So say no if there are warnings
90922     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
90923     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
90924     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
90925       lt_cv_prog_compiler_c_o=yes
90926     fi
90927   fi
90928   chmod u+w . 2>&5
90929   $rm conftest*
90930   # SGI C++ compiler will create directory out/ii_files/ for
90931   # template instantiation
90932   test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
90933   $rm out/* && rmdir out
90934   cd ..
90935   rmdir conftest
90936   $rm conftest*
90937
90938fi
90939{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
90940printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; }
90941
90942
90943hard_links="nottested"
90944if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
90945  # do not overwrite the value of need_locks provided by the user
90946  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
90947printf %s "checking if we can lock with hard links... " >&6; }
90948  hard_links=yes
90949  $rm conftest*
90950  ln conftest.a conftest.b 2>/dev/null && hard_links=no
90951  touch conftest.a
90952  ln conftest.a conftest.b 2>&5 || hard_links=no
90953  ln conftest.a conftest.b 2>/dev/null && hard_links=no
90954  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
90955printf "%s\n" "$hard_links" >&6; }
90956  if test "$hard_links" = no; then
90957    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
90958printf "%s\n" "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
90959    need_locks=warn
90960  fi
90961else
90962  need_locks=no
90963fi
90964
90965{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
90966printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
90967
90968  runpath_var=
90969  allow_undefined_flag=
90970  enable_shared_with_static_runtimes=no
90971  archive_cmds=
90972  archive_expsym_cmds=
90973  old_archive_From_new_cmds=
90974  old_archive_from_expsyms_cmds=
90975  export_dynamic_flag_spec=
90976  whole_archive_flag_spec=
90977  thread_safe_flag_spec=
90978  hardcode_libdir_flag_spec=
90979  hardcode_libdir_flag_spec_ld=
90980  hardcode_libdir_separator=
90981  hardcode_direct=no
90982  hardcode_minus_L=no
90983  hardcode_shlibpath_var=unsupported
90984  link_all_deplibs=unknown
90985  hardcode_automatic=no
90986  module_cmds=
90987  module_expsym_cmds=
90988  always_export_symbols=no
90989  export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
90990  # include_expsyms should be a list of space-separated symbols to be *always*
90991  # included in the symbol list
90992  include_expsyms=
90993  # exclude_expsyms can be an extended regexp of symbols to exclude
90994  # it will be wrapped by ` (' and `)$', so one must not match beginning or
90995  # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
90996  # as well as any symbol that contains `d'.
90997  exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
90998  # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
90999  # platforms (ab)use it in PIC code, but their linkers get confused if
91000  # the symbol is explicitly referenced.  Since portable code cannot
91001  # rely on this symbol name, it's probably fine to never include it in
91002  # preloaded symbol tables.
91003  # Exclude shared library initialization/finalization symbols.
91004  extract_expsyms_cmds=
91005  # Just being paranoid about ensuring that cc_basename is set.
91006  for cc_temp in $compiler""; do
91007  case $cc_temp in
91008    compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
91009    distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
91010    \-*) ;;
91011    *) break;;
91012  esac
91013done
91014cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
91015
91016  case $host_os in
91017  cygwin* | mingw* | pw32*)
91018    # FIXME: the MSVC++ port hasn't been tested in a loooong time
91019    # When not using gcc, we currently assume that we are using
91020    # Microsoft Visual C++.
91021    if test "$GCC" != yes; then
91022      with_gnu_ld=no
91023    fi
91024    ;;
91025  interix*)
91026    # we just hope/assume this is gcc and not c89 (= MSVC++)
91027    with_gnu_ld=yes
91028    ;;
91029  openbsd*)
91030    with_gnu_ld=no
91031    ;;
91032  esac
91033
91034  ld_shlibs=yes
91035  if test "$with_gnu_ld" = yes; then
91036    # If archive_cmds runs LD, not CC, wlarc should be empty
91037    wlarc='${wl}'
91038
91039    # Set some defaults for GNU ld with shared library support. These
91040    # are reset later if shared libraries are not supported. Putting them
91041    # here allows them to be overridden if necessary.
91042    runpath_var=LD_RUN_PATH
91043    hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
91044    export_dynamic_flag_spec='${wl}--export-dynamic'
91045    # ancient GNU ld didn't support --whole-archive et. al.
91046    if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
91047	whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
91048      else
91049  	whole_archive_flag_spec=
91050    fi
91051    supports_anon_versioning=no
91052    case `$LD -v 2>/dev/null` in
91053      *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
91054      *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
91055      *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
91056      *\ 2.11.*) ;; # other 2.11 versions
91057      *) supports_anon_versioning=yes ;;
91058    esac
91059
91060    # See if GNU ld supports shared libraries.
91061    case $host_os in
91062    aix[3-9]*)
91063      # On AIX/PPC, the GNU linker is very broken
91064      if test "$host_cpu" != ia64; then
91065	ld_shlibs=no
91066	cat <<EOF 1>&2
91067
91068*** Warning: the GNU linker, at least up to release 2.9.1, is reported
91069*** to be unable to reliably create shared libraries on AIX.
91070*** Therefore, libtool is disabling shared libraries support.  If you
91071*** really care for shared libraries, you may want to modify your PATH
91072*** so that a non-GNU linker is found, and then restart.
91073
91074EOF
91075      fi
91076      ;;
91077
91078    amigaos*)
91079      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)'
91080      hardcode_libdir_flag_spec='-L$libdir'
91081      hardcode_minus_L=yes
91082
91083      # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
91084      # that the semantics of dynamic libraries on AmigaOS, at least up
91085      # to version 4, is to share data among multiple programs linked
91086      # with the same dynamic library.  Since this doesn't match the
91087      # behavior of shared libraries on other platforms, we can't use
91088      # them.
91089      ld_shlibs=no
91090      ;;
91091
91092    beos*)
91093      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
91094	allow_undefined_flag=unsupported
91095	# Joseph Beckenbach <jrb3@best.com> says some releases of gcc
91096	# support --undefined.  This deserves some investigation.  FIXME
91097	archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
91098      else
91099	ld_shlibs=no
91100      fi
91101      ;;
91102
91103    cygwin* | mingw* | pw32*)
91104      # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
91105      # as there is no search path for DLLs.
91106      hardcode_libdir_flag_spec='-L$libdir'
91107      allow_undefined_flag=unsupported
91108      always_export_symbols=no
91109      enable_shared_with_static_runtimes=yes
91110      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
91111
91112      if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
91113        archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
91114	# If the export-symbols file already is a .def file (1st line
91115	# is EXPORTS), use it as is; otherwise, prepend...
91116	archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
91117	  cp $export_symbols $output_objdir/$soname.def;
91118	else
91119	  echo EXPORTS > $output_objdir/$soname.def;
91120	  cat $export_symbols >> $output_objdir/$soname.def;
91121	fi~
91122	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
91123      else
91124	ld_shlibs=no
91125      fi
91126      ;;
91127
91128    interix[3-9]*)
91129      hardcode_direct=no
91130      hardcode_shlibpath_var=no
91131      hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
91132      export_dynamic_flag_spec='${wl}-E'
91133      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
91134      # Instead, shared libraries are loaded at an image base (0x10000000 by
91135      # default) and relocated if they conflict, which is a slow very memory
91136      # consuming and fragmenting process.  To avoid this, we pick a random,
91137      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
91138      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
91139      archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
91140      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'
91141      ;;
91142
91143    gnu* | linux* | k*bsd*-gnu)
91144      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
91145	tmp_addflag=
91146	case $cc_basename,$host_cpu in
91147	pgcc*)				# Portland Group C compiler
91148	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
91149	  tmp_addflag=' $pic_flag'
91150	  ;;
91151	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
91152	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
91153	  tmp_addflag=' $pic_flag -Mnomain' ;;
91154	ecc*,ia64* | icc*,ia64*)		# Intel C compiler on ia64
91155	  tmp_addflag=' -i_dynamic' ;;
91156	efc*,ia64* | ifort*,ia64*)	# Intel Fortran compiler on ia64
91157	  tmp_addflag=' -i_dynamic -nofor_main' ;;
91158	ifc* | ifort*)			# Intel Fortran compiler
91159	  tmp_addflag=' -nofor_main' ;;
91160	esac
91161	case `$CC -V 2>&1 | sed 5q` in
91162	*Sun\ C*)			# Sun C 5.9
91163	  whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
91164	  tmp_sharedflag='-G' ;;
91165	*Sun\ F*)			# Sun Fortran 8.3
91166	  tmp_sharedflag='-G' ;;
91167	*)
91168	  tmp_sharedflag='-shared' ;;
91169	esac
91170	archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
91171
91172	if test $supports_anon_versioning = yes; then
91173	  archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
91174  cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
91175  $echo "local: *; };" >> $output_objdir/$libname.ver~
91176	  $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
91177	fi
91178      else
91179	ld_shlibs=no
91180      fi
91181      ;;
91182
91183    netbsd*)
91184      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
91185	archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
91186	wlarc=
91187      else
91188	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
91189	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
91190      fi
91191      ;;
91192
91193    solaris*)
91194      if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
91195	ld_shlibs=no
91196	cat <<EOF 1>&2
91197
91198*** Warning: The releases 2.8.* of the GNU linker cannot reliably
91199*** create shared libraries on Solaris systems.  Therefore, libtool
91200*** is disabling shared libraries support.  We urge you to upgrade GNU
91201*** binutils to release 2.9.1 or newer.  Another option is to modify
91202*** your PATH or compiler configuration so that the native linker is
91203*** used, and then restart.
91204
91205EOF
91206      elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
91207	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
91208	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
91209      else
91210	ld_shlibs=no
91211      fi
91212      ;;
91213
91214    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
91215      case `$LD -v 2>&1` in
91216        *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
91217	ld_shlibs=no
91218	cat <<_LT_EOF 1>&2
91219
91220*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
91221*** reliably create shared libraries on SCO systems.  Therefore, libtool
91222*** is disabling shared libraries support.  We urge you to upgrade GNU
91223*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
91224*** your PATH or compiler configuration so that the native linker is
91225*** used, and then restart.
91226
91227_LT_EOF
91228	;;
91229	*)
91230	  if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
91231	    hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
91232	    archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
91233	    archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
91234	  else
91235	    ld_shlibs=no
91236	  fi
91237	;;
91238      esac
91239      ;;
91240
91241    sunos4*)
91242      archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
91243      wlarc=
91244      hardcode_direct=yes
91245      hardcode_shlibpath_var=no
91246      ;;
91247
91248    *)
91249      if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
91250	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
91251	archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
91252      else
91253	ld_shlibs=no
91254      fi
91255      ;;
91256    esac
91257
91258    if test "$ld_shlibs" = no; then
91259      runpath_var=
91260      hardcode_libdir_flag_spec=
91261      export_dynamic_flag_spec=
91262      whole_archive_flag_spec=
91263    fi
91264  else
91265    # PORTME fill in a description of your system's linker (not GNU ld)
91266    case $host_os in
91267    aix3*)
91268      allow_undefined_flag=unsupported
91269      always_export_symbols=yes
91270      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'
91271      # Note: this linker hardcodes the directories in LIBPATH if there
91272      # are no directories specified by -L.
91273      hardcode_minus_L=yes
91274      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
91275	# Neither direct hardcoding nor static linking is supported with a
91276	# broken collect2.
91277	hardcode_direct=unsupported
91278      fi
91279      ;;
91280
91281    aix[4-9]*)
91282      if test "$host_cpu" = ia64; then
91283	# On IA64, the linker does run time linking by default, so we don't
91284	# have to do anything special.
91285	aix_use_runtimelinking=no
91286	exp_sym_flag='-Bexport'
91287	no_entry_flag=""
91288      else
91289	# If we're using GNU nm, then we don't want the "-C" option.
91290	# -C means demangle to AIX nm, but means don't demangle with GNU nm
91291	if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
91292	  export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
91293	else
91294	  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'
91295	fi
91296	aix_use_runtimelinking=no
91297
91298	# Test if we are trying to use run time linking or normal
91299	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
91300	# need to do runtime linking.
91301	case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
91302	  for ld_flag in $LDFLAGS; do
91303  	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
91304  	    aix_use_runtimelinking=yes
91305  	    break
91306  	  fi
91307	  done
91308	  ;;
91309	esac
91310
91311	exp_sym_flag='-bexport'
91312	no_entry_flag='-bnoentry'
91313      fi
91314
91315      # When large executables or shared objects are built, AIX ld can
91316      # have problems creating the table of contents.  If linking a library
91317      # or program results in "error TOC overflow" add -mminimal-toc to
91318      # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
91319      # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
91320
91321      archive_cmds=''
91322      hardcode_direct=yes
91323      hardcode_libdir_separator=':'
91324      link_all_deplibs=yes
91325
91326      if test "$GCC" = yes; then
91327	case $host_os in aix4.[012]|aix4.[012].*)
91328	# We only want to do this on AIX 4.2 and lower, the check
91329	# below for broken collect2 doesn't work under 4.3+
91330	  collect2name=`${CC} -print-prog-name=collect2`
91331	  if test -f "$collect2name" && \
91332  	   strings "$collect2name" | grep resolve_lib_name >/dev/null
91333	  then
91334  	  # We have reworked collect2
91335  	  :
91336	  else
91337  	  # We have old collect2
91338  	  hardcode_direct=unsupported
91339  	  # It fails to find uninstalled libraries when the uninstalled
91340  	  # path is not listed in the libpath.  Setting hardcode_minus_L
91341  	  # to unsupported forces relinking
91342  	  hardcode_minus_L=yes
91343  	  hardcode_libdir_flag_spec='-L$libdir'
91344  	  hardcode_libdir_separator=
91345	  fi
91346	  ;;
91347	esac
91348	shared_flag='-shared'
91349	if test "$aix_use_runtimelinking" = yes; then
91350	  shared_flag="$shared_flag "'${wl}-G'
91351	fi
91352      else
91353	# not using gcc
91354	if test "$host_cpu" = ia64; then
91355  	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
91356  	# chokes on -Wl,-G. The following line is correct:
91357	  shared_flag='-G'
91358	else
91359	  if test "$aix_use_runtimelinking" = yes; then
91360	    shared_flag='${wl}-G'
91361	  else
91362	    shared_flag='${wl}-bM:SRE'
91363	  fi
91364	fi
91365      fi
91366
91367      # It seems that -bexpall does not export symbols beginning with
91368      # underscore (_), so it is better to generate a list of symbols to export.
91369      always_export_symbols=yes
91370      if test "$aix_use_runtimelinking" = yes; then
91371	# Warning - without using the other runtime loading flags (-brtl),
91372	# -berok will link without error, but may produce a broken library.
91373	allow_undefined_flag='-berok'
91374       # Determine the default libpath from the value encoded in an empty executable.
91375
91376cat > conftest.$ac_ext <<EOF
91377#line 91377 "configure"
91378#include "confdefs.h"
91379int main() {
91380; return 0; }
91381EOF
91382if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
91383  (eval $ac_link) 2>&5
91384  ac_status=$?
91385  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
91386  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
91387
91388lt_aix_libpath_sed='
91389    /Import File Strings/,/^$/ {
91390	/^0/ {
91391	    s/^0  *\(.*\)$/\1/
91392	    p
91393	}
91394    }'
91395aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
91396# Check for a 64-bit object if we didn't find anything.
91397if test -z "$aix_libpath"; then
91398  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
91399fi
91400  rm -rf conftest*
91401else
91402  echo "configure: failed program was:" >&5
91403  cat conftest.$ac_ext >&6
91404fi
91405rm -f conftest*
91406if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
91407
91408       hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
91409	archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
91410       else
91411	if test "$host_cpu" = ia64; then
91412	  hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
91413	  allow_undefined_flag="-z nodefs"
91414	  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"
91415	else
91416	 # Determine the default libpath from the value encoded in an empty executable.
91417
91418cat > conftest.$ac_ext <<EOF
91419#line 91419 "configure"
91420#include "confdefs.h"
91421int main() {
91422; return 0; }
91423EOF
91424if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
91425  (eval $ac_link) 2>&5
91426  ac_status=$?
91427  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
91428  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
91429
91430lt_aix_libpath_sed='
91431    /Import File Strings/,/^$/ {
91432	/^0/ {
91433	    s/^0  *\(.*\)$/\1/
91434	    p
91435	}
91436    }'
91437aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
91438# Check for a 64-bit object if we didn't find anything.
91439if test -z "$aix_libpath"; then
91440  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
91441fi
91442  rm -rf conftest*
91443else
91444  echo "configure: failed program was:" >&5
91445  cat conftest.$ac_ext >&6
91446fi
91447rm -f conftest*
91448if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
91449
91450	 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
91451	  # Warning - without using the other run time loading flags,
91452	  # -berok will link without error, but may produce a broken library.
91453	  no_undefined_flag=' ${wl}-bernotok'
91454	  allow_undefined_flag=' ${wl}-berok'
91455	  # Exported symbols can be pulled into shared objects from archives
91456	  whole_archive_flag_spec='$convenience'
91457	  archive_cmds_need_lc=yes
91458	  # This is similar to how AIX traditionally builds its shared libraries.
91459	  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'
91460	fi
91461      fi
91462      ;;
91463
91464    amigaos*)
91465      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)'
91466      hardcode_libdir_flag_spec='-L$libdir'
91467      hardcode_minus_L=yes
91468      # see comment about different semantics on the GNU ld section
91469      ld_shlibs=no
91470      ;;
91471
91472    bsdi[45]*)
91473      export_dynamic_flag_spec=-rdynamic
91474      ;;
91475
91476    cygwin* | mingw* | pw32*)
91477      # When not using gcc, we currently assume that we are using
91478      # Microsoft Visual C++.
91479      # hardcode_libdir_flag_spec is actually meaningless, as there is
91480      # no search path for DLLs.
91481      hardcode_libdir_flag_spec=' '
91482      allow_undefined_flag=unsupported
91483      # Tell ltmain to make .lib files, not .a files.
91484      libext=lib
91485      # Tell ltmain to make .dll files, not .so files.
91486      shrext_cmds=".dll"
91487      # FIXME: Setting linknames here is a bad hack.
91488      archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
91489      # The linker will automatically build a .lib file if we build a DLL.
91490      old_archive_From_new_cmds='true'
91491      # FIXME: Should let the user specify the lib program.
91492      old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
91493      fix_srcfile_path='`cygpath -w "$srcfile"`'
91494      enable_shared_with_static_runtimes=yes
91495      ;;
91496
91497    darwin* | rhapsody*)
91498      case $host_os in
91499        rhapsody* | darwin1.[012])
91500         allow_undefined_flag='${wl}-undefined ${wl}suppress'
91501         ;;
91502       *) # Darwin 1.3 on
91503         if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
91504           allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
91505         else
91506           case ${MACOSX_DEPLOYMENT_TARGET} in
91507             10.[012])
91508               allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
91509               ;;
91510             *)
91511               allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
91512               ;;
91513           esac
91514         fi
91515         ;;
91516      esac
91517      archive_cmds_need_lc=no
91518      hardcode_direct=no
91519      hardcode_automatic=yes
91520      hardcode_shlibpath_var=unsupported
91521      whole_archive_flag_spec=''
91522      link_all_deplibs=yes
91523    if test "$GCC" = yes ; then
91524    	output_verbose_link_cmd='echo'
91525        archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
91526        module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
91527        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}"
91528        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}"
91529    else
91530      case $cc_basename in
91531        xlc*)
91532         output_verbose_link_cmd='echo'
91533         archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
91534         module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
91535          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
91536         archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
91537          module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
91538          ;;
91539       *)
91540         ld_shlibs=no
91541          ;;
91542      esac
91543    fi
91544      ;;
91545
91546    dgux*)
91547      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91548      hardcode_libdir_flag_spec='-L$libdir'
91549      hardcode_shlibpath_var=no
91550      ;;
91551
91552    # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
91553    # support.  Future versions do this automatically, but an explicit c++rt0.o
91554    # does not break anything, and helps significantly (at the cost of a little
91555    # extra space).
91556    freebsd2.2*)
91557      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
91558      hardcode_libdir_flag_spec='-R$libdir'
91559      hardcode_direct=yes
91560      hardcode_shlibpath_var=no
91561      ;;
91562
91563    # Unfortunately, older versions of FreeBSD 2 do not have this feature.
91564    freebsd2*)
91565      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
91566      hardcode_direct=yes
91567      hardcode_minus_L=yes
91568      hardcode_shlibpath_var=no
91569      ;;
91570
91571    # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
91572    freebsd* | dragonfly*)
91573      archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
91574      hardcode_libdir_flag_spec='-R$libdir'
91575      hardcode_direct=yes
91576      hardcode_shlibpath_var=no
91577      ;;
91578
91579    hpux9*)
91580      if test "$GCC" = yes; then
91581	archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
91582      else
91583	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'
91584      fi
91585      hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
91586      hardcode_libdir_separator=:
91587      hardcode_direct=yes
91588
91589      # hardcode_minus_L: Not really in the search PATH,
91590      # but as the default location of the library.
91591      hardcode_minus_L=yes
91592      export_dynamic_flag_spec='${wl}-E'
91593      ;;
91594
91595    hpux10*)
91596      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
91597	archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
91598      else
91599	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
91600      fi
91601      if test "$with_gnu_ld" = no; then
91602	hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
91603	hardcode_libdir_separator=:
91604
91605	hardcode_direct=yes
91606	export_dynamic_flag_spec='${wl}-E'
91607
91608	# hardcode_minus_L: Not really in the search PATH,
91609	# but as the default location of the library.
91610	hardcode_minus_L=yes
91611      fi
91612      ;;
91613
91614    hpux11*)
91615      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
91616	case $host_cpu in
91617	hppa*64*)
91618	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
91619	  ;;
91620	ia64*)
91621	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
91622	  ;;
91623	*)
91624	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
91625	  ;;
91626	esac
91627      else
91628	case $host_cpu in
91629	hppa*64*)
91630	  archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
91631	  ;;
91632	ia64*)
91633	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
91634	  ;;
91635	*)
91636	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
91637	  ;;
91638	esac
91639      fi
91640      if test "$with_gnu_ld" = no; then
91641	hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
91642	hardcode_libdir_separator=:
91643
91644	case $host_cpu in
91645	hppa*64*|ia64*)
91646	  hardcode_libdir_flag_spec_ld='+b $libdir'
91647	  hardcode_direct=no
91648	  hardcode_shlibpath_var=no
91649	  ;;
91650	*)
91651	  hardcode_direct=yes
91652	  export_dynamic_flag_spec='${wl}-E'
91653
91654	  # hardcode_minus_L: Not really in the search PATH,
91655	  # but as the default location of the library.
91656	  hardcode_minus_L=yes
91657	  ;;
91658	esac
91659      fi
91660      ;;
91661
91662    irix5* | irix6* | nonstopux*)
91663      if test "$GCC" = yes; then
91664	archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
91665      else
91666	archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
91667	hardcode_libdir_flag_spec_ld='-rpath $libdir'
91668      fi
91669      hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
91670      hardcode_libdir_separator=:
91671      link_all_deplibs=yes
91672      ;;
91673
91674    netbsd*)
91675      if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
91676	archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
91677      else
91678	archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
91679      fi
91680      hardcode_libdir_flag_spec='-R$libdir'
91681      hardcode_direct=yes
91682      hardcode_shlibpath_var=no
91683      ;;
91684
91685    newsos6)
91686      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91687      hardcode_direct=yes
91688      hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
91689      hardcode_libdir_separator=:
91690      hardcode_shlibpath_var=no
91691      ;;
91692
91693    openbsd*)
91694      if test -f /usr/libexec/ld.so; then
91695	hardcode_direct=yes
91696	hardcode_shlibpath_var=no
91697	if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
91698	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
91699	  archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
91700	  hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
91701	  export_dynamic_flag_spec='${wl}-E'
91702	else
91703	  case $host_os in
91704	   openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
91705	     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
91706	     hardcode_libdir_flag_spec='-R$libdir'
91707	     ;;
91708	   *)
91709	     archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
91710	     hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
91711	     ;;
91712	  esac
91713        fi
91714      else
91715	ld_shlibs=no
91716      fi
91717      ;;
91718
91719    os2*)
91720      hardcode_libdir_flag_spec='-L$libdir'
91721      hardcode_minus_L=yes
91722      allow_undefined_flag=unsupported
91723      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'
91724      old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
91725      ;;
91726
91727    osf3*)
91728      if test "$GCC" = yes; then
91729	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
91730	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
91731      else
91732	allow_undefined_flag=' -expect_unresolved \*'
91733	archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
91734      fi
91735      hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
91736      hardcode_libdir_separator=:
91737      ;;
91738
91739    osf4* | osf5*)	# as osf3* with the addition of -msym flag
91740      if test "$GCC" = yes; then
91741	allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
91742	archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
91743	hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
91744      else
91745	allow_undefined_flag=' -expect_unresolved \*'
91746	archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
91747	archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
91748	$LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
91749
91750	# Both c and cxx compiler support -rpath directly
91751	hardcode_libdir_flag_spec='-rpath $libdir'
91752      fi
91753      hardcode_libdir_separator=:
91754      ;;
91755
91756    solaris*)
91757      no_undefined_flag=' -z text'
91758      if test "$GCC" = yes; then
91759	wlarc='${wl}'
91760	archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
91761	archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
91762	  $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
91763      else
91764	wlarc=''
91765	archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
91766	archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
91767  	$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
91768      fi
91769      hardcode_libdir_flag_spec='-R$libdir'
91770      hardcode_shlibpath_var=no
91771      case $host_os in
91772      solaris2.[0-5] | solaris2.[0-5].*) ;;
91773      *)
91774	# The compiler driver will combine and reorder linker options,
91775	# but understands `-z linker_flag'.  GCC discards it without `$wl',
91776	# but is careful enough not to reorder.
91777 	# Supported since Solaris 2.6 (maybe 2.5.1?)
91778	if test "$GCC" = yes; then
91779	  whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
91780	else
91781	  whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
91782	fi
91783	;;
91784      esac
91785      link_all_deplibs=yes
91786      ;;
91787
91788    sunos4*)
91789      if test "x$host_vendor" = xsequent; then
91790	# Use $CC to link under sequent, because it throws in some extra .o
91791	# files that make .init and .fini sections work.
91792	archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
91793      else
91794	archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
91795      fi
91796      hardcode_libdir_flag_spec='-L$libdir'
91797      hardcode_direct=yes
91798      hardcode_minus_L=yes
91799      hardcode_shlibpath_var=no
91800      ;;
91801
91802    sysv4)
91803      case $host_vendor in
91804	sni)
91805	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91806	  hardcode_direct=yes # is this really true???
91807	;;
91808	siemens)
91809	  ## LD is ld it makes a PLAMLIB
91810	  ## CC just makes a GrossModule.
91811	  archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
91812	  reload_cmds='$CC -r -o $output$reload_objs'
91813	  hardcode_direct=no
91814        ;;
91815	motorola)
91816	  archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91817	  hardcode_direct=no #Motorola manual says yes, but my tests say they lie
91818	;;
91819      esac
91820      runpath_var='LD_RUN_PATH'
91821      hardcode_shlibpath_var=no
91822      ;;
91823
91824    sysv4.3*)
91825      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91826      hardcode_shlibpath_var=no
91827      export_dynamic_flag_spec='-Bexport'
91828      ;;
91829
91830    sysv4*MP*)
91831      if test -d /usr/nec; then
91832	archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91833	hardcode_shlibpath_var=no
91834	runpath_var=LD_RUN_PATH
91835	hardcode_runpath_var=yes
91836	ld_shlibs=yes
91837      fi
91838      ;;
91839
91840    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
91841      no_undefined_flag='${wl}-z,text'
91842      archive_cmds_need_lc=no
91843      hardcode_shlibpath_var=no
91844      runpath_var='LD_RUN_PATH'
91845
91846      if test "$GCC" = yes; then
91847	archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
91848	archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
91849      else
91850	archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
91851	archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
91852      fi
91853      ;;
91854
91855    sysv5* | sco3.2v5* | sco5v6*)
91856      # Note: We can NOT use -z defs as we might desire, because we do not
91857      # link with -lc, and that would cause any symbols used from libc to
91858      # always be unresolved, which means just about no library would
91859      # ever link correctly.  If we're not using GNU ld we use -z text
91860      # though, which does catch some bad symbols but isn't as heavy-handed
91861      # as -z defs.
91862      no_undefined_flag='${wl}-z,text'
91863      allow_undefined_flag='${wl}-z,nodefs'
91864      archive_cmds_need_lc=no
91865      hardcode_shlibpath_var=no
91866      hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
91867      hardcode_libdir_separator=':'
91868      link_all_deplibs=yes
91869      export_dynamic_flag_spec='${wl}-Bexport'
91870      runpath_var='LD_RUN_PATH'
91871
91872      if test "$GCC" = yes; then
91873	archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
91874	archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
91875      else
91876	archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
91877	archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
91878      fi
91879      ;;
91880
91881    uts4*)
91882      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
91883      hardcode_libdir_flag_spec='-L$libdir'
91884      hardcode_shlibpath_var=no
91885      ;;
91886
91887    *)
91888      ld_shlibs=no
91889      ;;
91890    esac
91891  fi
91892
91893{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
91894printf "%s\n" "$ld_shlibs" >&6; }
91895test "$ld_shlibs" = no && can_build_shared=no
91896
91897#
91898# Do we need to explicitly link libc?
91899#
91900case "x$archive_cmds_need_lc" in
91901x|xyes)
91902  # Assume -lc should be added
91903  archive_cmds_need_lc=yes
91904
91905  if test "$enable_shared" = yes && test "$GCC" = yes; then
91906    case $archive_cmds in
91907    *'~'*)
91908      # FIXME: we may have to deal with multi-command sequences.
91909      ;;
91910    '$CC '*)
91911      # Test whether the compiler implicitly links with -lc since on some
91912      # systems, -lgcc has to come before -lc. If gcc already passes -lc
91913      # to ld, don't add -lc before -lgcc.
91914      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
91915printf %s "checking whether -lc should be explicitly linked in... " >&6; }
91916      $rm conftest*
91917      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
91918
91919      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
91920  (eval $ac_compile) 2>&5
91921  ac_status=$?
91922  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
91923  test $ac_status = 0; } 2>conftest.err; then
91924        soname=conftest
91925        lib=conftest
91926        libobjs=conftest.$ac_objext
91927        deplibs=
91928        wl=$lt_prog_compiler_wl
91929	pic_flag=$lt_prog_compiler_pic
91930        compiler_flags=-v
91931        linker_flags=-v
91932        verstring=
91933        output_objdir=.
91934        libname=conftest
91935        lt_save_allow_undefined_flag=$allow_undefined_flag
91936        allow_undefined_flag=
91937        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5
91938  (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
91939  ac_status=$?
91940  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
91941  test $ac_status = 0; }
91942        then
91943	  archive_cmds_need_lc=no
91944        else
91945	  archive_cmds_need_lc=yes
91946        fi
91947        allow_undefined_flag=$lt_save_allow_undefined_flag
91948      else
91949        cat conftest.err 1>&5
91950      fi
91951      $rm conftest*
91952      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc" >&5
91953printf "%s\n" "$archive_cmds_need_lc" >&6; }
91954      ;;
91955    esac
91956  fi
91957  ;;
91958esac
91959
91960{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
91961printf %s "checking dynamic linker characteristics... " >&6; }
91962library_names_spec=
91963libname_spec='lib$name'
91964soname_spec=
91965shrext_cmds=".so"
91966postinstall_cmds=
91967postuninstall_cmds=
91968finish_cmds=
91969finish_eval=
91970shlibpath_var=
91971shlibpath_overrides_runpath=unknown
91972version_type=none
91973dynamic_linker="$host_os ld.so"
91974sys_lib_dlsearch_path_spec="/lib /usr/lib"
91975
91976if test "$GCC" = yes; then
91977  case $host_os in
91978    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
91979    *) lt_awk_arg="/^libraries:/" ;;
91980  esac
91981  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
91982  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
91983    # if the path contains ";" then we assume it to be the separator
91984    # otherwise default to the standard path separator (i.e. ":") - it is
91985    # assumed that no part of a normal pathname contains ";" but that should
91986    # okay in the real world where ";" in dirpaths is itself problematic.
91987    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
91988  else
91989    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
91990  fi
91991  # Ok, now we have the path, separated by spaces, we can step through it
91992  # and add multilib dir if necessary.
91993  lt_tmp_lt_search_path_spec=
91994  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
91995  for lt_sys_path in $lt_search_path_spec; do
91996    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
91997      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
91998    else
91999      test -d "$lt_sys_path" && \
92000	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
92001    fi
92002  done
92003  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
92004BEGIN {RS=" "; FS="/|\n";} {
92005  lt_foo="";
92006  lt_count=0;
92007  for (lt_i = NF; lt_i > 0; lt_i--) {
92008    if ($lt_i != "" && $lt_i != ".") {
92009      if ($lt_i == "..") {
92010        lt_count++;
92011      } else {
92012        if (lt_count == 0) {
92013          lt_foo="/" $lt_i lt_foo;
92014        } else {
92015          lt_count--;
92016        }
92017      }
92018    }
92019  }
92020  if (lt_foo != "") { lt_freq[lt_foo]++; }
92021  if (lt_freq[lt_foo] == 1) { print lt_foo; }
92022}'`
92023  sys_lib_search_path_spec=`echo $lt_search_path_spec`
92024else
92025  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
92026fi
92027need_lib_prefix=unknown
92028hardcode_into_libs=no
92029
92030# when you set need_version to no, make sure it does not cause -set_version
92031# flags to be left without arguments
92032need_version=unknown
92033
92034case $host_os in
92035aix3*)
92036  version_type=linux
92037  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
92038  shlibpath_var=LIBPATH
92039
92040  # AIX 3 has no versioning support, so we append a major version to the name.
92041  soname_spec='${libname}${release}${shared_ext}$major'
92042  ;;
92043
92044aix[4-9]*)
92045  version_type=linux
92046  need_lib_prefix=no
92047  need_version=no
92048  hardcode_into_libs=yes
92049  if test "$host_cpu" = ia64; then
92050    # AIX 5 supports IA64
92051    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
92052    shlibpath_var=LD_LIBRARY_PATH
92053  else
92054    # With GCC up to 2.95.x, collect2 would create an import file
92055    # for dependence libraries.  The import file would start with
92056    # the line `#! .'.  This would cause the generated library to
92057    # depend on `.', always an invalid library.  This was fixed in
92058    # development snapshots of GCC prior to 3.0.
92059    case $host_os in
92060      aix4 | aix4.[01] | aix4.[01].*)
92061      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
92062	   echo ' yes '
92063	   echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
92064	:
92065      else
92066	can_build_shared=no
92067      fi
92068      ;;
92069    esac
92070    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
92071    # soname into executable. Probably we can add versioning support to
92072    # collect2, so additional links can be useful in future.
92073    if test "$aix_use_runtimelinking" = yes; then
92074      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
92075      # instead of lib<name>.a to let people know that these are not
92076      # typical AIX shared libraries.
92077      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92078    else
92079      # We preserve .a as extension for shared libraries through AIX4.2
92080      # and later when we are not doing run time linking.
92081      library_names_spec='${libname}${release}.a $libname.a'
92082      soname_spec='${libname}${release}${shared_ext}$major'
92083    fi
92084    shlibpath_var=LIBPATH
92085  fi
92086  ;;
92087
92088amigaos*)
92089  library_names_spec='$libname.ixlibrary $libname.a'
92090  # Create ${libname}_ixlibrary.a entries in /sys/libs.
92091  finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''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'
92092  ;;
92093
92094beos*)
92095  library_names_spec='${libname}${shared_ext}'
92096  dynamic_linker="$host_os ld.so"
92097  shlibpath_var=LIBRARY_PATH
92098  ;;
92099
92100haiku*)
92101  # Since haiku provides gcc, use GNU style here
92102  version_type=linux
92103  need_lib_prefix=no
92104  need_version=no
92105  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
92106  soname_spec='${libname}${release}${shared_ext}$major'
92107  shlibpath_var=LIBRARY_PATH
92108  hardcode_into_libs=yes
92109  ;;
92110
92111bsdi[45]*)
92112  version_type=linux
92113  need_version=no
92114  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92115  soname_spec='${libname}${release}${shared_ext}$major'
92116  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
92117  shlibpath_var=LD_LIBRARY_PATH
92118  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
92119  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
92120  # the default ld.so.conf also contains /usr/contrib/lib and
92121  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
92122  # libtool to hard-code these into programs
92123  ;;
92124
92125cygwin* | mingw* | pw32*)
92126  version_type=windows
92127  shrext_cmds=".dll"
92128  need_version=no
92129  need_lib_prefix=no
92130
92131  case $GCC,$host_os in
92132  yes,cygwin* | yes,mingw* | yes,pw32*)
92133    library_names_spec='$libname.dll.a'
92134    # DLL is installed to $(libdir)/../bin by postinstall_cmds
92135    postinstall_cmds='base_file=`basename \${file}`~
92136      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
92137      dldir=$destdir/`dirname \$dlpath`~
92138      test -d \$dldir || mkdir -p \$dldir~
92139      $install_prog $dir/$dlname \$dldir/$dlname~
92140      chmod a+x \$dldir/$dlname'
92141    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
92142      dlpath=$dir/\$dldll~
92143       $rm \$dlpath'
92144    shlibpath_overrides_runpath=yes
92145
92146    case $host_os in
92147    cygwin*)
92148      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
92149      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
92150      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
92151      ;;
92152    mingw*)
92153      # MinGW DLLs use traditional 'lib' prefix
92154      soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
92155      sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
92156      if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
92157        # It is most probably a Windows format PATH printed by
92158        # mingw gcc, but we are running on Cygwin. Gcc prints its search
92159        # path with ; separators, and with drive letters. We can handle the
92160        # drive letters (cygwin fileutils understands them), so leave them,
92161        # especially as we might pass files found there to a mingw objdump,
92162        # which wouldn't understand a cygwinified path. Ahh.
92163        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
92164      else
92165        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
92166      fi
92167      ;;
92168    pw32*)
92169      # pw32 DLLs use 'pw' prefix rather than 'lib'
92170      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
92171      ;;
92172    esac
92173    ;;
92174
92175  *)
92176    library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
92177    ;;
92178  esac
92179  dynamic_linker='Win32 ld.exe'
92180  # FIXME: first we should search . and the directory the executable is in
92181  shlibpath_var=PATH
92182  ;;
92183
92184darwin* | rhapsody*)
92185  dynamic_linker="$host_os dyld"
92186  version_type=darwin
92187  need_lib_prefix=no
92188  need_version=no
92189  library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
92190  soname_spec='${libname}${release}${major}$shared_ext'
92191  shlibpath_overrides_runpath=yes
92192  shlibpath_var=DYLD_LIBRARY_PATH
92193  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
92194
92195  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
92196  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
92197  ;;
92198
92199dgux*)
92200  version_type=linux
92201  need_lib_prefix=no
92202  need_version=no
92203  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
92204  soname_spec='${libname}${release}${shared_ext}$major'
92205  shlibpath_var=LD_LIBRARY_PATH
92206  ;;
92207
92208freebsd* | dragonfly*)
92209  # DragonFly does not have aout.  When/if they implement a new
92210  # versioning mechanism, adjust this.
92211  if test -x /usr/bin/objformat; then
92212    objformat=`/usr/bin/objformat`
92213  else
92214    case $host_os in
92215    freebsd[123].*) objformat=aout ;;
92216    *) objformat=elf ;;
92217    esac
92218  fi
92219  version_type=freebsd-$objformat
92220  case $version_type in
92221    freebsd-elf*)
92222      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
92223      need_version=no
92224      need_lib_prefix=no
92225      ;;
92226    freebsd-*)
92227      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
92228      need_version=yes
92229      ;;
92230  esac
92231  shlibpath_var=LD_LIBRARY_PATH
92232  case $host_os in
92233  freebsd2*)
92234    shlibpath_overrides_runpath=yes
92235    ;;
92236  freebsd3.[01]* | freebsdelf3.[01]*)
92237    shlibpath_overrides_runpath=yes
92238    hardcode_into_libs=yes
92239    ;;
92240  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
92241  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
92242    shlibpath_overrides_runpath=no
92243    hardcode_into_libs=yes
92244    ;;
92245  *) # from 4.6 on, and DragonFly
92246    shlibpath_overrides_runpath=yes
92247    hardcode_into_libs=yes
92248    ;;
92249  esac
92250  ;;
92251
92252gnu*)
92253  version_type=linux
92254  need_lib_prefix=no
92255  need_version=no
92256  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
92257  soname_spec='${libname}${release}${shared_ext}$major'
92258  shlibpath_var=LD_LIBRARY_PATH
92259  hardcode_into_libs=yes
92260  ;;
92261
92262hpux9* | hpux10* | hpux11*)
92263  # Give a soname corresponding to the major version so that dld.sl refuses to
92264  # link against other versions.
92265  version_type=sunos
92266  need_lib_prefix=no
92267  need_version=no
92268  case $host_cpu in
92269  ia64*)
92270    shrext_cmds='.so'
92271    hardcode_into_libs=yes
92272    dynamic_linker="$host_os dld.so"
92273    shlibpath_var=LD_LIBRARY_PATH
92274    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
92275    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92276    soname_spec='${libname}${release}${shared_ext}$major'
92277    if test "X$HPUX_IA64_MODE" = X32; then
92278      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
92279    else
92280      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
92281    fi
92282    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
92283    ;;
92284   hppa*64*)
92285     shrext_cmds='.sl'
92286     hardcode_into_libs=yes
92287     dynamic_linker="$host_os dld.sl"
92288     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
92289     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
92290     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92291     soname_spec='${libname}${release}${shared_ext}$major'
92292     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
92293     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
92294     ;;
92295   *)
92296    shrext_cmds='.sl'
92297    dynamic_linker="$host_os dld.sl"
92298    shlibpath_var=SHLIB_PATH
92299    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
92300    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92301    soname_spec='${libname}${release}${shared_ext}$major'
92302    ;;
92303  esac
92304  # HP-UX runs *really* slowly unless shared libraries are mode 555.
92305  postinstall_cmds='chmod 555 $lib'
92306  ;;
92307
92308interix[3-9]*)
92309  version_type=linux
92310  need_lib_prefix=no
92311  need_version=no
92312  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
92313  soname_spec='${libname}${release}${shared_ext}$major'
92314  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
92315  shlibpath_var=LD_LIBRARY_PATH
92316  shlibpath_overrides_runpath=no
92317  hardcode_into_libs=yes
92318  ;;
92319
92320irix5* | irix6* | nonstopux*)
92321  case $host_os in
92322    nonstopux*) version_type=nonstopux ;;
92323    *)
92324	if test "$lt_cv_prog_gnu_ld" = yes; then
92325		version_type=linux
92326	else
92327		version_type=irix
92328	fi ;;
92329  esac
92330  need_lib_prefix=no
92331  need_version=no
92332  soname_spec='${libname}${release}${shared_ext}$major'
92333  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
92334  case $host_os in
92335  irix5* | nonstopux*)
92336    libsuff= shlibsuff=
92337    ;;
92338  *)
92339    case $LD in # libtool.m4 will add one of these switches to LD
92340    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
92341      libsuff= shlibsuff= libmagic=32-bit;;
92342    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
92343      libsuff=32 shlibsuff=N32 libmagic=N32;;
92344    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
92345      libsuff=64 shlibsuff=64 libmagic=64-bit;;
92346    *) libsuff= shlibsuff= libmagic=never-match;;
92347    esac
92348    ;;
92349  esac
92350  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
92351  shlibpath_overrides_runpath=no
92352  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
92353  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
92354  hardcode_into_libs=yes
92355  ;;
92356
92357# No shared lib support for Linux oldld, aout, or coff.
92358linux*oldld* | linux*aout* | linux*coff*)
92359  dynamic_linker=no
92360  ;;
92361
92362# This must be Linux ELF.
92363linux* | k*bsd*-gnu)
92364  version_type=linux
92365  need_lib_prefix=no
92366  need_version=no
92367  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92368  soname_spec='${libname}${release}${shared_ext}$major'
92369  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
92370  shlibpath_var=LD_LIBRARY_PATH
92371  shlibpath_overrides_runpath=no
92372  # This implies no fast_install, which is unacceptable.
92373  # Some rework will be needed to allow for fast_install
92374  # before this can be enabled.
92375  hardcode_into_libs=yes
92376
92377  # Append ld.so.conf contents to the search path
92378  if test -f /etc/ld.so.conf; then
92379    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;/^$/d' | tr '\n' ' '`
92380    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
92381  fi
92382
92383  # We used to test for /lib/ld.so.1 and disable shared libraries on
92384  # powerpc, because MkLinux only supported shared libraries with the
92385  # GNU dynamic linker.  Since this was broken with cross compilers,
92386  # most powerpc-linux boxes support dynamic linking these days and
92387  # people can always --disable-shared, the test was removed, and we
92388  # assume the GNU/Linux dynamic linker is in use.
92389  dynamic_linker='GNU/Linux ld.so'
92390  ;;
92391
92392netbsd*)
92393  version_type=sunos
92394  need_lib_prefix=no
92395  need_version=no
92396  if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
92397    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
92398    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
92399    dynamic_linker='NetBSD (a.out) ld.so'
92400  else
92401    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
92402    soname_spec='${libname}${release}${shared_ext}$major'
92403    dynamic_linker='NetBSD ld.elf_so'
92404  fi
92405  shlibpath_var=LD_LIBRARY_PATH
92406  shlibpath_overrides_runpath=yes
92407  hardcode_into_libs=yes
92408  ;;
92409
92410newsos6)
92411  version_type=linux
92412  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92413  shlibpath_var=LD_LIBRARY_PATH
92414  shlibpath_overrides_runpath=yes
92415  ;;
92416
92417nto-qnx*)
92418  version_type=linux
92419  need_lib_prefix=no
92420  need_version=no
92421  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92422  soname_spec='${libname}${release}${shared_ext}$major'
92423  shlibpath_var=LD_LIBRARY_PATH
92424  shlibpath_overrides_runpath=yes
92425  ;;
92426
92427openbsd*)
92428  version_type=sunos
92429  sys_lib_dlsearch_path_spec="/usr/lib"
92430  need_lib_prefix=no
92431  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
92432  case $host_os in
92433    openbsd3.3 | openbsd3.3.*) need_version=yes ;;
92434    *)                         need_version=no  ;;
92435  esac
92436  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
92437  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
92438  shlibpath_var=LD_LIBRARY_PATH
92439  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
92440    case $host_os in
92441      openbsd2.[89] | openbsd2.[89].*)
92442	shlibpath_overrides_runpath=no
92443	;;
92444      *)
92445	shlibpath_overrides_runpath=yes
92446	;;
92447      esac
92448  else
92449    shlibpath_overrides_runpath=yes
92450  fi
92451  ;;
92452
92453os2*)
92454  libname_spec='$name'
92455  shrext_cmds=".dll"
92456  need_lib_prefix=no
92457  library_names_spec='$libname${shared_ext} $libname.a'
92458  dynamic_linker='OS/2 ld.exe'
92459  shlibpath_var=LIBPATH
92460  ;;
92461
92462osf3* | osf4* | osf5*)
92463  version_type=osf
92464  need_lib_prefix=no
92465  need_version=no
92466  soname_spec='${libname}${release}${shared_ext}$major'
92467  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92468  shlibpath_var=LD_LIBRARY_PATH
92469  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
92470  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
92471  ;;
92472
92473rdos*)
92474  dynamic_linker=no
92475  ;;
92476
92477solaris*)
92478  version_type=linux
92479  need_lib_prefix=no
92480  need_version=no
92481  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92482  soname_spec='${libname}${release}${shared_ext}$major'
92483  shlibpath_var=LD_LIBRARY_PATH
92484  shlibpath_overrides_runpath=yes
92485  hardcode_into_libs=yes
92486  # ldd complains unless libraries are executable
92487  postinstall_cmds='chmod +x $lib'
92488  ;;
92489
92490sunos4*)
92491  version_type=sunos
92492  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
92493  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
92494  shlibpath_var=LD_LIBRARY_PATH
92495  shlibpath_overrides_runpath=yes
92496  if test "$with_gnu_ld" = yes; then
92497    need_lib_prefix=no
92498  fi
92499  need_version=yes
92500  ;;
92501
92502sysv4 | sysv4.3*)
92503  version_type=linux
92504  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92505  soname_spec='${libname}${release}${shared_ext}$major'
92506  shlibpath_var=LD_LIBRARY_PATH
92507  case $host_vendor in
92508    sni)
92509      shlibpath_overrides_runpath=no
92510      need_lib_prefix=no
92511      export_dynamic_flag_spec='${wl}-Blargedynsym'
92512      runpath_var=LD_RUN_PATH
92513      ;;
92514    siemens)
92515      need_lib_prefix=no
92516      ;;
92517    motorola)
92518      need_lib_prefix=no
92519      need_version=no
92520      shlibpath_overrides_runpath=no
92521      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
92522      ;;
92523  esac
92524  ;;
92525
92526sysv4*MP*)
92527  if test -d /usr/nec ;then
92528    version_type=linux
92529    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
92530    soname_spec='$libname${shared_ext}.$major'
92531    shlibpath_var=LD_LIBRARY_PATH
92532  fi
92533  ;;
92534
92535sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
92536  version_type=freebsd-elf
92537  need_lib_prefix=no
92538  need_version=no
92539  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
92540  soname_spec='${libname}${release}${shared_ext}$major'
92541  shlibpath_var=LD_LIBRARY_PATH
92542  hardcode_into_libs=yes
92543  if test "$with_gnu_ld" = yes; then
92544    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
92545    shlibpath_overrides_runpath=no
92546  else
92547    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
92548    shlibpath_overrides_runpath=yes
92549    case $host_os in
92550      sco3.2v5*)
92551        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
92552	;;
92553    esac
92554  fi
92555  sys_lib_dlsearch_path_spec='/usr/lib'
92556  ;;
92557
92558uts4*)
92559  version_type=linux
92560  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
92561  soname_spec='${libname}${release}${shared_ext}$major'
92562  shlibpath_var=LD_LIBRARY_PATH
92563  ;;
92564
92565*)
92566  dynamic_linker=no
92567  ;;
92568esac
92569{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
92570printf "%s\n" "$dynamic_linker" >&6; }
92571test "$dynamic_linker" = no && can_build_shared=no
92572
92573if test ${lt_cv_sys_lib_search_path_spec+y}
92574then :
92575  printf %s "(cached) " >&6
92576else $as_nop
92577  lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"
92578fi
92579
92580sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
92581if test ${lt_cv_sys_lib_dlsearch_path_spec+y}
92582then :
92583  printf %s "(cached) " >&6
92584else $as_nop
92585  lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"
92586fi
92587
92588sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
92589
92590variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
92591if test "$GCC" = yes; then
92592  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
92593fi
92594
92595{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
92596printf %s "checking how to hardcode library paths into programs... " >&6; }
92597hardcode_action=
92598if test -n "$hardcode_libdir_flag_spec" || \
92599   test -n "$runpath_var" || \
92600   test "X$hardcode_automatic" = "Xyes" ; then
92601
92602  # We can hardcode non-existent directories.
92603  if test "$hardcode_direct" != no &&
92604     # If the only mechanism to avoid hardcoding is shlibpath_var, we
92605     # have to relink, otherwise we might link with an installed library
92606     # when we should be linking with a yet-to-be-installed one
92607     ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
92608     test "$hardcode_minus_L" != no; then
92609    # Linking always hardcodes the temporary library directory.
92610    hardcode_action=relink
92611  else
92612    # We can link without hardcoding, and we can hardcode nonexisting dirs.
92613    hardcode_action=immediate
92614  fi
92615else
92616  # We cannot hardcode anything, or else we can only hardcode existing
92617  # directories.
92618  hardcode_action=unsupported
92619fi
92620{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
92621printf "%s\n" "$hardcode_action" >&6; }
92622
92623if test "$hardcode_action" = relink; then
92624  # Fast installation is not supported
92625  enable_fast_install=no
92626elif test "$shlibpath_overrides_runpath" = yes ||
92627     test "$enable_shared" = no; then
92628  # Fast installation is not necessary
92629  enable_fast_install=needless
92630fi
92631
92632striplib=
92633old_striplib=
92634{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
92635printf %s "checking whether stripping libraries is possible... " >&6; }
92636if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
92637  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
92638  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
92639  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
92640printf "%s\n" "yes" >&6; }
92641else
92642# FIXME - insert some real tests, host_os isn't really good enough
92643  case $host_os in
92644   darwin*)
92645       if test -n "$STRIP" ; then
92646         striplib="$STRIP -x"
92647         old_striplib="$STRIP -S"
92648         { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
92649printf "%s\n" "yes" >&6; }
92650       else
92651  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
92652printf "%s\n" "no" >&6; }
92653fi
92654       ;;
92655   *)
92656  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
92657printf "%s\n" "no" >&6; }
92658    ;;
92659  esac
92660fi
92661
92662if test "x$enable_dlopen" != xyes; then
92663  enable_dlopen=unknown
92664  enable_dlopen_self=unknown
92665  enable_dlopen_self_static=unknown
92666else
92667  lt_cv_dlopen=no
92668  lt_cv_dlopen_libs=
92669
92670  case $host_os in
92671  beos* | haiku*)
92672    lt_cv_dlopen="load_add_on"
92673    lt_cv_dlopen_libs=
92674    lt_cv_dlopen_self=yes
92675    ;;
92676
92677  mingw* | pw32*)
92678    lt_cv_dlopen="LoadLibrary"
92679    lt_cv_dlopen_libs=
92680   ;;
92681
92682  cygwin*)
92683    lt_cv_dlopen="dlopen"
92684    lt_cv_dlopen_libs=
92685   ;;
92686
92687  darwin*)
92688  # if libdl is installed we need to link against it
92689    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
92690printf %s "checking for dlopen in -ldl... " >&6; }
92691if test ${ac_cv_lib_dl_dlopen+y}
92692then :
92693  printf %s "(cached) " >&6
92694else $as_nop
92695  ac_check_lib_save_LIBS=$LIBS
92696LIBS="-ldl  $LIBS"
92697cat confdefs.h - <<_ACEOF >conftest.$ac_ext
92698/* end confdefs.h.  */
92699
92700/* Override any GCC internal prototype to avoid an error.
92701   Use char because int might match the return type of a GCC
92702   builtin and then its argument prototype would still apply.  */
92703char dlopen ();
92704int
92705main (void)
92706{
92707return dlopen ();
92708  ;
92709  return 0;
92710}
92711_ACEOF
92712if ac_fn_c_try_link "$LINENO"
92713then :
92714  ac_cv_lib_dl_dlopen=yes
92715else $as_nop
92716  ac_cv_lib_dl_dlopen=no
92717fi
92718rm -f core conftest.err conftest.$ac_objext conftest.beam \
92719    conftest$ac_exeext conftest.$ac_ext
92720LIBS=$ac_check_lib_save_LIBS
92721fi
92722{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
92723printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
92724if test "x$ac_cv_lib_dl_dlopen" = xyes
92725then :
92726  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
92727else $as_nop
92728
92729    lt_cv_dlopen="dyld"
92730    lt_cv_dlopen_libs=
92731    lt_cv_dlopen_self=yes
92732
92733fi
92734
92735   ;;
92736
92737  *)
92738    ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
92739if test "x$ac_cv_func_shl_load" = xyes
92740then :
92741  lt_cv_dlopen="shl_load"
92742else $as_nop
92743  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
92744printf %s "checking for shl_load in -ldld... " >&6; }
92745if test ${ac_cv_lib_dld_shl_load+y}
92746then :
92747  printf %s "(cached) " >&6
92748else $as_nop
92749  ac_check_lib_save_LIBS=$LIBS
92750LIBS="-ldld  $LIBS"
92751cat confdefs.h - <<_ACEOF >conftest.$ac_ext
92752/* end confdefs.h.  */
92753
92754/* Override any GCC internal prototype to avoid an error.
92755   Use char because int might match the return type of a GCC
92756   builtin and then its argument prototype would still apply.  */
92757char shl_load ();
92758int
92759main (void)
92760{
92761return shl_load ();
92762  ;
92763  return 0;
92764}
92765_ACEOF
92766if ac_fn_c_try_link "$LINENO"
92767then :
92768  ac_cv_lib_dld_shl_load=yes
92769else $as_nop
92770  ac_cv_lib_dld_shl_load=no
92771fi
92772rm -f core conftest.err conftest.$ac_objext conftest.beam \
92773    conftest$ac_exeext conftest.$ac_ext
92774LIBS=$ac_check_lib_save_LIBS
92775fi
92776{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
92777printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; }
92778if test "x$ac_cv_lib_dld_shl_load" = xyes
92779then :
92780  lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
92781else $as_nop
92782  ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
92783if test "x$ac_cv_func_dlopen" = xyes
92784then :
92785  lt_cv_dlopen="dlopen"
92786else $as_nop
92787  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
92788printf %s "checking for dlopen in -ldl... " >&6; }
92789if test ${ac_cv_lib_dl_dlopen+y}
92790then :
92791  printf %s "(cached) " >&6
92792else $as_nop
92793  ac_check_lib_save_LIBS=$LIBS
92794LIBS="-ldl  $LIBS"
92795cat confdefs.h - <<_ACEOF >conftest.$ac_ext
92796/* end confdefs.h.  */
92797
92798/* Override any GCC internal prototype to avoid an error.
92799   Use char because int might match the return type of a GCC
92800   builtin and then its argument prototype would still apply.  */
92801char dlopen ();
92802int
92803main (void)
92804{
92805return dlopen ();
92806  ;
92807  return 0;
92808}
92809_ACEOF
92810if ac_fn_c_try_link "$LINENO"
92811then :
92812  ac_cv_lib_dl_dlopen=yes
92813else $as_nop
92814  ac_cv_lib_dl_dlopen=no
92815fi
92816rm -f core conftest.err conftest.$ac_objext conftest.beam \
92817    conftest$ac_exeext conftest.$ac_ext
92818LIBS=$ac_check_lib_save_LIBS
92819fi
92820{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
92821printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
92822if test "x$ac_cv_lib_dl_dlopen" = xyes
92823then :
92824  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
92825else $as_nop
92826  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
92827printf %s "checking for dlopen in -lsvld... " >&6; }
92828if test ${ac_cv_lib_svld_dlopen+y}
92829then :
92830  printf %s "(cached) " >&6
92831else $as_nop
92832  ac_check_lib_save_LIBS=$LIBS
92833LIBS="-lsvld  $LIBS"
92834cat confdefs.h - <<_ACEOF >conftest.$ac_ext
92835/* end confdefs.h.  */
92836
92837/* Override any GCC internal prototype to avoid an error.
92838   Use char because int might match the return type of a GCC
92839   builtin and then its argument prototype would still apply.  */
92840char dlopen ();
92841int
92842main (void)
92843{
92844return dlopen ();
92845  ;
92846  return 0;
92847}
92848_ACEOF
92849if ac_fn_c_try_link "$LINENO"
92850then :
92851  ac_cv_lib_svld_dlopen=yes
92852else $as_nop
92853  ac_cv_lib_svld_dlopen=no
92854fi
92855rm -f core conftest.err conftest.$ac_objext conftest.beam \
92856    conftest$ac_exeext conftest.$ac_ext
92857LIBS=$ac_check_lib_save_LIBS
92858fi
92859{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
92860printf "%s\n" "$ac_cv_lib_svld_dlopen" >&6; }
92861if test "x$ac_cv_lib_svld_dlopen" = xyes
92862then :
92863  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
92864else $as_nop
92865  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
92866printf %s "checking for dld_link in -ldld... " >&6; }
92867if test ${ac_cv_lib_dld_dld_link+y}
92868then :
92869  printf %s "(cached) " >&6
92870else $as_nop
92871  ac_check_lib_save_LIBS=$LIBS
92872LIBS="-ldld  $LIBS"
92873cat confdefs.h - <<_ACEOF >conftest.$ac_ext
92874/* end confdefs.h.  */
92875
92876/* Override any GCC internal prototype to avoid an error.
92877   Use char because int might match the return type of a GCC
92878   builtin and then its argument prototype would still apply.  */
92879char dld_link ();
92880int
92881main (void)
92882{
92883return dld_link ();
92884  ;
92885  return 0;
92886}
92887_ACEOF
92888if ac_fn_c_try_link "$LINENO"
92889then :
92890  ac_cv_lib_dld_dld_link=yes
92891else $as_nop
92892  ac_cv_lib_dld_dld_link=no
92893fi
92894rm -f core conftest.err conftest.$ac_objext conftest.beam \
92895    conftest$ac_exeext conftest.$ac_ext
92896LIBS=$ac_check_lib_save_LIBS
92897fi
92898{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
92899printf "%s\n" "$ac_cv_lib_dld_dld_link" >&6; }
92900if test "x$ac_cv_lib_dld_dld_link" = xyes
92901then :
92902  lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
92903fi
92904
92905
92906fi
92907
92908
92909fi
92910
92911
92912fi
92913
92914
92915fi
92916
92917
92918fi
92919
92920    ;;
92921  esac
92922
92923  if test "x$lt_cv_dlopen" != xno; then
92924    enable_dlopen=yes
92925  else
92926    enable_dlopen=no
92927  fi
92928
92929  case $lt_cv_dlopen in
92930  dlopen)
92931    save_CPPFLAGS="$CPPFLAGS"
92932    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
92933
92934    save_LDFLAGS="$LDFLAGS"
92935    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
92936
92937    save_LIBS="$LIBS"
92938    LIBS="$lt_cv_dlopen_libs $LIBS"
92939
92940    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
92941printf %s "checking whether a program can dlopen itself... " >&6; }
92942if test ${lt_cv_dlopen_self+y}
92943then :
92944  printf %s "(cached) " >&6
92945else $as_nop
92946  	  if test "$cross_compiling" = yes; then :
92947  lt_cv_dlopen_self=cross
92948else
92949  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
92950  lt_status=$lt_dlunknown
92951  cat > conftest.$ac_ext <<EOF
92952#line 92952 "configure"
92953#include "confdefs.h"
92954
92955#if HAVE_DLFCN_H
92956#include <dlfcn.h>
92957#endif
92958
92959#include <stdio.h>
92960#include <stdlib.h>
92961
92962#ifdef RTLD_GLOBAL
92963#  define LT_DLGLOBAL		RTLD_GLOBAL
92964#else
92965#  ifdef DL_GLOBAL
92966#    define LT_DLGLOBAL		DL_GLOBAL
92967#  else
92968#    define LT_DLGLOBAL		0
92969#  endif
92970#endif
92971
92972/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
92973   find out it does not work in some platform. */
92974#ifndef LT_DLLAZY_OR_NOW
92975#  ifdef RTLD_LAZY
92976#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
92977#  else
92978#    ifdef DL_LAZY
92979#      define LT_DLLAZY_OR_NOW		DL_LAZY
92980#    else
92981#      ifdef RTLD_NOW
92982#        define LT_DLLAZY_OR_NOW	RTLD_NOW
92983#      else
92984#        ifdef DL_NOW
92985#          define LT_DLLAZY_OR_NOW	DL_NOW
92986#        else
92987#          define LT_DLLAZY_OR_NOW	0
92988#        endif
92989#      endif
92990#    endif
92991#  endif
92992#endif
92993
92994void fnord() { int i=42;}
92995int main ()
92996{
92997  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
92998  int status = $lt_dlunknown;
92999
93000  if (self)
93001    {
93002      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
93003      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
93004      /* dlclose (self); */
93005    }
93006  else
93007    puts (dlerror ());
93008
93009    return (status);
93010}
93011EOF
93012  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
93013  (eval $ac_link) 2>&5
93014  ac_status=$?
93015  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
93016  test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
93017    (./conftest; exit; ) >&5 2>/dev/null
93018    lt_status=$?
93019    case x$lt_status in
93020      x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
93021      x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
93022      x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
93023    esac
93024  else :
93025    # compilation failed
93026    lt_cv_dlopen_self=no
93027  fi
93028fi
93029rm -fr conftest*
93030
93031
93032fi
93033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
93034printf "%s\n" "$lt_cv_dlopen_self" >&6; }
93035
93036    if test "x$lt_cv_dlopen_self" = xyes; then
93037      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
93038      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
93039printf %s "checking whether a statically linked program can dlopen itself... " >&6; }
93040if test ${lt_cv_dlopen_self_static+y}
93041then :
93042  printf %s "(cached) " >&6
93043else $as_nop
93044  	  if test "$cross_compiling" = yes; then :
93045  lt_cv_dlopen_self_static=cross
93046else
93047  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
93048  lt_status=$lt_dlunknown
93049  cat > conftest.$ac_ext <<EOF
93050#line 93050 "configure"
93051#include "confdefs.h"
93052
93053#if HAVE_DLFCN_H
93054#include <dlfcn.h>
93055#endif
93056
93057#include <stdio.h>
93058#include <stdlib.h>
93059
93060#ifdef RTLD_GLOBAL
93061#  define LT_DLGLOBAL		RTLD_GLOBAL
93062#else
93063#  ifdef DL_GLOBAL
93064#    define LT_DLGLOBAL		DL_GLOBAL
93065#  else
93066#    define LT_DLGLOBAL		0
93067#  endif
93068#endif
93069
93070/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
93071   find out it does not work in some platform. */
93072#ifndef LT_DLLAZY_OR_NOW
93073#  ifdef RTLD_LAZY
93074#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
93075#  else
93076#    ifdef DL_LAZY
93077#      define LT_DLLAZY_OR_NOW		DL_LAZY
93078#    else
93079#      ifdef RTLD_NOW
93080#        define LT_DLLAZY_OR_NOW	RTLD_NOW
93081#      else
93082#        ifdef DL_NOW
93083#          define LT_DLLAZY_OR_NOW	DL_NOW
93084#        else
93085#          define LT_DLLAZY_OR_NOW	0
93086#        endif
93087#      endif
93088#    endif
93089#  endif
93090#endif
93091
93092void fnord() { int i=42;}
93093int main ()
93094{
93095  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
93096  int status = $lt_dlunknown;
93097
93098  if (self)
93099    {
93100      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
93101      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
93102      /* dlclose (self); */
93103    }
93104  else
93105    puts (dlerror ());
93106
93107    return (status);
93108}
93109EOF
93110  if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
93111  (eval $ac_link) 2>&5
93112  ac_status=$?
93113  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
93114  test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
93115    (./conftest; exit; ) >&5 2>/dev/null
93116    lt_status=$?
93117    case x$lt_status in
93118      x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
93119      x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
93120      x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
93121    esac
93122  else :
93123    # compilation failed
93124    lt_cv_dlopen_self_static=no
93125  fi
93126fi
93127rm -fr conftest*
93128
93129
93130fi
93131{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
93132printf "%s\n" "$lt_cv_dlopen_self_static" >&6; }
93133    fi
93134
93135    CPPFLAGS="$save_CPPFLAGS"
93136    LDFLAGS="$save_LDFLAGS"
93137    LIBS="$save_LIBS"
93138    ;;
93139  esac
93140
93141  case $lt_cv_dlopen_self in
93142  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
93143  *) enable_dlopen_self=unknown ;;
93144  esac
93145
93146  case $lt_cv_dlopen_self_static in
93147  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
93148  *) enable_dlopen_self_static=unknown ;;
93149  esac
93150fi
93151
93152
93153# Report which library types will actually be built
93154{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
93155printf %s "checking if libtool supports shared libraries... " >&6; }
93156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
93157printf "%s\n" "$can_build_shared" >&6; }
93158
93159{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
93160printf %s "checking whether to build shared libraries... " >&6; }
93161test "$can_build_shared" = "no" && enable_shared=no
93162
93163# On AIX, shared libraries and static libraries use the same namespace, and
93164# are all built from PIC.
93165case $host_os in
93166aix3*)
93167  test "$enable_shared" = yes && enable_static=no
93168  if test -n "$RANLIB"; then
93169    archive_cmds="$archive_cmds~\$RANLIB \$lib"
93170    postinstall_cmds='$RANLIB $lib'
93171  fi
93172  ;;
93173
93174aix[4-9]*)
93175  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
93176    test "$enable_shared" = yes && enable_static=no
93177  fi
93178    ;;
93179esac
93180{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
93181printf "%s\n" "$enable_shared" >&6; }
93182
93183{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
93184printf %s "checking whether to build static libraries... " >&6; }
93185# Make sure either enable_shared or enable_static is yes.
93186test "$enable_shared" = yes || enable_static=yes
93187{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
93188printf "%s\n" "$enable_static" >&6; }
93189
93190# The else clause should only fire when bootstrapping the
93191# libtool distribution, otherwise you forgot to ship ltmain.sh
93192# with your package, and you will get complaints that there are
93193# no rules to generate ltmain.sh.
93194if test -f "$ltmain"; then
93195  # See if we are running on zsh, and set the options which allow our commands through
93196  # without removal of \ escapes.
93197  if test -n "${ZSH_VERSION+set}" ; then
93198    setopt NO_GLOB_SUBST
93199  fi
93200  # Now quote all the things that may contain metacharacters while being
93201  # careful not to overquote the AC_SUBSTed values.  We take copies of the
93202  # variables and quote the copies for generation of the libtool script.
93203  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
93204    SED SHELL STRIP \
93205    libname_spec library_names_spec soname_spec extract_expsyms_cmds \
93206    old_striplib striplib file_magic_cmd finish_cmds finish_eval \
93207    deplibs_check_method reload_flag reload_cmds need_locks \
93208    lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
93209    lt_cv_sys_global_symbol_to_c_name_address \
93210    sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
93211    old_postinstall_cmds old_postuninstall_cmds \
93212    compiler \
93213    CC \
93214    LD \
93215    lt_prog_compiler_wl \
93216    lt_prog_compiler_pic \
93217    lt_prog_compiler_static \
93218    lt_prog_compiler_no_builtin_flag \
93219    export_dynamic_flag_spec \
93220    thread_safe_flag_spec \
93221    whole_archive_flag_spec \
93222    enable_shared_with_static_runtimes \
93223    old_archive_cmds \
93224    old_archive_from_new_cmds \
93225    predep_objects \
93226    postdep_objects \
93227    predeps \
93228    postdeps \
93229    compiler_lib_search_path \
93230    compiler_lib_search_dirs \
93231    archive_cmds \
93232    archive_expsym_cmds \
93233    postinstall_cmds \
93234    postuninstall_cmds \
93235    old_archive_from_expsyms_cmds \
93236    allow_undefined_flag \
93237    no_undefined_flag \
93238    export_symbols_cmds \
93239    hardcode_libdir_flag_spec \
93240    hardcode_libdir_flag_spec_ld \
93241    hardcode_libdir_separator \
93242    hardcode_automatic \
93243    module_cmds \
93244    module_expsym_cmds \
93245    lt_cv_prog_compiler_c_o \
93246    fix_srcfile_path \
93247    exclude_expsyms \
93248    include_expsyms; do
93249
93250    case $var in
93251    old_archive_cmds | \
93252    old_archive_from_new_cmds | \
93253    archive_cmds | \
93254    archive_expsym_cmds | \
93255    module_cmds | \
93256    module_expsym_cmds | \
93257    old_archive_from_expsyms_cmds | \
93258    export_symbols_cmds | \
93259    extract_expsyms_cmds | reload_cmds | finish_cmds | \
93260    postinstall_cmds | postuninstall_cmds | \
93261    old_postinstall_cmds | old_postuninstall_cmds | \
93262    sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
93263      # Double-quote double-evaled strings.
93264      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
93265      ;;
93266    *)
93267      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
93268      ;;
93269    esac
93270  done
93271
93272  case $lt_echo in
93273  *'\$0 --fallback-echo"')
93274    lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
93275    ;;
93276  esac
93277
93278cfgfile="${ofile}T"
93279  trap "$rm \"$cfgfile\"; exit 1" 1 2 15
93280  $rm -f "$cfgfile"
93281  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result:
93282creating $ofile" >&5
93283printf "%s\n" "
93284creating $ofile" >&6; }
93285
93286  cat <<__EOF__ >> "$cfgfile"
93287#! $SHELL
93288
93289# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
93290# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
93291# NOTE: Changes made to this file will be lost: look at ltmain.sh.
93292#
93293# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
93294# Free Software Foundation, Inc.
93295#
93296# This file is part of GNU Libtool:
93297# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
93298#
93299# This program is free software; you can redistribute it and/or modify
93300# it under the terms of the GNU General Public License as published by
93301# the Free Software Foundation; either version 2 of the License, or
93302# (at your option) any later version.
93303#
93304# This program is distributed in the hope that it will be useful, but
93305# WITHOUT ANY WARRANTY; without even the implied warranty of
93306# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
93307# General Public License for more details.
93308#
93309# You should have received a copy of the GNU General Public License
93310# along with this program; if not, write to the Free Software
93311# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
93312#
93313# As a special exception to the GNU General Public License, if you
93314# distribute this file as part of a program that contains a
93315# configuration script generated by Autoconf, you may include it under
93316# the same distribution terms that you use for the rest of that program.
93317
93318# A sed program that does not truncate output.
93319SED=$lt_SED
93320
93321# Sed that helps us avoid accidentally triggering echo(1) options like -n.
93322Xsed="$SED -e 1s/^X//"
93323
93324# The HP-UX ksh and POSIX shell print the target directory to stdout
93325# if CDPATH is set.
93326(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
93327
93328# The names of the tagged configurations supported by this script.
93329available_tags=
93330
93331# ### BEGIN LIBTOOL CONFIG
93332
93333# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
93334
93335# Shell to use when invoking shell scripts.
93336SHELL=$lt_SHELL
93337
93338# Whether or not to build shared libraries.
93339build_libtool_libs=$enable_shared
93340
93341# Whether or not to build static libraries.
93342build_old_libs=$enable_static
93343
93344# Whether or not to add -lc for building shared libraries.
93345build_libtool_need_lc=$archive_cmds_need_lc
93346
93347# Whether or not to disallow shared libs when runtime libs are static
93348allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
93349
93350# Whether or not to optimize for fast installation.
93351fast_install=$enable_fast_install
93352
93353# The host system.
93354host_alias=$host_alias
93355host=$host
93356host_os=$host_os
93357
93358# The build system.
93359build_alias=$build_alias
93360build=$build
93361build_os=$build_os
93362
93363# An echo program that does not interpret backslashes.
93364echo=$lt_echo
93365
93366# The archiver.
93367AR=$lt_AR
93368AR_FLAGS=$lt_AR_FLAGS
93369
93370# A C compiler.
93371LTCC=$lt_LTCC
93372
93373# LTCC compiler flags.
93374LTCFLAGS=$lt_LTCFLAGS
93375
93376# A language-specific compiler.
93377CC=$lt_compiler
93378
93379# Is the compiler the GNU C compiler?
93380with_gcc=$GCC
93381
93382# An ERE matcher.
93383EGREP=$lt_EGREP
93384
93385# The linker used to build libraries.
93386LD=$lt_LD
93387
93388# Whether we need hard or soft links.
93389LN_S=$lt_LN_S
93390
93391# A BSD-compatible nm program.
93392NM=$lt_NM
93393
93394# A symbol stripping program
93395STRIP=$lt_STRIP
93396
93397# Used to examine libraries when file_magic_cmd begins "file"
93398MAGIC_CMD=$MAGIC_CMD
93399
93400# Used on cygwin: DLL creation program.
93401DLLTOOL="$DLLTOOL"
93402
93403# Used on cygwin: object dumper.
93404OBJDUMP="$OBJDUMP"
93405
93406# Used on cygwin: assembler.
93407AS="$AS"
93408
93409# The name of the directory that contains temporary libtool files.
93410objdir=$objdir
93411
93412# How to create reloadable object files.
93413reload_flag=$lt_reload_flag
93414reload_cmds=$lt_reload_cmds
93415
93416# How to pass a linker flag through the compiler.
93417wl=$lt_lt_prog_compiler_wl
93418
93419# Object file suffix (normally "o").
93420objext="$ac_objext"
93421
93422# Old archive suffix (normally "a").
93423libext="$libext"
93424
93425# Shared library suffix (normally ".so").
93426shrext_cmds='$shrext_cmds'
93427
93428# Executable file suffix (normally "").
93429exeext="$exeext"
93430
93431# Additional compiler flags for building library objects.
93432pic_flag=$lt_lt_prog_compiler_pic
93433pic_mode=$pic_mode
93434
93435# What is the maximum length of a command?
93436max_cmd_len=$lt_cv_sys_max_cmd_len
93437
93438# Does compiler simultaneously support -c and -o options?
93439compiler_c_o=$lt_lt_cv_prog_compiler_c_o
93440
93441# Must we lock files when doing compilation?
93442need_locks=$lt_need_locks
93443
93444# Do we need the lib prefix for modules?
93445need_lib_prefix=$need_lib_prefix
93446
93447# Do we need a version for libraries?
93448need_version=$need_version
93449
93450# Whether dlopen is supported.
93451dlopen_support=$enable_dlopen
93452
93453# Whether dlopen of programs is supported.
93454dlopen_self=$enable_dlopen_self
93455
93456# Whether dlopen of statically linked programs is supported.
93457dlopen_self_static=$enable_dlopen_self_static
93458
93459# Compiler flag to prevent dynamic linking.
93460link_static_flag=$lt_lt_prog_compiler_static
93461
93462# Compiler flag to turn off builtin functions.
93463no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
93464
93465# Compiler flag to allow reflexive dlopens.
93466export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
93467
93468# Compiler flag to generate shared objects directly from archives.
93469whole_archive_flag_spec=$lt_whole_archive_flag_spec
93470
93471# Compiler flag to generate thread-safe objects.
93472thread_safe_flag_spec=$lt_thread_safe_flag_spec
93473
93474# Library versioning type.
93475version_type=$version_type
93476
93477# Format of library name prefix.
93478libname_spec=$lt_libname_spec
93479
93480# List of archive names.  First name is the real one, the rest are links.
93481# The last name is the one that the linker finds with -lNAME.
93482library_names_spec=$lt_library_names_spec
93483
93484# The coded name of the library, if different from the real name.
93485soname_spec=$lt_soname_spec
93486
93487# Commands used to build and install an old-style archive.
93488RANLIB=$lt_RANLIB
93489old_archive_cmds=$lt_old_archive_cmds
93490old_postinstall_cmds=$lt_old_postinstall_cmds
93491old_postuninstall_cmds=$lt_old_postuninstall_cmds
93492
93493# Create an old-style archive from a shared archive.
93494old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
93495
93496# Create a temporary old-style archive to link instead of a shared archive.
93497old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
93498
93499# Commands used to build and install a shared archive.
93500archive_cmds=$lt_archive_cmds
93501archive_expsym_cmds=$lt_archive_expsym_cmds
93502postinstall_cmds=$lt_postinstall_cmds
93503postuninstall_cmds=$lt_postuninstall_cmds
93504
93505# Commands used to build a loadable module (assumed same as above if empty)
93506module_cmds=$lt_module_cmds
93507module_expsym_cmds=$lt_module_expsym_cmds
93508
93509# Commands to strip libraries.
93510old_striplib=$lt_old_striplib
93511striplib=$lt_striplib
93512
93513# Dependencies to place before the objects being linked to create a
93514# shared library.
93515predep_objects=$lt_predep_objects
93516
93517# Dependencies to place after the objects being linked to create a
93518# shared library.
93519postdep_objects=$lt_postdep_objects
93520
93521# Dependencies to place before the objects being linked to create a
93522# shared library.
93523predeps=$lt_predeps
93524
93525# Dependencies to place after the objects being linked to create a
93526# shared library.
93527postdeps=$lt_postdeps
93528
93529# The directories searched by this compiler when creating a shared
93530# library
93531compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
93532
93533# The library search path used internally by the compiler when linking
93534# a shared library.
93535compiler_lib_search_path=$lt_compiler_lib_search_path
93536
93537# Method to check whether dependent libraries are shared objects.
93538deplibs_check_method=$lt_deplibs_check_method
93539
93540# Command to use when deplibs_check_method == file_magic.
93541file_magic_cmd=$lt_file_magic_cmd
93542
93543# Flag that allows shared libraries with undefined symbols to be built.
93544allow_undefined_flag=$lt_allow_undefined_flag
93545
93546# Flag that forces no undefined symbols.
93547no_undefined_flag=$lt_no_undefined_flag
93548
93549# Commands used to finish a libtool library installation in a directory.
93550finish_cmds=$lt_finish_cmds
93551
93552# Same as above, but a single script fragment to be evaled but not shown.
93553finish_eval=$lt_finish_eval
93554
93555# Take the output of nm and produce a listing of raw symbols and C names.
93556global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
93557
93558# Transform the output of nm in a proper C declaration
93559global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
93560
93561# Transform the output of nm in a C name address pair
93562global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
93563
93564# This is the shared library runtime path variable.
93565runpath_var=$runpath_var
93566
93567# This is the shared library path variable.
93568shlibpath_var=$shlibpath_var
93569
93570# Is shlibpath searched before the hard-coded library search path?
93571shlibpath_overrides_runpath=$shlibpath_overrides_runpath
93572
93573# How to hardcode a shared library path into an executable.
93574hardcode_action=$hardcode_action
93575
93576# Whether we should hardcode library paths into libraries.
93577hardcode_into_libs=$hardcode_into_libs
93578
93579# Flag to hardcode \$libdir into a binary during linking.
93580# This must work even if \$libdir does not exist.
93581hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
93582
93583# If ld is used when linking, flag to hardcode \$libdir into
93584# a binary during linking. This must work even if \$libdir does
93585# not exist.
93586hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
93587
93588# Whether we need a single -rpath flag with a separated argument.
93589hardcode_libdir_separator=$lt_hardcode_libdir_separator
93590
93591# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
93592# resulting binary.
93593hardcode_direct=$hardcode_direct
93594
93595# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
93596# resulting binary.
93597hardcode_minus_L=$hardcode_minus_L
93598
93599# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
93600# the resulting binary.
93601hardcode_shlibpath_var=$hardcode_shlibpath_var
93602
93603# Set to yes if building a shared library automatically hardcodes DIR into the library
93604# and all subsequent libraries and executables linked against it.
93605hardcode_automatic=$hardcode_automatic
93606
93607# Variables whose values should be saved in libtool wrapper scripts and
93608# restored at relink time.
93609variables_saved_for_relink="$variables_saved_for_relink"
93610
93611# Whether libtool must link a program against all its dependency libraries.
93612link_all_deplibs=$link_all_deplibs
93613
93614# Compile-time system search path for libraries
93615sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
93616
93617# Run-time system search path for libraries
93618sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
93619
93620# Fix the shell variable \$srcfile for the compiler.
93621fix_srcfile_path=$lt_fix_srcfile_path
93622
93623# Set to yes if exported symbols are required.
93624always_export_symbols=$always_export_symbols
93625
93626# The commands to list exported symbols.
93627export_symbols_cmds=$lt_export_symbols_cmds
93628
93629# The commands to extract the exported symbol list from a shared archive.
93630extract_expsyms_cmds=$lt_extract_expsyms_cmds
93631
93632# Symbols that should not be listed in the preloaded symbols.
93633exclude_expsyms=$lt_exclude_expsyms
93634
93635# Symbols that must always be exported.
93636include_expsyms=$lt_include_expsyms
93637
93638# ### END LIBTOOL CONFIG
93639
93640__EOF__
93641
93642
93643  case $host_os in
93644  aix3*)
93645    cat <<\EOF >> "$cfgfile"
93646
93647# AIX sometimes has problems with the GCC collect2 program.  For some
93648# reason, if we set the COLLECT_NAMES environment variable, the problems
93649# vanish in a puff of smoke.
93650if test "X${COLLECT_NAMES+set}" != Xset; then
93651  COLLECT_NAMES=
93652  export COLLECT_NAMES
93653fi
93654EOF
93655    ;;
93656  esac
93657
93658  # We use sed instead of cat because bash on DJGPP gets confused if
93659  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
93660  # text mode, it properly converts lines to CR/LF.  This bash problem
93661  # is reportedly fixed, but why not run on old versions too?
93662  sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
93663
93664  mv -f "$cfgfile" "$ofile" || \
93665    (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
93666  chmod +x "$ofile"
93667
93668else
93669  # If there is no Makefile yet, we rely on a make rule to execute
93670  # `config.status --recheck' to rerun these tests and create the
93671  # libtool script then.
93672  ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
93673  if test -f "$ltmain_in"; then
93674    test -f Makefile && make "$ltmain"
93675  fi
93676fi
93677
93678
93679ac_ext=c
93680ac_cpp='$CPP $CPPFLAGS'
93681ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
93682ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
93683ac_compiler_gnu=$ac_cv_c_compiler_gnu
93684
93685CC="$lt_save_CC"
93686
93687
93688# Check whether --with-tags was given.
93689if test ${with_tags+y}
93690then :
93691  withval=$with_tags; tagnames="$withval"
93692fi
93693
93694
93695if test -f "$ltmain" && test -n "$tagnames"; then
93696  if test ! -f "${ofile}"; then
93697    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not exist" >&5
93698printf "%s\n" "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
93699  fi
93700
93701  if test -z "$LTCC"; then
93702    eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
93703    if test -z "$LTCC"; then
93704      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: output file \`$ofile' does not look like a libtool script" >&5
93705printf "%s\n" "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
93706    else
93707      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
93708printf "%s\n" "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
93709    fi
93710  fi
93711  if test -z "$LTCFLAGS"; then
93712    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
93713  fi
93714
93715  # Extract list of available tagged configurations in $ofile.
93716  # Note that this assumes the entire list is on one line.
93717  available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
93718
93719  lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
93720  for tagname in $tagnames; do
93721    IFS="$lt_save_ifs"
93722    # Check whether tagname contains only valid characters
93723    case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
93724    "") ;;
93725    *)  as_fn_error $? "invalid tag name: $tagname" "$LINENO" 5
93726	;;
93727    esac
93728
93729    if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
93730    then
93731      as_fn_error $? "tag name \"$tagname\" already exists" "$LINENO" 5
93732    fi
93733
93734    # Update the list of available tags.
93735    if test -n "$tagname"; then
93736      echo appending configuration tag \"$tagname\" to $ofile
93737
93738      case $tagname in
93739      CXX)
93740	if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
93741	    ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
93742	    (test "X$CXX" != "Xg++"))) ; then
93743
93744ac_ext=cpp
93745ac_cpp='$CXXCPP $CPPFLAGS'
93746ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
93747ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
93748ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
93749
93750
93751
93752
93753archive_cmds_need_lc_CXX=no
93754allow_undefined_flag_CXX=
93755always_export_symbols_CXX=no
93756archive_expsym_cmds_CXX=
93757export_dynamic_flag_spec_CXX=
93758hardcode_direct_CXX=no
93759hardcode_libdir_flag_spec_CXX=
93760hardcode_libdir_flag_spec_ld_CXX=
93761hardcode_libdir_separator_CXX=
93762hardcode_minus_L_CXX=no
93763hardcode_shlibpath_var_CXX=unsupported
93764hardcode_automatic_CXX=no
93765module_cmds_CXX=
93766module_expsym_cmds_CXX=
93767link_all_deplibs_CXX=unknown
93768old_archive_cmds_CXX=$old_archive_cmds
93769no_undefined_flag_CXX=
93770whole_archive_flag_spec_CXX=
93771enable_shared_with_static_runtimes_CXX=no
93772
93773# Dependencies to place before and after the object being linked:
93774predep_objects_CXX=
93775postdep_objects_CXX=
93776predeps_CXX=
93777postdeps_CXX=
93778compiler_lib_search_path_CXX=
93779compiler_lib_search_dirs_CXX=
93780
93781# Source file extension for C++ test sources.
93782ac_ext=cpp
93783
93784# Object file extension for compiled C++ test sources.
93785objext=o
93786objext_CXX=$objext
93787
93788# Code to be used in simple compile tests
93789lt_simple_compile_test_code="int some_variable = 0;"
93790
93791# Code to be used in simple link tests
93792lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
93793
93794# ltmain only uses $CC for tagged configurations so make sure $CC is set.
93795
93796# If no C compiler was specified, use CC.
93797LTCC=${LTCC-"$CC"}
93798
93799# If no C compiler flags were specified, use CFLAGS.
93800LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
93801
93802# Allow CC to be a program name with arguments.
93803compiler=$CC
93804
93805
93806# save warnings/boilerplate of simple test code
93807ac_outfile=conftest.$ac_objext
93808echo "$lt_simple_compile_test_code" >conftest.$ac_ext
93809eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
93810_lt_compiler_boilerplate=`cat conftest.err`
93811$rm conftest*
93812
93813ac_outfile=conftest.$ac_objext
93814echo "$lt_simple_link_test_code" >conftest.$ac_ext
93815eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
93816_lt_linker_boilerplate=`cat conftest.err`
93817$rm -r conftest*
93818
93819
93820# Allow CC to be a program name with arguments.
93821lt_save_CC=$CC
93822lt_save_LD=$LD
93823lt_save_GCC=$GCC
93824GCC=$GXX
93825lt_save_with_gnu_ld=$with_gnu_ld
93826lt_save_path_LD=$lt_cv_path_LD
93827if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
93828  lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
93829else
93830  unset lt_cv_prog_gnu_ld
93831fi
93832if test -n "${lt_cv_path_LDCXX+set}"; then
93833  lt_cv_path_LD=$lt_cv_path_LDCXX
93834else
93835  unset lt_cv_path_LD
93836fi
93837test -z "${LDCXX+set}" || LD=$LDCXX
93838CC=${CXX-"c++"}
93839compiler=$CC
93840compiler_CXX=$CC
93841for cc_temp in $compiler""; do
93842  case $cc_temp in
93843    compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
93844    distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
93845    \-*) ;;
93846    *) break;;
93847  esac
93848done
93849cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
93850
93851
93852# We don't want -fno-exception wen compiling C++ code, so set the
93853# no_builtin_flag separately
93854if test "$GXX" = yes; then
93855  lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
93856else
93857  lt_prog_compiler_no_builtin_flag_CXX=
93858fi
93859
93860if test "$GXX" = yes; then
93861  # Set up default GNU C++ configuration
93862
93863
93864# Check whether --with-gnu-ld was given.
93865if test ${with_gnu_ld+y}
93866then :
93867  withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
93868else $as_nop
93869  with_gnu_ld=no
93870fi
93871
93872ac_prog=ld
93873if test "$GCC" = yes; then
93874  # Check if gcc -print-prog-name=ld gives a path.
93875  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
93876printf %s "checking for ld used by $CC... " >&6; }
93877  case $host in
93878  *-*-mingw*)
93879    # gcc leaves a trailing carriage return which upsets mingw
93880    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
93881  *)
93882    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
93883  esac
93884  case $ac_prog in
93885    # Accept absolute paths.
93886    [\\/]* | ?:[\\/]*)
93887      re_direlt='/[^/][^/]*/\.\./'
93888      # Canonicalize the pathname of ld
93889      ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
93890      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
93891	ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
93892      done
93893      test -z "$LD" && LD="$ac_prog"
93894      ;;
93895  "")
93896    # If it fails, then pretend we aren't using GCC.
93897    ac_prog=ld
93898    ;;
93899  *)
93900    # If it is relative, then search for the first ld in PATH.
93901    with_gnu_ld=unknown
93902    ;;
93903  esac
93904elif test "$with_gnu_ld" = yes; then
93905  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
93906printf %s "checking for GNU ld... " >&6; }
93907else
93908  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
93909printf %s "checking for non-GNU ld... " >&6; }
93910fi
93911if test ${lt_cv_path_LD+y}
93912then :
93913  printf %s "(cached) " >&6
93914else $as_nop
93915  if test -z "$LD"; then
93916  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
93917  for ac_dir in $PATH; do
93918    IFS="$lt_save_ifs"
93919    test -z "$ac_dir" && ac_dir=.
93920    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
93921      lt_cv_path_LD="$ac_dir/$ac_prog"
93922      # Check to see if the program is GNU ld.  I'd rather use --version,
93923      # but apparently some variants of GNU ld only accept -v.
93924      # Break only if it was the GNU/non-GNU ld that we prefer.
93925      case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
93926      *GNU* | *'with BFD'*)
93927	test "$with_gnu_ld" != no && break
93928	;;
93929      *)
93930	test "$with_gnu_ld" != yes && break
93931	;;
93932      esac
93933    fi
93934  done
93935  IFS="$lt_save_ifs"
93936else
93937  lt_cv_path_LD="$LD" # Let the user override the test with a path.
93938fi
93939fi
93940
93941LD="$lt_cv_path_LD"
93942if test -n "$LD"; then
93943  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
93944printf "%s\n" "$LD" >&6; }
93945else
93946  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
93947printf "%s\n" "no" >&6; }
93948fi
93949test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
93950{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
93951printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
93952if test ${lt_cv_prog_gnu_ld+y}
93953then :
93954  printf %s "(cached) " >&6
93955else $as_nop
93956  # I'd rather use --version here, but apparently some GNU lds only accept -v.
93957case `$LD -v 2>&1 </dev/null` in
93958*GNU* | *'with BFD'*)
93959  lt_cv_prog_gnu_ld=yes
93960  ;;
93961*)
93962  lt_cv_prog_gnu_ld=no
93963  ;;
93964esac
93965fi
93966{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
93967printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; }
93968with_gnu_ld=$lt_cv_prog_gnu_ld
93969
93970
93971
93972  # Check if GNU C++ uses GNU ld as the underlying linker, since the
93973  # archiving commands below assume that GNU ld is being used.
93974  if test "$with_gnu_ld" = yes; then
93975    archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
93976    archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
93977
93978    hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
93979    export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
93980
93981    # If archive_cmds runs LD, not CC, wlarc should be empty
93982    # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
93983    #     investigate it a little bit more. (MM)
93984    wlarc='${wl}'
93985
93986    # ancient GNU ld didn't support --whole-archive et. al.
93987    if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
93988	grep 'no-whole-archive' > /dev/null; then
93989      whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
93990    else
93991      whole_archive_flag_spec_CXX=
93992    fi
93993  else
93994    with_gnu_ld=no
93995    wlarc=
93996
93997    # A generic and very simple default shared library creation
93998    # command for GNU C++ for the case where it uses the native
93999    # linker, instead of GNU ld.  If possible, this setting should
94000    # overridden to take advantage of the native linker features on
94001    # the platform it is being used on.
94002    archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
94003  fi
94004
94005  # Commands to make compiler produce verbose output that lists
94006  # what "hidden" libraries, object files and flags are used when
94007  # linking a shared library.
94008  output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
94009
94010else
94011  GXX=no
94012  with_gnu_ld=no
94013  wlarc=
94014fi
94015
94016# PORTME: fill in a description of your system's C++ link characteristics
94017{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
94018printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
94019ld_shlibs_CXX=yes
94020case $host_os in
94021  aix3*)
94022    # FIXME: insert proper C++ library support
94023    ld_shlibs_CXX=no
94024    ;;
94025  aix[4-9]*)
94026    if test "$host_cpu" = ia64; then
94027      # On IA64, the linker does run time linking by default, so we don't
94028      # have to do anything special.
94029      aix_use_runtimelinking=no
94030      exp_sym_flag='-Bexport'
94031      no_entry_flag=""
94032    else
94033      aix_use_runtimelinking=no
94034
94035      # Test if we are trying to use run time linking or normal
94036      # AIX style linking. If -brtl is somewhere in LDFLAGS, we
94037      # need to do runtime linking.
94038      case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
94039	for ld_flag in $LDFLAGS; do
94040	  case $ld_flag in
94041	  *-brtl*)
94042	    aix_use_runtimelinking=yes
94043	    break
94044	    ;;
94045	  esac
94046	done
94047	;;
94048      esac
94049
94050      exp_sym_flag='-bexport'
94051      no_entry_flag='-bnoentry'
94052    fi
94053
94054    # When large executables or shared objects are built, AIX ld can
94055    # have problems creating the table of contents.  If linking a library
94056    # or program results in "error TOC overflow" add -mminimal-toc to
94057    # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
94058    # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
94059
94060    archive_cmds_CXX=''
94061    hardcode_direct_CXX=yes
94062    hardcode_libdir_separator_CXX=':'
94063    link_all_deplibs_CXX=yes
94064
94065    if test "$GXX" = yes; then
94066      case $host_os in aix4.[012]|aix4.[012].*)
94067      # We only want to do this on AIX 4.2 and lower, the check
94068      # below for broken collect2 doesn't work under 4.3+
94069	collect2name=`${CC} -print-prog-name=collect2`
94070	if test -f "$collect2name" && \
94071	   strings "$collect2name" | grep resolve_lib_name >/dev/null
94072	then
94073	  # We have reworked collect2
94074	  :
94075	else
94076	  # We have old collect2
94077	  hardcode_direct_CXX=unsupported
94078	  # It fails to find uninstalled libraries when the uninstalled
94079	  # path is not listed in the libpath.  Setting hardcode_minus_L
94080	  # to unsupported forces relinking
94081	  hardcode_minus_L_CXX=yes
94082	  hardcode_libdir_flag_spec_CXX='-L$libdir'
94083	  hardcode_libdir_separator_CXX=
94084	fi
94085	;;
94086      esac
94087      shared_flag='-shared'
94088      if test "$aix_use_runtimelinking" = yes; then
94089	shared_flag="$shared_flag "'${wl}-G'
94090      fi
94091    else
94092      # not using gcc
94093      if test "$host_cpu" = ia64; then
94094	# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
94095	# chokes on -Wl,-G. The following line is correct:
94096	shared_flag='-G'
94097      else
94098	if test "$aix_use_runtimelinking" = yes; then
94099	  shared_flag='${wl}-G'
94100	else
94101	  shared_flag='${wl}-bM:SRE'
94102	fi
94103      fi
94104    fi
94105
94106    # It seems that -bexpall does not export symbols beginning with
94107    # underscore (_), so it is better to generate a list of symbols to export.
94108    always_export_symbols_CXX=yes
94109    if test "$aix_use_runtimelinking" = yes; then
94110      # Warning - without using the other runtime loading flags (-brtl),
94111      # -berok will link without error, but may produce a broken library.
94112      allow_undefined_flag_CXX='-berok'
94113      # Determine the default libpath from the value encoded in an empty executable.
94114
94115cat > conftest.$ac_ext <<EOF
94116#line 94116 "configure"
94117#include "confdefs.h"
94118int main() {
94119; return 0; }
94120EOF
94121if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
94122  (eval $ac_link) 2>&5
94123  ac_status=$?
94124  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
94125  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
94126
94127lt_aix_libpath_sed='
94128    /Import File Strings/,/^$/ {
94129	/^0/ {
94130	    s/^0  *\(.*\)$/\1/
94131	    p
94132	}
94133    }'
94134aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
94135# Check for a 64-bit object if we didn't find anything.
94136if test -z "$aix_libpath"; then
94137  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
94138fi
94139  rm -rf conftest*
94140else
94141  echo "configure: failed program was:" >&5
94142  cat conftest.$ac_ext >&6
94143fi
94144rm -f conftest*
94145if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
94146
94147      hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
94148
94149      archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
94150     else
94151      if test "$host_cpu" = ia64; then
94152	hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
94153	allow_undefined_flag_CXX="-z nodefs"
94154	archive_expsym_cmds_CXX="\$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"
94155      else
94156	# Determine the default libpath from the value encoded in an empty executable.
94157
94158cat > conftest.$ac_ext <<EOF
94159#line 94159 "configure"
94160#include "confdefs.h"
94161int main() {
94162; return 0; }
94163EOF
94164if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
94165  (eval $ac_link) 2>&5
94166  ac_status=$?
94167  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
94168  test $ac_status = 0; } && test -s conftest${ac_exeext}; then
94169
94170lt_aix_libpath_sed='
94171    /Import File Strings/,/^$/ {
94172	/^0/ {
94173	    s/^0  *\(.*\)$/\1/
94174	    p
94175	}
94176    }'
94177aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
94178# Check for a 64-bit object if we didn't find anything.
94179if test -z "$aix_libpath"; then
94180  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
94181fi
94182  rm -rf conftest*
94183else
94184  echo "configure: failed program was:" >&5
94185  cat conftest.$ac_ext >&6
94186fi
94187rm -f conftest*
94188if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
94189
94190	hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
94191	# Warning - without using the other run time loading flags,
94192	# -berok will link without error, but may produce a broken library.
94193	no_undefined_flag_CXX=' ${wl}-bernotok'
94194	allow_undefined_flag_CXX=' ${wl}-berok'
94195	# Exported symbols can be pulled into shared objects from archives
94196	whole_archive_flag_spec_CXX='$convenience'
94197	archive_cmds_need_lc_CXX=yes
94198	# This is similar to how AIX traditionally builds its shared libraries.
94199	archive_expsym_cmds_CXX="\$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'
94200      fi
94201    fi
94202    ;;
94203
94204  beos*)
94205    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
94206      allow_undefined_flag_CXX=unsupported
94207      # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
94208      # support --undefined.  This deserves some investigation.  FIXME
94209      archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
94210    else
94211      ld_shlibs_CXX=no
94212    fi
94213    ;;
94214
94215  chorus*)
94216    case $cc_basename in
94217      *)
94218	# FIXME: insert proper C++ library support
94219	ld_shlibs_CXX=no
94220	;;
94221    esac
94222    ;;
94223
94224  cygwin* | mingw* | pw32*)
94225    # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
94226    # as there is no search path for DLLs.
94227    hardcode_libdir_flag_spec_CXX='-L$libdir'
94228    allow_undefined_flag_CXX=unsupported
94229    always_export_symbols_CXX=no
94230    enable_shared_with_static_runtimes_CXX=yes
94231
94232    if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
94233      archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
94234      # If the export-symbols file already is a .def file (1st line
94235      # is EXPORTS), use it as is; otherwise, prepend...
94236      archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
94237	cp $export_symbols $output_objdir/$soname.def;
94238      else
94239	echo EXPORTS > $output_objdir/$soname.def;
94240	cat $export_symbols >> $output_objdir/$soname.def;
94241      fi~
94242      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
94243    else
94244      ld_shlibs_CXX=no
94245    fi
94246  ;;
94247      darwin* | rhapsody*)
94248      archive_cmds_need_lc_CXX=no
94249      hardcode_direct_CXX=no
94250      hardcode_automatic_CXX=yes
94251      hardcode_shlibpath_var_CXX=unsupported
94252      whole_archive_flag_spec_CXX=''
94253      link_all_deplibs_CXX=yes
94254      allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
94255      if test "$GXX" = yes ; then
94256      output_verbose_link_cmd='echo'
94257      archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
94258      module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
94259      archive_expsym_cmds_CXX="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}"
94260      module_expsym_cmds_CXX="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}"
94261      if test "$lt_cv_apple_cc_single_mod" != "yes"; then
94262        archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
94263        archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
94264      fi
94265      else
94266      case $cc_basename in
94267        xlc*)
94268         output_verbose_link_cmd='echo'
94269          archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
94270          module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
94271          # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
94272          archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
94273          module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
94274          ;;
94275       *)
94276         ld_shlibs_CXX=no
94277          ;;
94278      esac
94279      fi
94280        ;;
94281
94282  dgux*)
94283    case $cc_basename in
94284      ec++*)
94285	# FIXME: insert proper C++ library support
94286	ld_shlibs_CXX=no
94287	;;
94288      ghcx*)
94289	# Green Hills C++ Compiler
94290	# FIXME: insert proper C++ library support
94291	ld_shlibs_CXX=no
94292	;;
94293      *)
94294	# FIXME: insert proper C++ library support
94295	ld_shlibs_CXX=no
94296	;;
94297    esac
94298    ;;
94299  freebsd[12].*)
94300    # C++ shared libraries reported to be fairly broken before switch to ELF
94301    ld_shlibs_CXX=no
94302    ;;
94303  freebsd-elf*)
94304    archive_cmds_need_lc_CXX=no
94305    ;;
94306  freebsd* | dragonfly*)
94307    # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
94308    # conventions
94309    ld_shlibs_CXX=yes
94310    ;;
94311  gnu*)
94312    ;;
94313  hpux9*)
94314    hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
94315    hardcode_libdir_separator_CXX=:
94316    export_dynamic_flag_spec_CXX='${wl}-E'
94317    hardcode_direct_CXX=yes
94318    hardcode_minus_L_CXX=yes # Not in the search PATH,
94319				# but as the default
94320				# location of the library.
94321
94322    case $cc_basename in
94323    CC*)
94324      # FIXME: insert proper C++ library support
94325      ld_shlibs_CXX=no
94326      ;;
94327    aCC*)
94328      archive_cmds_CXX='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
94329      # Commands to make compiler produce verbose output that lists
94330      # what "hidden" libraries, object files and flags are used when
94331      # linking a shared library.
94332      #
94333      # There doesn't appear to be a way to prevent this compiler from
94334      # explicitly linking system object files so we need to strip them
94335      # from the output so that they don't get included in the library
94336      # dependencies.
94337      output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94338      ;;
94339    *)
94340      if test "$GXX" = yes; then
94341        archive_cmds_CXX='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
94342      else
94343        # FIXME: insert proper C++ library support
94344        ld_shlibs_CXX=no
94345      fi
94346      ;;
94347    esac
94348    ;;
94349  hpux10*|hpux11*)
94350    if test $with_gnu_ld = no; then
94351      hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
94352      hardcode_libdir_separator_CXX=:
94353
94354      case $host_cpu in
94355      hppa*64*|ia64*) ;;
94356      *)
94357	export_dynamic_flag_spec_CXX='${wl}-E'
94358        ;;
94359      esac
94360    fi
94361    case $host_cpu in
94362    hppa*64*|ia64*)
94363      hardcode_direct_CXX=no
94364      hardcode_shlibpath_var_CXX=no
94365      ;;
94366    *)
94367      hardcode_direct_CXX=yes
94368      hardcode_minus_L_CXX=yes # Not in the search PATH,
94369					      # but as the default
94370					      # location of the library.
94371      ;;
94372    esac
94373
94374    case $cc_basename in
94375      CC*)
94376	# FIXME: insert proper C++ library support
94377	ld_shlibs_CXX=no
94378	;;
94379      aCC*)
94380	case $host_cpu in
94381	hppa*64*)
94382	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94383	  ;;
94384	ia64*)
94385	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94386	  ;;
94387	*)
94388	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94389	  ;;
94390	esac
94391	# Commands to make compiler produce verbose output that lists
94392	# what "hidden" libraries, object files and flags are used when
94393	# linking a shared library.
94394	#
94395	# There doesn't appear to be a way to prevent this compiler from
94396	# explicitly linking system object files so we need to strip them
94397	# from the output so that they don't get included in the library
94398	# dependencies.
94399	output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94400	;;
94401      *)
94402	if test "$GXX" = yes; then
94403	  if test $with_gnu_ld = no; then
94404	    case $host_cpu in
94405	    hppa*64*)
94406	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94407	      ;;
94408	    ia64*)
94409	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94410	      ;;
94411	    *)
94412	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94413	      ;;
94414	    esac
94415	  fi
94416	else
94417	  # FIXME: insert proper C++ library support
94418	  ld_shlibs_CXX=no
94419	fi
94420	;;
94421    esac
94422    ;;
94423  interix[3-9]*)
94424    hardcode_direct_CXX=no
94425    hardcode_shlibpath_var_CXX=no
94426    hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
94427    export_dynamic_flag_spec_CXX='${wl}-E'
94428    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
94429    # Instead, shared libraries are loaded at an image base (0x10000000 by
94430    # default) and relocated if they conflict, which is a slow very memory
94431    # consuming and fragmenting process.  To avoid this, we pick a random,
94432    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
94433    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
94434    archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
94435    archive_expsym_cmds_CXX='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'
94436    ;;
94437  irix5* | irix6*)
94438    case $cc_basename in
94439      CC*)
94440	# SGI C++
94441	archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
94442
94443	# Archives containing C++ object files must be created using
94444	# "CC -ar", where "CC" is the IRIX C++ compiler.  This is
94445	# necessary to make sure instantiated templates are included
94446	# in the archive.
94447	old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
94448	;;
94449      *)
94450	if test "$GXX" = yes; then
94451	  if test "$with_gnu_ld" = no; then
94452	    archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
94453	  else
94454	    archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
94455	  fi
94456	fi
94457	link_all_deplibs_CXX=yes
94458	;;
94459    esac
94460    hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
94461    hardcode_libdir_separator_CXX=:
94462    ;;
94463  linux* | k*bsd*-gnu)
94464    case $cc_basename in
94465      KCC*)
94466	# Kuck and Associates, Inc. (KAI) C++ Compiler
94467
94468	# KCC will only create a shared library if the output file
94469	# ends with ".so" (or ".sl" for HP-UX), so rename the library
94470	# to its proper name (with version) after linking.
94471	archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
94472	archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
94473	# Commands to make compiler produce verbose output that lists
94474	# what "hidden" libraries, object files and flags are used when
94475	# linking a shared library.
94476	#
94477	# There doesn't appear to be a way to prevent this compiler from
94478	# explicitly linking system object files so we need to strip them
94479	# from the output so that they don't get included in the library
94480	# dependencies.
94481	output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94482
94483	hardcode_libdir_flag_spec_CXX='${wl}--rpath,$libdir'
94484	export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
94485
94486	# Archives containing C++ object files must be created using
94487	# "CC -Bstatic", where "CC" is the KAI C++ compiler.
94488	old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
94489	;;
94490      icpc*)
94491	# Intel C++
94492	with_gnu_ld=yes
94493	# version 8.0 and above of icpc choke on multiply defined symbols
94494	# if we add $predep_objects and $postdep_objects, however 7.1 and
94495	# earlier do not add the objects themselves.
94496	case `$CC -V 2>&1` in
94497	*"Version 7."*)
94498  	  archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
94499  	  archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
94500	  ;;
94501	*)  # Version 8.0 or newer
94502	  tmp_idyn=
94503	  case $host_cpu in
94504	    ia64*) tmp_idyn=' -i_dynamic';;
94505	  esac
94506  	  archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
94507	  archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
94508	  ;;
94509	esac
94510	archive_cmds_need_lc_CXX=no
94511	hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
94512	export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
94513	whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
94514	;;
94515      pgCC* | pgcpp*)
94516        # Portland Group C++ compiler
94517	archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
94518  	archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
94519
94520	hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
94521	export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
94522	whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
94523        ;;
94524      cxx*)
94525	# Compaq C++
94526	archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
94527	archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
94528
94529	runpath_var=LD_RUN_PATH
94530	hardcode_libdir_flag_spec_CXX='-rpath $libdir'
94531	hardcode_libdir_separator_CXX=:
94532
94533	# Commands to make compiler produce verbose output that lists
94534	# what "hidden" libraries, object files and flags are used when
94535	# linking a shared library.
94536	#
94537	# There doesn't appear to be a way to prevent this compiler from
94538	# explicitly linking system object files so we need to strip them
94539	# from the output so that they don't get included in the library
94540	# dependencies.
94541	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94542	;;
94543      *)
94544	case `$CC -V 2>&1 | sed 5q` in
94545	*Sun\ C*)
94546	  # Sun C++ 5.9
94547	  no_undefined_flag_CXX=' -zdefs'
94548	  archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94549	  archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
94550	  hardcode_libdir_flag_spec_CXX='-R$libdir'
94551	  whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
94552
94553	  # Not sure whether something based on
94554	  # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
94555	  # would be better.
94556	  output_verbose_link_cmd='echo'
94557
94558	  # Archives containing C++ object files must be created using
94559	  # "CC -xar", where "CC" is the Sun C++ compiler.  This is
94560	  # necessary to make sure instantiated templates are included
94561	  # in the archive.
94562	  old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
94563	  ;;
94564	esac
94565	;;
94566    esac
94567    ;;
94568  lynxos*)
94569    # FIXME: insert proper C++ library support
94570    ld_shlibs_CXX=no
94571    ;;
94572  m88k*)
94573    # FIXME: insert proper C++ library support
94574    ld_shlibs_CXX=no
94575    ;;
94576  mvs*)
94577    case $cc_basename in
94578      cxx*)
94579	# FIXME: insert proper C++ library support
94580	ld_shlibs_CXX=no
94581	;;
94582      *)
94583	# FIXME: insert proper C++ library support
94584	ld_shlibs_CXX=no
94585	;;
94586    esac
94587    ;;
94588  netbsd*)
94589    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
94590      archive_cmds_CXX='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
94591      wlarc=
94592      hardcode_libdir_flag_spec_CXX='-R$libdir'
94593      hardcode_direct_CXX=yes
94594      hardcode_shlibpath_var_CXX=no
94595    fi
94596    # Workaround some broken pre-1.5 toolchains
94597    output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
94598    ;;
94599  openbsd2*)
94600    # C++ shared libraries are fairly broken
94601    ld_shlibs_CXX=no
94602    ;;
94603  openbsd*)
94604    if test -f /usr/libexec/ld.so; then
94605      hardcode_direct_CXX=yes
94606      hardcode_shlibpath_var_CXX=no
94607      archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
94608      hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
94609      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
94610	archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
94611	export_dynamic_flag_spec_CXX='${wl}-E'
94612	whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
94613      fi
94614      output_verbose_link_cmd='echo'
94615    else
94616      ld_shlibs_CXX=no
94617    fi
94618    ;;
94619  osf3*)
94620    case $cc_basename in
94621      KCC*)
94622	# Kuck and Associates, Inc. (KAI) C++ Compiler
94623
94624	# KCC will only create a shared library if the output file
94625	# ends with ".so" (or ".sl" for HP-UX), so rename the library
94626	# to its proper name (with version) after linking.
94627	archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
94628
94629	hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
94630	hardcode_libdir_separator_CXX=:
94631
94632	# Archives containing C++ object files must be created using
94633	# "CC -Bstatic", where "CC" is the KAI C++ compiler.
94634	old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
94635
94636	;;
94637      RCC*)
94638	# Rational C++ 2.4.1
94639	# FIXME: insert proper C++ library support
94640	ld_shlibs_CXX=no
94641	;;
94642      cxx*)
94643	allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
94644	archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
94645
94646	hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
94647	hardcode_libdir_separator_CXX=:
94648
94649	# Commands to make compiler produce verbose output that lists
94650	# what "hidden" libraries, object files and flags are used when
94651	# linking a shared library.
94652	#
94653	# There doesn't appear to be a way to prevent this compiler from
94654	# explicitly linking system object files so we need to strip them
94655	# from the output so that they don't get included in the library
94656	# dependencies.
94657	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94658	;;
94659      *)
94660	if test "$GXX" = yes && test "$with_gnu_ld" = no; then
94661	  allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
94662	  archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
94663
94664	  hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
94665	  hardcode_libdir_separator_CXX=:
94666
94667	  # Commands to make compiler produce verbose output that lists
94668	  # what "hidden" libraries, object files and flags are used when
94669	  # linking a shared library.
94670	  output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
94671
94672	else
94673	  # FIXME: insert proper C++ library support
94674	  ld_shlibs_CXX=no
94675	fi
94676	;;
94677    esac
94678    ;;
94679  osf4* | osf5*)
94680    case $cc_basename in
94681      KCC*)
94682	# Kuck and Associates, Inc. (KAI) C++ Compiler
94683
94684	# KCC will only create a shared library if the output file
94685	# ends with ".so" (or ".sl" for HP-UX), so rename the library
94686	# to its proper name (with version) after linking.
94687	archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
94688
94689	hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
94690	hardcode_libdir_separator_CXX=:
94691
94692	# Archives containing C++ object files must be created using
94693	# the KAI C++ compiler.
94694	old_archive_cmds_CXX='$CC -o $oldlib $oldobjs'
94695	;;
94696      RCC*)
94697	# Rational C++ 2.4.1
94698	# FIXME: insert proper C++ library support
94699	ld_shlibs_CXX=no
94700	;;
94701      cxx*)
94702	allow_undefined_flag_CXX=' -expect_unresolved \*'
94703	archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
94704	archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
94705	  echo "-hidden">> $lib.exp~
94706	  $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp  `test -n "$verstring" && echo -set_version	$verstring` -update_registry ${output_objdir}/so_locations -o $lib~
94707	  $rm $lib.exp'
94708
94709	hardcode_libdir_flag_spec_CXX='-rpath $libdir'
94710	hardcode_libdir_separator_CXX=:
94711
94712	# Commands to make compiler produce verbose output that lists
94713	# what "hidden" libraries, object files and flags are used when
94714	# linking a shared library.
94715	#
94716	# There doesn't appear to be a way to prevent this compiler from
94717	# explicitly linking system object files so we need to strip them
94718	# from the output so that they don't get included in the library
94719	# dependencies.
94720	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
94721	;;
94722      *)
94723	if test "$GXX" = yes && test "$with_gnu_ld" = no; then
94724	  allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
94725	 archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
94726
94727	  hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
94728	  hardcode_libdir_separator_CXX=:
94729
94730	  # Commands to make compiler produce verbose output that lists
94731	  # what "hidden" libraries, object files and flags are used when
94732	  # linking a shared library.
94733	  output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
94734
94735	else
94736	  # FIXME: insert proper C++ library support
94737	  ld_shlibs_CXX=no
94738	fi
94739	;;
94740    esac
94741    ;;
94742  psos*)
94743    # FIXME: insert proper C++ library support
94744    ld_shlibs_CXX=no
94745    ;;
94746  sunos4*)
94747    case $cc_basename in
94748      CC*)
94749	# Sun C++ 4.x
94750	# FIXME: insert proper C++ library support
94751	ld_shlibs_CXX=no
94752	;;
94753      lcc*)
94754	# Lucid
94755	# FIXME: insert proper C++ library support
94756	ld_shlibs_CXX=no
94757	;;
94758      *)
94759	# FIXME: insert proper C++ library support
94760	ld_shlibs_CXX=no
94761	;;
94762    esac
94763    ;;
94764  solaris*)
94765    case $cc_basename in
94766      CC*)
94767	# Sun C++ 4.2, 5.x and Centerline C++
94768        archive_cmds_need_lc_CXX=yes
94769	no_undefined_flag_CXX=' -zdefs'
94770	archive_cmds_CXX='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
94771	archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
94772	$CC -G${allow_undefined_flag}  ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
94773
94774	hardcode_libdir_flag_spec_CXX='-R$libdir'
94775	hardcode_shlibpath_var_CXX=no
94776	case $host_os in
94777	  solaris2.[0-5] | solaris2.[0-5].*) ;;
94778	  *)
94779	    # The compiler driver will combine and reorder linker options,
94780	    # but understands `-z linker_flag'.
94781	    # Supported since Solaris 2.6 (maybe 2.5.1?)
94782	    whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
94783	    ;;
94784	esac
94785	link_all_deplibs_CXX=yes
94786
94787	output_verbose_link_cmd='echo'
94788
94789	# Archives containing C++ object files must be created using
94790	# "CC -xar", where "CC" is the Sun C++ compiler.  This is
94791	# necessary to make sure instantiated templates are included
94792	# in the archive.
94793	old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
94794	;;
94795      gcx*)
94796	# Green Hills C++ Compiler
94797	archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
94798
94799	# The C++ compiler must be used to create the archive.
94800	old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
94801	;;
94802      *)
94803	# GNU C++ compiler with Solaris linker
94804	if test "$GXX" = yes && test "$with_gnu_ld" = no; then
94805	  no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
94806	  if $CC --version | grep -v '^2\.7' > /dev/null; then
94807	    archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
94808	    archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
94809		$CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
94810
94811	    # Commands to make compiler produce verbose output that lists
94812	    # what "hidden" libraries, object files and flags are used when
94813	    # linking a shared library.
94814	    output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
94815	  else
94816	    # g++ 2.7 appears to require `-G' NOT `-shared' on this
94817	    # platform.
94818	    archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
94819	    archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
94820		$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
94821
94822	    # Commands to make compiler produce verbose output that lists
94823	    # what "hidden" libraries, object files and flags are used when
94824	    # linking a shared library.
94825	    output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
94826	  fi
94827
94828	  hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
94829	  case $host_os in
94830	  solaris2.[0-5] | solaris2.[0-5].*) ;;
94831	  *)
94832	    whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
94833	    ;;
94834	  esac
94835	fi
94836	;;
94837    esac
94838    ;;
94839  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
94840    no_undefined_flag_CXX='${wl}-z,text'
94841    archive_cmds_need_lc_CXX=no
94842    hardcode_shlibpath_var_CXX=no
94843    runpath_var='LD_RUN_PATH'
94844
94845    case $cc_basename in
94846      CC*)
94847	archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
94848	archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
94849	;;
94850      *)
94851	archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
94852	archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
94853	;;
94854    esac
94855    ;;
94856  sysv5* | sco3.2v5* | sco5v6*)
94857    # Note: We can NOT use -z defs as we might desire, because we do not
94858    # link with -lc, and that would cause any symbols used from libc to
94859    # always be unresolved, which means just about no library would
94860    # ever link correctly.  If we're not using GNU ld we use -z text
94861    # though, which does catch some bad symbols but isn't as heavy-handed
94862    # as -z defs.
94863    # For security reasons, it is highly recommended that you always
94864    # use absolute paths for naming shared libraries, and exclude the
94865    # DT_RUNPATH tag from executables and libraries.  But doing so
94866    # requires that you compile everything twice, which is a pain.
94867    # So that behaviour is only enabled if SCOABSPATH is set to a
94868    # non-empty value in the environment.  Most likely only useful for
94869    # creating official distributions of packages.
94870    # This is a hack until libtool officially supports absolute path
94871    # names for shared libraries.
94872    no_undefined_flag_CXX='${wl}-z,text'
94873    allow_undefined_flag_CXX='${wl}-z,nodefs'
94874    archive_cmds_need_lc_CXX=no
94875    hardcode_shlibpath_var_CXX=no
94876    hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
94877    hardcode_libdir_separator_CXX=':'
94878    link_all_deplibs_CXX=yes
94879    export_dynamic_flag_spec_CXX='${wl}-Bexport'
94880    runpath_var='LD_RUN_PATH'
94881
94882    case $cc_basename in
94883      CC*)
94884	archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
94885	archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
94886	;;
94887      *)
94888	archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
94889	archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
94890	;;
94891    esac
94892    ;;
94893  tandem*)
94894    case $cc_basename in
94895      NCC*)
94896	# NonStop-UX NCC 3.20
94897	# FIXME: insert proper C++ library support
94898	ld_shlibs_CXX=no
94899	;;
94900      *)
94901	# FIXME: insert proper C++ library support
94902	ld_shlibs_CXX=no
94903	;;
94904    esac
94905    ;;
94906  vxworks*)
94907    # FIXME: insert proper C++ library support
94908    ld_shlibs_CXX=no
94909    ;;
94910  *)
94911    # FIXME: insert proper C++ library support
94912    ld_shlibs_CXX=no
94913    ;;
94914esac
94915{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
94916printf "%s\n" "$ld_shlibs_CXX" >&6; }
94917test "$ld_shlibs_CXX" = no && can_build_shared=no
94918
94919GCC_CXX="$GXX"
94920LD_CXX="$LD"
94921
94922## CAVEAT EMPTOR:
94923## There is no encapsulation within the following macros, do not change
94924## the running order or otherwise move them around unless you know exactly
94925## what you are doing...
94926cat > conftest.$ac_ext <<EOF
94927class Foo
94928{
94929public:
94930  Foo (void) { a = 0; }
94931private:
94932  int a;
94933};
94934EOF
94935
94936if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
94937  (eval $ac_compile) 2>&5
94938  ac_status=$?
94939  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
94940  test $ac_status = 0; }; then
94941  # Parse the compiler output and extract the necessary
94942  # objects, libraries and library flags.
94943
94944  # Sentinel used to keep track of whether or not we are before
94945  # the conftest object file.
94946  pre_test_object_deps_done=no
94947
94948  # The `*' in the case matches for architectures that use `case' in
94949  # $output_verbose_cmd can trigger glob expansion during the loop
94950  # eval without this substitution.
94951  output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
94952
94953  for p in `eval $output_verbose_link_cmd`; do
94954    case $p in
94955
94956    -L* | -R* | -l*)
94957       # Some compilers place space between "-{L,R}" and the path.
94958       # Remove the space.
94959       if test $p = "-L" \
94960	  || test $p = "-R"; then
94961	 prev=$p
94962	 continue
94963       else
94964	 prev=
94965       fi
94966
94967       if test "$pre_test_object_deps_done" = no; then
94968	 case $p in
94969	 -L* | -R*)
94970	   # Internal compiler library paths should come after those
94971	   # provided the user.  The postdeps already come after the
94972	   # user supplied libs so there is no need to process them.
94973	   if test -z "$compiler_lib_search_path_CXX"; then
94974	     compiler_lib_search_path_CXX="${prev}${p}"
94975	   else
94976	     compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
94977	   fi
94978	   ;;
94979	 # The "-l" case would never come before the object being
94980	 # linked, so don't bother handling this case.
94981	 esac
94982       else
94983	 if test -z "$postdeps_CXX"; then
94984	   postdeps_CXX="${prev}${p}"
94985	 else
94986	   postdeps_CXX="${postdeps_CXX} ${prev}${p}"
94987	 fi
94988       fi
94989       ;;
94990
94991    *.$objext)
94992       # This assumes that the test object file only shows up
94993       # once in the compiler output.
94994       if test "$p" = "conftest.$objext"; then
94995	 pre_test_object_deps_done=yes
94996	 continue
94997       fi
94998
94999       if test "$pre_test_object_deps_done" = no; then
95000	 if test -z "$predep_objects_CXX"; then
95001	   predep_objects_CXX="$p"
95002	 else
95003	   predep_objects_CXX="$predep_objects_CXX $p"
95004	 fi
95005       else
95006	 if test -z "$postdep_objects_CXX"; then
95007	   postdep_objects_CXX="$p"
95008	 else
95009	   postdep_objects_CXX="$postdep_objects_CXX $p"
95010	 fi
95011       fi
95012       ;;
95013
95014    *) ;; # Ignore the rest.
95015
95016    esac
95017  done
95018
95019  # Clean up.
95020  rm -f a.out a.exe
95021else
95022  echo "libtool.m4: error: problem compiling CXX test program"
95023fi
95024
95025$rm -f confest.$objext
95026
95027compiler_lib_search_dirs_CXX=
95028if test -n "$compiler_lib_search_path_CXX"; then
95029  compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
95030fi
95031
95032# PORTME: override above test on systems where it is broken
95033case $host_os in
95034interix[3-9]*)
95035  # Interix 3.5 installs completely hosed .la files for C++, so rather than
95036  # hack all around it, let's just trust "g++" to DTRT.
95037  predep_objects_CXX=
95038  postdep_objects_CXX=
95039  postdeps_CXX=
95040  ;;
95041
95042linux*)
95043  case `$CC -V 2>&1 | sed 5q` in
95044  *Sun\ C*)
95045    # Sun C++ 5.9
95046    #
95047    # The more standards-conforming stlport4 library is
95048    # incompatible with the Cstd library. Avoid specifying
95049    # it if it's in CXXFLAGS. Ignore libCrun as
95050    # -library=stlport4 depends on it.
95051    case " $CXX $CXXFLAGS " in
95052    *" -library=stlport4 "*)
95053      solaris_use_stlport4=yes
95054      ;;
95055    esac
95056    if test "$solaris_use_stlport4" != yes; then
95057      postdeps_CXX='-library=Cstd -library=Crun'
95058    fi
95059    ;;
95060  esac
95061  ;;
95062
95063solaris*)
95064  case $cc_basename in
95065  CC*)
95066    # The more standards-conforming stlport4 library is
95067    # incompatible with the Cstd library. Avoid specifying
95068    # it if it's in CXXFLAGS. Ignore libCrun as
95069    # -library=stlport4 depends on it.
95070    case " $CXX $CXXFLAGS " in
95071    *" -library=stlport4 "*)
95072      solaris_use_stlport4=yes
95073      ;;
95074    esac
95075
95076    # Adding this requires a known-good setup of shared libraries for
95077    # Sun compiler versions before 5.6, else PIC objects from an old
95078    # archive will be linked into the output, leading to subtle bugs.
95079    if test "$solaris_use_stlport4" != yes; then
95080      postdeps_CXX='-library=Cstd -library=Crun'
95081    fi
95082    ;;
95083  esac
95084  ;;
95085esac
95086
95087case " $postdeps_CXX " in
95088*" -lc "*) archive_cmds_need_lc_CXX=no ;;
95089esac
95090
95091lt_prog_compiler_wl_CXX=
95092lt_prog_compiler_pic_CXX=
95093lt_prog_compiler_static_CXX=
95094
95095{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
95096printf %s "checking for $compiler option to produce PIC... " >&6; }
95097
95098  # C++ specific cases for pic, static, wl, etc.
95099  if test "$GXX" = yes; then
95100    lt_prog_compiler_wl_CXX='-Wl,'
95101    lt_prog_compiler_static_CXX='-static'
95102
95103    case $host_os in
95104    aix*)
95105      # All AIX code is PIC.
95106      if test "$host_cpu" = ia64; then
95107	# AIX 5 now supports IA64 processor
95108	lt_prog_compiler_static_CXX='-Bstatic'
95109      fi
95110      ;;
95111    amigaos*)
95112      # FIXME: we need at least 68020 code to build shared libraries, but
95113      # adding the `-m68020' flag to GCC prevents building anything better,
95114      # like `-m68040'.
95115      lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
95116      ;;
95117    beos* | haiku* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
95118      # PIC is the default for these OSes.
95119      ;;
95120    mingw* | cygwin* | os2* | pw32*)
95121      # This hack is so that the source file can tell whether it is being
95122      # built for inclusion in a dll (and should export symbols for example).
95123      # Although the cygwin gcc ignores -fPIC, still need this for old-style
95124      # (--disable-auto-import) libraries
95125	  lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
95126      ;;
95127    darwin* | rhapsody*)
95128      # PIC is the default on this platform
95129      # Common symbols not allowed in MH_DYLIB files
95130      lt_prog_compiler_pic_CXX='-fno-common'
95131      ;;
95132    *djgpp*)
95133      # DJGPP does not support shared libraries at all
95134      lt_prog_compiler_pic_CXX=
95135      ;;
95136    interix[3-9]*)
95137      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
95138      # Instead, we relocate shared libraries at runtime.
95139      ;;
95140    sysv4*MP*)
95141      if test -d /usr/nec; then
95142	lt_prog_compiler_pic_CXX=-Kconform_pic
95143      fi
95144      ;;
95145    hpux*)
95146      # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
95147      # not for PA HP-UX.
95148      case $host_cpu in
95149      hppa*64*|ia64*)
95150	;;
95151      *)
95152	lt_prog_compiler_pic_CXX='-fPIC'
95153	;;
95154      esac
95155      ;;
95156    *)
95157      lt_prog_compiler_pic_CXX='-fPIC'
95158      ;;
95159    esac
95160  else
95161    case $host_os in
95162      aix[4-9]*)
95163	# All AIX code is PIC.
95164	if test "$host_cpu" = ia64; then
95165	  # AIX 5 now supports IA64 processor
95166	  lt_prog_compiler_static_CXX='-Bstatic'
95167	else
95168	  lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
95169	fi
95170	;;
95171      chorus*)
95172	case $cc_basename in
95173	cxch68*)
95174	  # Green Hills C++ Compiler
95175	  # _LT_AC_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
95176	  ;;
95177	esac
95178	;;
95179       darwin*)
95180         # PIC is the default on this platform
95181         # Common symbols not allowed in MH_DYLIB files
95182         case $cc_basename in
95183           xlc*)
95184           lt_prog_compiler_pic_CXX='-qnocommon'
95185           lt_prog_compiler_wl_CXX='-Wl,'
95186           ;;
95187         esac
95188       ;;
95189      dgux*)
95190	case $cc_basename in
95191	  ec++*)
95192	    lt_prog_compiler_pic_CXX='-KPIC'
95193	    ;;
95194	  ghcx*)
95195	    # Green Hills C++ Compiler
95196	    lt_prog_compiler_pic_CXX='-pic'
95197	    ;;
95198	  *)
95199	    ;;
95200	esac
95201	;;
95202      freebsd* | dragonfly*)
95203	# FreeBSD uses GNU C++
95204	;;
95205      hpux9* | hpux10* | hpux11*)
95206	case $cc_basename in
95207	  CC*)
95208	    lt_prog_compiler_wl_CXX='-Wl,'
95209	    lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
95210	    if test "$host_cpu" != ia64; then
95211	      lt_prog_compiler_pic_CXX='+Z'
95212	    fi
95213	    ;;
95214	  aCC*)
95215	    lt_prog_compiler_wl_CXX='-Wl,'
95216	    lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
95217	    case $host_cpu in
95218	    hppa*64*|ia64*)
95219	      # +Z the default
95220	      ;;
95221	    *)
95222	      lt_prog_compiler_pic_CXX='+Z'
95223	      ;;
95224	    esac
95225	    ;;
95226	  *)
95227	    ;;
95228	esac
95229	;;
95230      interix*)
95231	# This is c89, which is MS Visual C++ (no shared libs)
95232	# Anyone wants to do a port?
95233	;;
95234      irix5* | irix6* | nonstopux*)
95235	case $cc_basename in
95236	  CC*)
95237	    lt_prog_compiler_wl_CXX='-Wl,'
95238	    lt_prog_compiler_static_CXX='-non_shared'
95239	    # CC pic flag -KPIC is the default.
95240	    ;;
95241	  *)
95242	    ;;
95243	esac
95244	;;
95245      linux* | k*bsd*-gnu)
95246	case $cc_basename in
95247	  KCC*)
95248	    # KAI C++ Compiler
95249	    lt_prog_compiler_wl_CXX='--backend -Wl,'
95250	    lt_prog_compiler_pic_CXX='-fPIC'
95251	    ;;
95252      ecpc*)
95253        # old Intel C++ for x86_64 which still supported -KPIC.
95254        lt_prog_compiler_wl_CXX='-Wl,'
95255        lt_prog_compiler_pic_CXX='-KPIC'
95256        lt_prog_compiler_static_CXX='-static'
95257        ;;
95258      icpc*)
95259        # Intel C++, used to be incompatible with GCC.
95260        lt_prog_compiler_wl_CXX='-Wl,'
95261        lt_prog_compiler_pic_CXX='-fPIC'
95262        lt_prog_compiler_static_CXX='-static'
95263        ;;
95264	  pgCC* | pgcpp*)
95265	    # Portland Group C++ compiler.
95266	    lt_prog_compiler_wl_CXX='-Wl,'
95267	    lt_prog_compiler_pic_CXX='-fpic'
95268	    lt_prog_compiler_static_CXX='-Bstatic'
95269	    ;;
95270	  cxx*)
95271	    # Compaq C++
95272	    # Make sure the PIC flag is empty.  It appears that all Alpha
95273	    # Linux and Compaq Tru64 Unix objects are PIC.
95274	    lt_prog_compiler_pic_CXX=
95275	    lt_prog_compiler_static_CXX='-non_shared'
95276	    ;;
95277	  *)
95278	    case `$CC -V 2>&1 | sed 5q` in
95279	    *Sun\ C*)
95280	      # Sun C++ 5.9
95281	      lt_prog_compiler_pic_CXX='-KPIC'
95282	      lt_prog_compiler_static_CXX='-Bstatic'
95283	      lt_prog_compiler_wl_CXX='-Qoption ld '
95284	      ;;
95285	    esac
95286	    ;;
95287	esac
95288	;;
95289      lynxos*)
95290	;;
95291      m88k*)
95292	;;
95293      mvs*)
95294	case $cc_basename in
95295	  cxx*)
95296	    lt_prog_compiler_pic_CXX='-W c,exportall'
95297	    ;;
95298	  *)
95299	    ;;
95300	esac
95301	;;
95302      netbsd*)
95303	;;
95304      osf3* | osf4* | osf5*)
95305	case $cc_basename in
95306	  KCC*)
95307	    lt_prog_compiler_wl_CXX='--backend -Wl,'
95308	    ;;
95309	  RCC*)
95310	    # Rational C++ 2.4.1
95311	    lt_prog_compiler_pic_CXX='-pic'
95312	    ;;
95313	  cxx*)
95314	    # Digital/Compaq C++
95315	    lt_prog_compiler_wl_CXX='-Wl,'
95316	    # Make sure the PIC flag is empty.  It appears that all Alpha
95317	    # Linux and Compaq Tru64 Unix objects are PIC.
95318	    lt_prog_compiler_pic_CXX=
95319	    lt_prog_compiler_static_CXX='-non_shared'
95320	    ;;
95321	  *)
95322	    ;;
95323	esac
95324	;;
95325      psos*)
95326	;;
95327      solaris*)
95328	case $cc_basename in
95329	  CC*)
95330	    # Sun C++ 4.2, 5.x and Centerline C++
95331	    lt_prog_compiler_pic_CXX='-KPIC'
95332	    lt_prog_compiler_static_CXX='-Bstatic'
95333	    lt_prog_compiler_wl_CXX='-Qoption ld '
95334	    ;;
95335	  gcx*)
95336	    # Green Hills C++ Compiler
95337	    lt_prog_compiler_pic_CXX='-PIC'
95338	    ;;
95339	  *)
95340	    ;;
95341	esac
95342	;;
95343      sunos4*)
95344	case $cc_basename in
95345	  CC*)
95346	    # Sun C++ 4.x
95347	    lt_prog_compiler_pic_CXX='-pic'
95348	    lt_prog_compiler_static_CXX='-Bstatic'
95349	    ;;
95350	  lcc*)
95351	    # Lucid
95352	    lt_prog_compiler_pic_CXX='-pic'
95353	    ;;
95354	  *)
95355	    ;;
95356	esac
95357	;;
95358      tandem*)
95359	case $cc_basename in
95360	  NCC*)
95361	    # NonStop-UX NCC 3.20
95362	    lt_prog_compiler_pic_CXX='-KPIC'
95363	    ;;
95364	  *)
95365	    ;;
95366	esac
95367	;;
95368      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
95369	case $cc_basename in
95370	  CC*)
95371	    lt_prog_compiler_wl_CXX='-Wl,'
95372	    lt_prog_compiler_pic_CXX='-KPIC'
95373	    lt_prog_compiler_static_CXX='-Bstatic'
95374	    ;;
95375	esac
95376	;;
95377      vxworks*)
95378	;;
95379      *)
95380	lt_prog_compiler_can_build_shared_CXX=no
95381	;;
95382    esac
95383  fi
95384
95385{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_CXX" >&5
95386printf "%s\n" "$lt_prog_compiler_pic_CXX" >&6; }
95387
95388#
95389# Check to make sure the PIC flag actually works.
95390#
95391if test -n "$lt_prog_compiler_pic_CXX"; then
95392
95393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
95394printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
95395if test ${lt_cv_prog_compiler_pic_works_CXX+y}
95396then :
95397  printf %s "(cached) " >&6
95398else $as_nop
95399  lt_cv_prog_compiler_pic_works_CXX=no
95400  ac_outfile=conftest.$ac_objext
95401   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
95402   lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
95403   # Insert the option either (1) after the last *FLAGS variable, or
95404   # (2) before a word containing "conftest.", or (3) at the end.
95405   # Note that $ac_compile itself does not contain backslashes and begins
95406   # with a dollar sign (not a hyphen), so the echo should work correctly.
95407   # The option is referenced via a variable to avoid confusing sed.
95408   lt_compile=`echo "$ac_compile" | $SED \
95409   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
95410   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
95411   -e 's:$: $lt_compiler_flag:'`
95412   (eval echo "\"configure:95412: $lt_compile\"" >&5)
95413   (eval "$lt_compile" 2>conftest.err)
95414   ac_status=$?
95415   cat conftest.err >&5
95416   echo "configure:95416: \$? = $ac_status" >&5
95417   if (exit $ac_status) && test -s "$ac_outfile"; then
95418     # The compiler can only warn and ignore the option if not recognized
95419     # So say no if there are warnings other than the usual output.
95420     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
95421     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
95422     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
95423       lt_cv_prog_compiler_pic_works_CXX=yes
95424     fi
95425   fi
95426   $rm conftest*
95427
95428fi
95429{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
95430printf "%s\n" "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
95431
95432if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
95433    case $lt_prog_compiler_pic_CXX in
95434     "" | " "*) ;;
95435     *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
95436     esac
95437else
95438    lt_prog_compiler_pic_CXX=
95439     lt_prog_compiler_can_build_shared_CXX=no
95440fi
95441
95442fi
95443case $host_os in
95444  # For platforms which do not support PIC, -DPIC is meaningless:
95445  *djgpp*)
95446    lt_prog_compiler_pic_CXX=
95447    ;;
95448  *)
95449    lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
95450    ;;
95451esac
95452
95453#
95454# Check to make sure the static flag actually works.
95455#
95456wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
95457{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
95458printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
95459if test ${lt_cv_prog_compiler_static_works_CXX+y}
95460then :
95461  printf %s "(cached) " >&6
95462else $as_nop
95463  lt_cv_prog_compiler_static_works_CXX=no
95464   save_LDFLAGS="$LDFLAGS"
95465   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
95466   echo "$lt_simple_link_test_code" > conftest.$ac_ext
95467   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
95468     # The linker can only warn and ignore the option if not recognized
95469     # So say no if there are warnings
95470     if test -s conftest.err; then
95471       # Append any errors to the config.log.
95472       cat conftest.err 1>&5
95473       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
95474       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
95475       if diff conftest.exp conftest.er2 >/dev/null; then
95476         lt_cv_prog_compiler_static_works_CXX=yes
95477       fi
95478     else
95479       lt_cv_prog_compiler_static_works_CXX=yes
95480     fi
95481   fi
95482   $rm -r conftest*
95483   LDFLAGS="$save_LDFLAGS"
95484
95485fi
95486{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
95487printf "%s\n" "$lt_cv_prog_compiler_static_works_CXX" >&6; }
95488
95489if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
95490    :
95491else
95492    lt_prog_compiler_static_CXX=
95493fi
95494
95495
95496{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
95497printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
95498if test ${lt_cv_prog_compiler_c_o_CXX+y}
95499then :
95500  printf %s "(cached) " >&6
95501else $as_nop
95502  lt_cv_prog_compiler_c_o_CXX=no
95503   $rm -r conftest 2>/dev/null
95504   mkdir conftest
95505   cd conftest
95506   mkdir out
95507   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
95508
95509   lt_compiler_flag="-o out/conftest2.$ac_objext"
95510   # Insert the option either (1) after the last *FLAGS variable, or
95511   # (2) before a word containing "conftest.", or (3) at the end.
95512   # Note that $ac_compile itself does not contain backslashes and begins
95513   # with a dollar sign (not a hyphen), so the echo should work correctly.
95514   lt_compile=`echo "$ac_compile" | $SED \
95515   -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
95516   -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
95517   -e 's:$: $lt_compiler_flag:'`
95518   (eval echo "\"configure:95518: $lt_compile\"" >&5)
95519   (eval "$lt_compile" 2>out/conftest.err)
95520   ac_status=$?
95521   cat out/conftest.err >&5
95522   echo "configure:95522: \$? = $ac_status" >&5
95523   if (exit $ac_status) && test -s out/conftest2.$ac_objext
95524   then
95525     # The compiler can only warn and ignore the option if not recognized
95526     # So say no if there are warnings
95527     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
95528     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
95529     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
95530       lt_cv_prog_compiler_c_o_CXX=yes
95531     fi
95532   fi
95533   chmod u+w . 2>&5
95534   $rm conftest*
95535   # SGI C++ compiler will create directory out/ii_files/ for
95536   # template instantiation
95537   test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
95538   $rm out/* && rmdir out
95539   cd ..
95540   rmdir conftest
95541   $rm conftest*
95542
95543fi
95544{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
95545printf "%s\n" "$lt_cv_prog_compiler_c_o_CXX" >&6; }
95546
95547
95548hard_links="nottested"
95549if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
95550  # do not overwrite the value of need_locks provided by the user
95551  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
95552printf %s "checking if we can lock with hard links... " >&6; }
95553  hard_links=yes
95554  $rm conftest*
95555  ln conftest.a conftest.b 2>/dev/null && hard_links=no
95556  touch conftest.a
95557  ln conftest.a conftest.b 2>&5 || hard_links=no
95558  ln conftest.a conftest.b 2>/dev/null && hard_links=no
95559  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
95560printf "%s\n" "$hard_links" >&6; }
95561  if test "$hard_links" = no; then
95562    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
95563printf "%s\n" "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
95564    need_locks=warn
95565  fi
95566else
95567  need_locks=no
95568fi
95569
95570{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
95571printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
95572
95573  export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
95574  case $host_os in
95575  aix[4-9]*)
95576    # If we're using GNU nm, then we don't want the "-C" option.
95577    # -C means demangle to AIX nm, but means don't demangle with GNU nm
95578    if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
95579      export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
95580    else
95581      export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
95582    fi
95583    ;;
95584  pw32*)
95585    export_symbols_cmds_CXX="$ltdll_cmds"
95586  ;;
95587  cygwin* | mingw*)
95588    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
95589  ;;
95590  *)
95591    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
95592  ;;
95593  esac
95594  exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
95595
95596{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
95597printf "%s\n" "$ld_shlibs_CXX" >&6; }
95598test "$ld_shlibs_CXX" = no && can_build_shared=no
95599
95600#
95601# Do we need to explicitly link libc?
95602#
95603case "x$archive_cmds_need_lc_CXX" in
95604x|xyes)
95605  # Assume -lc should be added
95606  archive_cmds_need_lc_CXX=yes
95607
95608  if test "$enable_shared" = yes && test "$GCC" = yes; then
95609    case $archive_cmds_CXX in
95610    *'~'*)
95611      # FIXME: we may have to deal with multi-command sequences.
95612      ;;
95613    '$CC '*)
95614      # Test whether the compiler implicitly links with -lc since on some
95615      # systems, -lgcc has to come before -lc. If gcc already passes -lc
95616      # to ld, don't add -lc before -lgcc.
95617      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
95618printf %s "checking whether -lc should be explicitly linked in... " >&6; }
95619      $rm conftest*
95620      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
95621
95622      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
95623  (eval $ac_compile) 2>&5
95624  ac_status=$?
95625  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
95626  test $ac_status = 0; } 2>conftest.err; then
95627        soname=conftest
95628        lib=conftest
95629        libobjs=conftest.$ac_objext
95630        deplibs=
95631        wl=$lt_prog_compiler_wl_CXX
95632	pic_flag=$lt_prog_compiler_pic_CXX
95633        compiler_flags=-v
95634        linker_flags=-v
95635        verstring=
95636        output_objdir=.
95637        libname=conftest
95638        lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
95639        allow_undefined_flag_CXX=
95640        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\""; } >&5
95641  (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
95642  ac_status=$?
95643  printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
95644  test $ac_status = 0; }
95645        then
95646	  archive_cmds_need_lc_CXX=no
95647        else
95648	  archive_cmds_need_lc_CXX=yes
95649        fi
95650        allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
95651      else
95652        cat conftest.err 1>&5
95653      fi
95654      $rm conftest*
95655      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $archive_cmds_need_lc_CXX" >&5
95656printf "%s\n" "$archive_cmds_need_lc_CXX" >&6; }
95657      ;;
95658    esac
95659  fi
95660  ;;
95661esac
95662
95663{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
95664printf %s "checking dynamic linker characteristics... " >&6; }
95665library_names_spec=
95666libname_spec='lib$name'
95667soname_spec=
95668shrext_cmds=".so"
95669postinstall_cmds=
95670postuninstall_cmds=
95671finish_cmds=
95672finish_eval=
95673shlibpath_var=
95674shlibpath_overrides_runpath=unknown
95675version_type=none
95676dynamic_linker="$host_os ld.so"
95677sys_lib_dlsearch_path_spec="/lib /usr/lib"
95678
95679need_lib_prefix=unknown
95680hardcode_into_libs=no
95681
95682# when you set need_version to no, make sure it does not cause -set_version
95683# flags to be left without arguments
95684need_version=unknown
95685
95686case $host_os in
95687aix3*)
95688  version_type=linux
95689  library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
95690  shlibpath_var=LIBPATH
95691
95692  # AIX 3 has no versioning support, so we append a major version to the name.
95693  soname_spec='${libname}${release}${shared_ext}$major'
95694  ;;
95695
95696aix[4-9]*)
95697  version_type=linux
95698  need_lib_prefix=no
95699  need_version=no
95700  hardcode_into_libs=yes
95701  if test "$host_cpu" = ia64; then
95702    # AIX 5 supports IA64
95703    library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
95704    shlibpath_var=LD_LIBRARY_PATH
95705  else
95706    # With GCC up to 2.95.x, collect2 would create an import file
95707    # for dependence libraries.  The import file would start with
95708    # the line `#! .'.  This would cause the generated library to
95709    # depend on `.', always an invalid library.  This was fixed in
95710    # development snapshots of GCC prior to 3.0.
95711    case $host_os in
95712      aix4 | aix4.[01] | aix4.[01].*)
95713      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
95714	   echo ' yes '
95715	   echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
95716	:
95717      else
95718	can_build_shared=no
95719      fi
95720      ;;
95721    esac
95722    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
95723    # soname into executable. Probably we can add versioning support to
95724    # collect2, so additional links can be useful in future.
95725    if test "$aix_use_runtimelinking" = yes; then
95726      # If using run time linking (on AIX 4.2 or later) use lib<name>.so
95727      # instead of lib<name>.a to let people know that these are not
95728      # typical AIX shared libraries.
95729      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
95730    else
95731      # We preserve .a as extension for shared libraries through AIX4.2
95732      # and later when we are not doing run time linking.
95733      library_names_spec='${libname}${release}.a $libname.a'
95734      soname_spec='${libname}${release}${shared_ext}$major'
95735    fi
95736    shlibpath_var=LIBPATH
95737  fi
95738  ;;
95739
95740amigaos*)
95741  library_names_spec='$libname.ixlibrary $libname.a'
95742  # Create ${libname}_ixlibrary.a entries in /sys/libs.
95743  finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''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'
95744  ;;
95745
95746beos*)
95747  library_names_spec='${libname}${shared_ext}'
95748  dynamic_linker="$host_os ld.so"
95749  shlibpath_var=LIBRARY_PATH
95750  ;;
95751
95752haiku*)
95753  # Since haiku provides gcc, use GNU style here
95754  version_type=linux
95755  need_lib_prefix=no
95756  need_version=no
95757  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
95758  soname_spec='${libname}${release}${shared_ext}$major'
95759  shlibpath_var=LIBRARY_PATH
95760  hardcode_into_libs=yes
95761  ;;
95762
95763bsdi[45]*)
95764  version_type=linux
95765  need_version=no
95766  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
95767  soname_spec='${libname}${release}${shared_ext}$major'
95768  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
95769  shlibpath_var=LD_LIBRARY_PATH
95770  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
95771  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
95772  # the default ld.so.conf also contains /usr/contrib/lib and
95773  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
95774  # libtool to hard-code these into programs
95775  ;;
95776
95777cygwin* | mingw* | pw32*)
95778  version_type=windows
95779  shrext_cmds=".dll"
95780  need_version=no
95781  need_lib_prefix=no
95782
95783  case $GCC,$host_os in
95784  yes,cygwin* | yes,mingw* | yes,pw32*)
95785    library_names_spec='$libname.dll.a'
95786    # DLL is installed to $(libdir)/../bin by postinstall_cmds
95787    postinstall_cmds='base_file=`basename \${file}`~
95788      dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
95789      dldir=$destdir/`dirname \$dlpath`~
95790      test -d \$dldir || mkdir -p \$dldir~
95791      $install_prog $dir/$dlname \$dldir/$dlname~
95792      chmod a+x \$dldir/$dlname'
95793    postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
95794      dlpath=$dir/\$dldll~
95795       $rm \$dlpath'
95796    shlibpath_overrides_runpath=yes
95797
95798    case $host_os in
95799    cygwin*)
95800      # Cygwin DLLs use 'cyg' prefix rather than 'lib'
95801      soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
95802      sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
95803      ;;
95804    mingw*)
95805      # MinGW DLLs use traditional 'lib' prefix
95806      soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
95807      sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
95808      if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
95809        # It is most probably a Windows format PATH printed by
95810        # mingw gcc, but we are running on Cygwin. Gcc prints its search
95811        # path with ; separators, and with drive letters. We can handle the
95812        # drive letters (cygwin fileutils understands them), so leave them,
95813        # especially as we might pass files found there to a mingw objdump,
95814        # which wouldn't understand a cygwinified path. Ahh.
95815        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
95816      else
95817        sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
95818      fi
95819      ;;
95820    pw32*)
95821      # pw32 DLLs use 'pw' prefix rather than 'lib'
95822      library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
95823      ;;
95824    esac
95825    ;;
95826
95827  *)
95828    library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
95829    ;;
95830  esac
95831  dynamic_linker='Win32 ld.exe'
95832  # FIXME: first we should search . and the directory the executable is in
95833  shlibpath_var=PATH
95834  ;;
95835
95836darwin* | rhapsody*)
95837  dynamic_linker="$host_os dyld"
95838  version_type=darwin
95839  need_lib_prefix=no
95840  need_version=no
95841  library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
95842  soname_spec='${libname}${release}${major}$shared_ext'
95843  shlibpath_overrides_runpath=yes
95844  shlibpath_var=DYLD_LIBRARY_PATH
95845  shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
95846
95847  sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
95848  ;;
95849
95850dgux*)
95851  version_type=linux
95852  need_lib_prefix=no
95853  need_version=no
95854  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
95855  soname_spec='${libname}${release}${shared_ext}$major'
95856  shlibpath_var=LD_LIBRARY_PATH
95857  ;;
95858
95859freebsd* | dragonfly*)
95860  # DragonFly does not have aout.  When/if they implement a new
95861  # versioning mechanism, adjust this.
95862  if test -x /usr/bin/objformat; then
95863    objformat=`/usr/bin/objformat`
95864  else
95865    case $host_os in
95866    freebsd[123].*) objformat=aout ;;
95867    *) objformat=elf ;;
95868    esac
95869  fi
95870  version_type=freebsd-$objformat
95871  case $version_type in
95872    freebsd-elf*)
95873      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
95874      need_version=no
95875      need_lib_prefix=no
95876      ;;
95877    freebsd-*)
95878      library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
95879      need_version=yes
95880      ;;
95881  esac
95882  shlibpath_var=LD_LIBRARY_PATH
95883  case $host_os in
95884  freebsd2*)
95885    shlibpath_overrides_runpath=yes
95886    ;;
95887  freebsd3.[01]* | freebsdelf3.[01]*)
95888    shlibpath_overrides_runpath=yes
95889    hardcode_into_libs=yes
95890    ;;
95891  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
95892  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
95893    shlibpath_overrides_runpath=no
95894    hardcode_into_libs=yes
95895    ;;
95896  *) # from 4.6 on, and DragonFly
95897    shlibpath_overrides_runpath=yes
95898    hardcode_into_libs=yes
95899    ;;
95900  esac
95901  ;;
95902
95903gnu*)
95904  version_type=linux
95905  need_lib_prefix=no
95906  need_version=no
95907  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
95908  soname_spec='${libname}${release}${shared_ext}$major'
95909  shlibpath_var=LD_LIBRARY_PATH
95910  hardcode_into_libs=yes
95911  ;;
95912
95913hpux9* | hpux10* | hpux11*)
95914  # Give a soname corresponding to the major version so that dld.sl refuses to
95915  # link against other versions.
95916  version_type=sunos
95917  need_lib_prefix=no
95918  need_version=no
95919  case $host_cpu in
95920  ia64*)
95921    shrext_cmds='.so'
95922    hardcode_into_libs=yes
95923    dynamic_linker="$host_os dld.so"
95924    shlibpath_var=LD_LIBRARY_PATH
95925    shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
95926    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
95927    soname_spec='${libname}${release}${shared_ext}$major'
95928    if test "X$HPUX_IA64_MODE" = X32; then
95929      sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
95930    else
95931      sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
95932    fi
95933    sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
95934    ;;
95935   hppa*64*)
95936     shrext_cmds='.sl'
95937     hardcode_into_libs=yes
95938     dynamic_linker="$host_os dld.sl"
95939     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
95940     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
95941     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
95942     soname_spec='${libname}${release}${shared_ext}$major'
95943     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
95944     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
95945     ;;
95946   *)
95947    shrext_cmds='.sl'
95948    dynamic_linker="$host_os dld.sl"
95949    shlibpath_var=SHLIB_PATH
95950    shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
95951    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
95952    soname_spec='${libname}${release}${shared_ext}$major'
95953    ;;
95954  esac
95955  # HP-UX runs *really* slowly unless shared libraries are mode 555.
95956  postinstall_cmds='chmod 555 $lib'
95957  ;;
95958
95959interix[3-9]*)
95960  version_type=linux
95961  need_lib_prefix=no
95962  need_version=no
95963  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
95964  soname_spec='${libname}${release}${shared_ext}$major'
95965  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
95966  shlibpath_var=LD_LIBRARY_PATH
95967  shlibpath_overrides_runpath=no
95968  hardcode_into_libs=yes
95969  ;;
95970
95971irix5* | irix6* | nonstopux*)
95972  case $host_os in
95973    nonstopux*) version_type=nonstopux ;;
95974    *)
95975	if test "$lt_cv_prog_gnu_ld" = yes; then
95976		version_type=linux
95977	else
95978		version_type=irix
95979	fi ;;
95980  esac
95981  need_lib_prefix=no
95982  need_version=no
95983  soname_spec='${libname}${release}${shared_ext}$major'
95984  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
95985  case $host_os in
95986  irix5* | nonstopux*)
95987    libsuff= shlibsuff=
95988    ;;
95989  *)
95990    case $LD in # libtool.m4 will add one of these switches to LD
95991    *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
95992      libsuff= shlibsuff= libmagic=32-bit;;
95993    *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
95994      libsuff=32 shlibsuff=N32 libmagic=N32;;
95995    *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
95996      libsuff=64 shlibsuff=64 libmagic=64-bit;;
95997    *) libsuff= shlibsuff= libmagic=never-match;;
95998    esac
95999    ;;
96000  esac
96001  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
96002  shlibpath_overrides_runpath=no
96003  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
96004  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
96005  hardcode_into_libs=yes
96006  ;;
96007
96008# No shared lib support for Linux oldld, aout, or coff.
96009linux*oldld* | linux*aout* | linux*coff*)
96010  dynamic_linker=no
96011  ;;
96012
96013# This must be Linux ELF.
96014linux* | k*bsd*-gnu)
96015  version_type=linux
96016  need_lib_prefix=no
96017  need_version=no
96018  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96019  soname_spec='${libname}${release}${shared_ext}$major'
96020  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
96021  shlibpath_var=LD_LIBRARY_PATH
96022  shlibpath_overrides_runpath=no
96023  # This implies no fast_install, which is unacceptable.
96024  # Some rework will be needed to allow for fast_install
96025  # before this can be enabled.
96026  hardcode_into_libs=yes
96027
96028  # Append ld.so.conf contents to the search path
96029  if test -f /etc/ld.so.conf; then
96030    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;/^$/d' | tr '\n' ' '`
96031    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
96032  fi
96033
96034  # We used to test for /lib/ld.so.1 and disable shared libraries on
96035  # powerpc, because MkLinux only supported shared libraries with the
96036  # GNU dynamic linker.  Since this was broken with cross compilers,
96037  # most powerpc-linux boxes support dynamic linking these days and
96038  # people can always --disable-shared, the test was removed, and we
96039  # assume the GNU/Linux dynamic linker is in use.
96040  dynamic_linker='GNU/Linux ld.so'
96041  ;;
96042
96043netbsd*)
96044  version_type=sunos
96045  need_lib_prefix=no
96046  need_version=no
96047  if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
96048    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
96049    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
96050    dynamic_linker='NetBSD (a.out) ld.so'
96051  else
96052    library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
96053    soname_spec='${libname}${release}${shared_ext}$major'
96054    dynamic_linker='NetBSD ld.elf_so'
96055  fi
96056  shlibpath_var=LD_LIBRARY_PATH
96057  shlibpath_overrides_runpath=yes
96058  hardcode_into_libs=yes
96059  ;;
96060
96061newsos6)
96062  version_type=linux
96063  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96064  shlibpath_var=LD_LIBRARY_PATH
96065  shlibpath_overrides_runpath=yes
96066  ;;
96067
96068nto-qnx*)
96069  version_type=linux
96070  need_lib_prefix=no
96071  need_version=no
96072  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96073  soname_spec='${libname}${release}${shared_ext}$major'
96074  shlibpath_var=LD_LIBRARY_PATH
96075  shlibpath_overrides_runpath=yes
96076  ;;
96077
96078openbsd*)
96079  version_type=sunos
96080  sys_lib_dlsearch_path_spec="/usr/lib"
96081  need_lib_prefix=no
96082  # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
96083  case $host_os in
96084    openbsd3.3 | openbsd3.3.*) need_version=yes ;;
96085    *)                         need_version=no  ;;
96086  esac
96087  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
96088  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
96089  shlibpath_var=LD_LIBRARY_PATH
96090  if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
96091    case $host_os in
96092      openbsd2.[89] | openbsd2.[89].*)
96093	shlibpath_overrides_runpath=no
96094	;;
96095      *)
96096	shlibpath_overrides_runpath=yes
96097	;;
96098      esac
96099  else
96100    shlibpath_overrides_runpath=yes
96101  fi
96102  ;;
96103
96104os2*)
96105  libname_spec='$name'
96106  shrext_cmds=".dll"
96107  need_lib_prefix=no
96108  library_names_spec='$libname${shared_ext} $libname.a'
96109  dynamic_linker='OS/2 ld.exe'
96110  shlibpath_var=LIBPATH
96111  ;;
96112
96113osf3* | osf4* | osf5*)
96114  version_type=osf
96115  need_lib_prefix=no
96116  need_version=no
96117  soname_spec='${libname}${release}${shared_ext}$major'
96118  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96119  shlibpath_var=LD_LIBRARY_PATH
96120  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
96121  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
96122  ;;
96123
96124rdos*)
96125  dynamic_linker=no
96126  ;;
96127
96128solaris*)
96129  version_type=linux
96130  need_lib_prefix=no
96131  need_version=no
96132  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96133  soname_spec='${libname}${release}${shared_ext}$major'
96134  shlibpath_var=LD_LIBRARY_PATH
96135  shlibpath_overrides_runpath=yes
96136  hardcode_into_libs=yes
96137  # ldd complains unless libraries are executable
96138  postinstall_cmds='chmod +x $lib'
96139  ;;
96140
96141sunos4*)
96142  version_type=sunos
96143  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
96144  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
96145  shlibpath_var=LD_LIBRARY_PATH
96146  shlibpath_overrides_runpath=yes
96147  if test "$with_gnu_ld" = yes; then
96148    need_lib_prefix=no
96149  fi
96150  need_version=yes
96151  ;;
96152
96153sysv4 | sysv4.3*)
96154  version_type=linux
96155  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96156  soname_spec='${libname}${release}${shared_ext}$major'
96157  shlibpath_var=LD_LIBRARY_PATH
96158  case $host_vendor in
96159    sni)
96160      shlibpath_overrides_runpath=no
96161      need_lib_prefix=no
96162      export_dynamic_flag_spec='${wl}-Blargedynsym'
96163      runpath_var=LD_RUN_PATH
96164      ;;
96165    siemens)
96166      need_lib_prefix=no
96167      ;;
96168    motorola)
96169      need_lib_prefix=no
96170      need_version=no
96171      shlibpath_overrides_runpath=no
96172      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
96173      ;;
96174  esac
96175  ;;
96176
96177sysv4*MP*)
96178  if test -d /usr/nec ;then
96179    version_type=linux
96180    library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
96181    soname_spec='$libname${shared_ext}.$major'
96182    shlibpath_var=LD_LIBRARY_PATH
96183  fi
96184  ;;
96185
96186sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
96187  version_type=freebsd-elf
96188  need_lib_prefix=no
96189  need_version=no
96190  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
96191  soname_spec='${libname}${release}${shared_ext}$major'
96192  shlibpath_var=LD_LIBRARY_PATH
96193  hardcode_into_libs=yes
96194  if test "$with_gnu_ld" = yes; then
96195    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
96196    shlibpath_overrides_runpath=no
96197  else
96198    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
96199    shlibpath_overrides_runpath=yes
96200    case $host_os in
96201      sco3.2v5*)
96202        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
96203	;;
96204    esac
96205  fi
96206  sys_lib_dlsearch_path_spec='/usr/lib'
96207  ;;
96208
96209uts4*)
96210  version_type=linux
96211  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
96212  soname_spec='${libname}${release}${shared_ext}$major'
96213  shlibpath_var=LD_LIBRARY_PATH
96214  ;;
96215
96216*)
96217  dynamic_linker=no
96218  ;;
96219esac
96220{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
96221printf "%s\n" "$dynamic_linker" >&6; }
96222test "$dynamic_linker" = no && can_build_shared=no
96223
96224if test ${lt_cv_sys_lib_search_path_spec+y}
96225then :
96226  printf %s "(cached) " >&6
96227else $as_nop
96228  lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"
96229fi
96230
96231sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
96232if test ${lt_cv_sys_lib_dlsearch_path_spec+y}
96233then :
96234  printf %s "(cached) " >&6
96235else $as_nop
96236  lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"
96237fi
96238
96239sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
96240
96241variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
96242if test "$GCC" = yes; then
96243  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
96244fi
96245
96246{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
96247printf %s "checking how to hardcode library paths into programs... " >&6; }
96248hardcode_action_CXX=
96249if test -n "$hardcode_libdir_flag_spec_CXX" || \
96250   test -n "$runpath_var_CXX" || \
96251   test "X$hardcode_automatic_CXX" = "Xyes" ; then
96252
96253  # We can hardcode non-existent directories.
96254  if test "$hardcode_direct_CXX" != no &&
96255     # If the only mechanism to avoid hardcoding is shlibpath_var, we
96256     # have to relink, otherwise we might link with an installed library
96257     # when we should be linking with a yet-to-be-installed one
96258     ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
96259     test "$hardcode_minus_L_CXX" != no; then
96260    # Linking always hardcodes the temporary library directory.
96261    hardcode_action_CXX=relink
96262  else
96263    # We can link without hardcoding, and we can hardcode nonexisting dirs.
96264    hardcode_action_CXX=immediate
96265  fi
96266else
96267  # We cannot hardcode anything, or else we can only hardcode existing
96268  # directories.
96269  hardcode_action_CXX=unsupported
96270fi
96271{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
96272printf "%s\n" "$hardcode_action_CXX" >&6; }
96273
96274if test "$hardcode_action_CXX" = relink; then
96275  # Fast installation is not supported
96276  enable_fast_install=no
96277elif test "$shlibpath_overrides_runpath" = yes ||
96278     test "$enable_shared" = no; then
96279  # Fast installation is not necessary
96280  enable_fast_install=needless
96281fi
96282
96283
96284# The else clause should only fire when bootstrapping the
96285# libtool distribution, otherwise you forgot to ship ltmain.sh
96286# with your package, and you will get complaints that there are
96287# no rules to generate ltmain.sh.
96288if test -f "$ltmain"; then
96289  # See if we are running on zsh, and set the options which allow our commands through
96290  # without removal of \ escapes.
96291  if test -n "${ZSH_VERSION+set}" ; then
96292    setopt NO_GLOB_SUBST
96293  fi
96294  # Now quote all the things that may contain metacharacters while being
96295  # careful not to overquote the AC_SUBSTed values.  We take copies of the
96296  # variables and quote the copies for generation of the libtool script.
96297  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
96298    SED SHELL STRIP \
96299    libname_spec library_names_spec soname_spec extract_expsyms_cmds \
96300    old_striplib striplib file_magic_cmd finish_cmds finish_eval \
96301    deplibs_check_method reload_flag reload_cmds need_locks \
96302    lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
96303    lt_cv_sys_global_symbol_to_c_name_address \
96304    sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
96305    old_postinstall_cmds old_postuninstall_cmds \
96306    compiler_CXX \
96307    CC_CXX \
96308    LD_CXX \
96309    lt_prog_compiler_wl_CXX \
96310    lt_prog_compiler_pic_CXX \
96311    lt_prog_compiler_static_CXX \
96312    lt_prog_compiler_no_builtin_flag_CXX \
96313    export_dynamic_flag_spec_CXX \
96314    thread_safe_flag_spec_CXX \
96315    whole_archive_flag_spec_CXX \
96316    enable_shared_with_static_runtimes_CXX \
96317    old_archive_cmds_CXX \
96318    old_archive_from_new_cmds_CXX \
96319    predep_objects_CXX \
96320    postdep_objects_CXX \
96321    predeps_CXX \
96322    postdeps_CXX \
96323    compiler_lib_search_path_CXX \
96324    compiler_lib_search_dirs_CXX \
96325    archive_cmds_CXX \
96326    archive_expsym_cmds_CXX \
96327    postinstall_cmds_CXX \
96328    postuninstall_cmds_CXX \
96329    old_archive_from_expsyms_cmds_CXX \
96330    allow_undefined_flag_CXX \
96331    no_undefined_flag_CXX \
96332    export_symbols_cmds_CXX \
96333    hardcode_libdir_flag_spec_CXX \
96334    hardcode_libdir_flag_spec_ld_CXX \
96335    hardcode_libdir_separator_CXX \
96336    hardcode_automatic_CXX \
96337    module_cmds_CXX \
96338    module_expsym_cmds_CXX \
96339    lt_cv_prog_compiler_c_o_CXX \
96340    fix_srcfile_path_CXX \
96341    exclude_expsyms_CXX \
96342    include_expsyms_CXX; do
96343
96344    case $var in
96345    old_archive_cmds_CXX | \
96346    old_archive_from_new_cmds_CXX | \
96347    archive_cmds_CXX | \
96348    archive_expsym_cmds_CXX | \
96349    module_cmds_CXX | \
96350    module_expsym_cmds_CXX | \
96351    old_archive_from_expsyms_cmds_CXX | \
96352    export_symbols_cmds_CXX | \
96353    extract_expsyms_cmds | reload_cmds | finish_cmds | \
96354    postinstall_cmds | postuninstall_cmds | \
96355    old_postinstall_cmds | old_postuninstall_cmds | \
96356    sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
96357      # Double-quote double-evaled strings.
96358      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
96359      ;;
96360    *)
96361      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
96362      ;;
96363    esac
96364  done
96365
96366  case $lt_echo in
96367  *'\$0 --fallback-echo"')
96368    lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
96369    ;;
96370  esac
96371
96372cfgfile="$ofile"
96373
96374  cat <<__EOF__ >> "$cfgfile"
96375# ### BEGIN LIBTOOL TAG CONFIG: $tagname
96376
96377# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
96378
96379# Shell to use when invoking shell scripts.
96380SHELL=$lt_SHELL
96381
96382# Whether or not to build shared libraries.
96383build_libtool_libs=$enable_shared
96384
96385# Whether or not to build static libraries.
96386build_old_libs=$enable_static
96387
96388# Whether or not to add -lc for building shared libraries.
96389build_libtool_need_lc=$archive_cmds_need_lc_CXX
96390
96391# Whether or not to disallow shared libs when runtime libs are static
96392allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
96393
96394# Whether or not to optimize for fast installation.
96395fast_install=$enable_fast_install
96396
96397# The host system.
96398host_alias=$host_alias
96399host=$host
96400host_os=$host_os
96401
96402# The build system.
96403build_alias=$build_alias
96404build=$build
96405build_os=$build_os
96406
96407# An echo program that does not interpret backslashes.
96408echo=$lt_echo
96409
96410# The archiver.
96411AR=$lt_AR
96412AR_FLAGS=$lt_AR_FLAGS
96413
96414# A C compiler.
96415LTCC=$lt_LTCC
96416
96417# LTCC compiler flags.
96418LTCFLAGS=$lt_LTCFLAGS
96419
96420# A language-specific compiler.
96421CC=$lt_compiler_CXX
96422
96423# Is the compiler the GNU C compiler?
96424with_gcc=$GCC_CXX
96425
96426# An ERE matcher.
96427EGREP=$lt_EGREP
96428
96429# The linker used to build libraries.
96430LD=$lt_LD_CXX
96431
96432# Whether we need hard or soft links.
96433LN_S=$lt_LN_S
96434
96435# A BSD-compatible nm program.
96436NM=$lt_NM
96437
96438# A symbol stripping program
96439STRIP=$lt_STRIP
96440
96441# Used to examine libraries when file_magic_cmd begins "file"
96442MAGIC_CMD=$MAGIC_CMD
96443
96444# Used on cygwin: DLL creation program.
96445DLLTOOL="$DLLTOOL"
96446
96447# Used on cygwin: object dumper.
96448OBJDUMP="$OBJDUMP"
96449
96450# Used on cygwin: assembler.
96451AS="$AS"
96452
96453# The name of the directory that contains temporary libtool files.
96454objdir=$objdir
96455
96456# How to create reloadable object files.
96457reload_flag=$lt_reload_flag
96458reload_cmds=$lt_reload_cmds
96459
96460# How to pass a linker flag through the compiler.
96461wl=$lt_lt_prog_compiler_wl_CXX
96462
96463# Object file suffix (normally "o").
96464objext="$ac_objext"
96465
96466# Old archive suffix (normally "a").
96467libext="$libext"
96468
96469# Shared library suffix (normally ".so").
96470shrext_cmds='$shrext_cmds'
96471
96472# Executable file suffix (normally "").
96473exeext="$exeext"
96474
96475# Additional compiler flags for building library objects.
96476pic_flag=$lt_lt_prog_compiler_pic_CXX
96477pic_mode=$pic_mode
96478
96479# What is the maximum length of a command?
96480max_cmd_len=$lt_cv_sys_max_cmd_len
96481
96482# Does compiler simultaneously support -c and -o options?
96483compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
96484
96485# Must we lock files when doing compilation?
96486need_locks=$lt_need_locks
96487
96488# Do we need the lib prefix for modules?
96489need_lib_prefix=$need_lib_prefix
96490
96491# Do we need a version for libraries?
96492need_version=$need_version
96493
96494# Whether dlopen is supported.
96495dlopen_support=$enable_dlopen
96496
96497# Whether dlopen of programs is supported.
96498dlopen_self=$enable_dlopen_self
96499
96500# Whether dlopen of statically linked programs is supported.
96501dlopen_self_static=$enable_dlopen_self_static
96502
96503# Compiler flag to prevent dynamic linking.
96504link_static_flag=$lt_lt_prog_compiler_static_CXX
96505
96506# Compiler flag to turn off builtin functions.
96507no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
96508
96509# Compiler flag to allow reflexive dlopens.
96510export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
96511
96512# Compiler flag to generate shared objects directly from archives.
96513whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
96514
96515# Compiler flag to generate thread-safe objects.
96516thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX
96517
96518# Library versioning type.
96519version_type=$version_type
96520
96521# Format of library name prefix.
96522libname_spec=$lt_libname_spec
96523
96524# List of archive names.  First name is the real one, the rest are links.
96525# The last name is the one that the linker finds with -lNAME.
96526library_names_spec=$lt_library_names_spec
96527
96528# The coded name of the library, if different from the real name.
96529soname_spec=$lt_soname_spec
96530
96531# Commands used to build and install an old-style archive.
96532RANLIB=$lt_RANLIB
96533old_archive_cmds=$lt_old_archive_cmds_CXX
96534old_postinstall_cmds=$lt_old_postinstall_cmds
96535old_postuninstall_cmds=$lt_old_postuninstall_cmds
96536
96537# Create an old-style archive from a shared archive.
96538old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
96539
96540# Create a temporary old-style archive to link instead of a shared archive.
96541old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
96542
96543# Commands used to build and install a shared archive.
96544archive_cmds=$lt_archive_cmds_CXX
96545archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
96546postinstall_cmds=$lt_postinstall_cmds
96547postuninstall_cmds=$lt_postuninstall_cmds
96548
96549# Commands used to build a loadable module (assumed same as above if empty)
96550module_cmds=$lt_module_cmds_CXX
96551module_expsym_cmds=$lt_module_expsym_cmds_CXX
96552
96553# Commands to strip libraries.
96554old_striplib=$lt_old_striplib
96555striplib=$lt_striplib
96556
96557# Dependencies to place before the objects being linked to create a
96558# shared library.
96559predep_objects=$lt_predep_objects_CXX
96560
96561# Dependencies to place after the objects being linked to create a
96562# shared library.
96563postdep_objects=$lt_postdep_objects_CXX
96564
96565# Dependencies to place before the objects being linked to create a
96566# shared library.
96567predeps=$lt_predeps_CXX
96568
96569# Dependencies to place after the objects being linked to create a
96570# shared library.
96571postdeps=$lt_postdeps_CXX
96572
96573# The directories searched by this compiler when creating a shared
96574# library
96575compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
96576
96577# The library search path used internally by the compiler when linking
96578# a shared library.
96579compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
96580
96581# Method to check whether dependent libraries are shared objects.
96582deplibs_check_method=$lt_deplibs_check_method
96583
96584# Command to use when deplibs_check_method == file_magic.
96585file_magic_cmd=$lt_file_magic_cmd
96586
96587# Flag that allows shared libraries with undefined symbols to be built.
96588allow_undefined_flag=$lt_allow_undefined_flag_CXX
96589
96590# Flag that forces no undefined symbols.
96591no_undefined_flag=$lt_no_undefined_flag_CXX
96592
96593# Commands used to finish a libtool library installation in a directory.
96594finish_cmds=$lt_finish_cmds
96595
96596# Same as above, but a single script fragment to be evaled but not shown.
96597finish_eval=$lt_finish_eval
96598
96599# Take the output of nm and produce a listing of raw symbols and C names.
96600global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
96601
96602# Transform the output of nm in a proper C declaration
96603global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
96604
96605# Transform the output of nm in a C name address pair
96606global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
96607
96608# This is the shared library runtime path variable.
96609runpath_var=$runpath_var
96610
96611# This is the shared library path variable.
96612shlibpath_var=$shlibpath_var
96613
96614# Is shlibpath searched before the hard-coded library search path?
96615shlibpath_overrides_runpath=$shlibpath_overrides_runpath
96616
96617# How to hardcode a shared library path into an executable.
96618hardcode_action=$hardcode_action_CXX
96619
96620# Whether we should hardcode library paths into libraries.
96621hardcode_into_libs=$hardcode_into_libs
96622
96623# Flag to hardcode \$libdir into a binary during linking.
96624# This must work even if \$libdir does not exist.
96625hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
96626
96627# If ld is used when linking, flag to hardcode \$libdir into
96628# a binary during linking. This must work even if \$libdir does
96629# not exist.
96630hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
96631
96632# Whether we need a single -rpath flag with a separated argument.
96633hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
96634
96635# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
96636# resulting binary.
96637hardcode_direct=$hardcode_direct_CXX
96638
96639# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
96640# resulting binary.
96641hardcode_minus_L=$hardcode_minus_L_CXX
96642
96643# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
96644# the resulting binary.
96645hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
96646
96647# Set to yes if building a shared library automatically hardcodes DIR into the library
96648# and all subsequent libraries and executables linked against it.
96649hardcode_automatic=$hardcode_automatic_CXX
96650
96651# Variables whose values should be saved in libtool wrapper scripts and
96652# restored at relink time.
96653variables_saved_for_relink="$variables_saved_for_relink"
96654
96655# Whether libtool must link a program against all its dependency libraries.
96656link_all_deplibs=$link_all_deplibs_CXX
96657
96658# Compile-time system search path for libraries
96659sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
96660
96661# Run-time system search path for libraries
96662sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
96663
96664# Fix the shell variable \$srcfile for the compiler.
96665fix_srcfile_path=$lt_fix_srcfile_path
96666
96667# Set to yes if exported symbols are required.
96668always_export_symbols=$always_export_symbols_CXX
96669
96670# The commands to list exported symbols.
96671export_symbols_cmds=$lt_export_symbols_cmds_CXX
96672
96673# The commands to extract the exported symbol list from a shared archive.
96674extract_expsyms_cmds=$lt_extract_expsyms_cmds
96675
96676# Symbols that should not be listed in the preloaded symbols.
96677exclude_expsyms=$lt_exclude_expsyms_CXX
96678
96679# Symbols that must always be exported.
96680include_expsyms=$lt_include_expsyms_CXX
96681
96682# ### END LIBTOOL TAG CONFIG: $tagname
96683
96684__EOF__
96685
96686
96687else
96688  # If there is no Makefile yet, we rely on a make rule to execute
96689  # `config.status --recheck' to rerun these tests and create the
96690  # libtool script then.
96691  ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
96692  if test -f "$ltmain_in"; then
96693    test -f Makefile && make "$ltmain"
96694  fi
96695fi
96696
96697
96698ac_ext=c
96699ac_cpp='$CPP $CPPFLAGS'
96700ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
96701ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
96702ac_compiler_gnu=$ac_cv_c_compiler_gnu
96703
96704CC=$lt_save_CC
96705LDCXX=$LD
96706LD=$lt_save_LD
96707GCC=$lt_save_GCC
96708with_gnu_ldcxx=$with_gnu_ld
96709with_gnu_ld=$lt_save_with_gnu_ld
96710lt_cv_path_LDCXX=$lt_cv_path_LD
96711lt_cv_path_LD=$lt_save_path_LD
96712lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
96713lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
96714
96715	else
96716	  tagname=""
96717	fi
96718	;;
96719
96720      *)
96721	as_fn_error $? "Unsupported tag name: $tagname" "$LINENO" 5
96722	;;
96723      esac
96724
96725      # Append the new tag name to the list of available tags.
96726      if test -n "$tagname" ; then
96727      available_tags="$available_tags $tagname"
96728    fi
96729    fi
96730  done
96731  IFS="$lt_save_ifs"
96732
96733  # Now substitute the updated list of available tags.
96734  if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
96735    mv "${ofile}T" "$ofile"
96736    chmod +x "$ofile"
96737  else
96738    rm -f "${ofile}T"
96739    as_fn_error $? "unable to update list of available tagged configurations." "$LINENO" 5
96740  fi
96741fi
96742
96743
96744
96745# This can be used to rebuild libtool when needed
96746LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
96747
96748# Always use our own libtool.
96749LIBTOOL='$(SHELL) $(top_builddir)/libtool'
96750
96751# Prevent multiple expansion
96752
96753
96754
96755
96756
96757
96758
96759
96760
96761
96762
96763
96764  if test -z "$LIBTOOL"; then
96765    LIBTOOL='$(SHELL) $(top_builddir)/libtool --silent'
96766  else
96767    LIBTOOL="$LIBTOOL --silent"
96768  fi
96769
96770
96771
96772  if test -z "$LIBTOOL"; then
96773    LIBTOOL='$(SHELL) $(top_builddir)/libtool --preserve-dup-deps'
96774  else
96775    LIBTOOL="$LIBTOOL --preserve-dup-deps"
96776  fi
96777
96778
96779
96780  if test -z "$LIBTOOL"; then
96781    LIBTOOL='$(SHELL) $(top_builddir)/libtool --tag CC'
96782  else
96783    LIBTOOL="$LIBTOOL --tag CC"
96784  fi
96785
96786
96787test -z "$PHP_COMPILE" && PHP_COMPILE='$(LIBTOOL) --mode=compile $(COMPILE) -c $<'
96788test -z "$CXX_PHP_COMPILE" && CXX_PHP_COMPILE='$(LIBTOOL) --mode=compile $(CXX_COMPILE) -c $<'
96789SHARED_LIBTOOL='$(LIBTOOL)'
96790
96791CC=$old_CC
96792
96793
96794  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: " >&5
96795printf "%s\n" "" >&6; }
96796  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${T_MD}Generating files${T_ME}" >&5
96797printf "%s\n" "${T_MD}Generating files${T_ME}" >&6; }
96798
96799
96800CXXFLAGS_CLEAN=$CXXFLAGS
96801CFLAGS_CLEAN="$CFLAGS \$(PROF_FLAGS)"
96802CFLAGS="\$(CFLAGS_CLEAN) $standard_libtool_flag"
96803CXXFLAGS="$CXXFLAGS $standard_libtool_flag \$(PROF_FLAGS)"
96804
96805if test "$PHP_PHAR" != "no" && test "$PHP_CLI" != "no"; then
96806  pharcmd=pharcmd
96807  pharcmd_install=install-pharcmd
96808else
96809  pharcmd=
96810  pharcmd_install=
96811fi;
96812
96813all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_ZEND_EX) \$(PHP_BINARIES) $pharcmd"
96814install_targets="$install_sapi $install_modules $install_binaries install-build install-headers install-programs $install_pear $pharcmd_install"
96815
96816
96817  PHP_VAR_SUBST="$PHP_VAR_SUBST all_targets"
96818
96819
96820  PHP_VAR_SUBST="$PHP_VAR_SUBST install_targets"
96821
96822
96823  PHP_VAR_SUBST="$PHP_VAR_SUBST install_binary_targets"
96824
96825
96826
96827
96828    for header_file in Zend/ TSRM/ include/ main/ main/streams/; do
96829
96830
96831  unique=`echo $header_file|$SED 's/[^a-zA-Z0-9]/_/g'`
96832
96833  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
96834  if test -n "$unique" && test "`eval $cmd`" = "" ; then
96835    eval "INSTALLHEADERS$unique=set"
96836
96837        INSTALL_HEADERS="$INSTALL_HEADERS $header_file"
96838
96839  fi
96840
96841    done
96842
96843
96844
96845
96846    header_path=Zend/Optimizer
96847    for header_file in  \
96848    zend_call_graph.h \
96849    zend_cfg.h \
96850    zend_dfg.h \
96851    zend_dump.h \
96852    zend_func_info.h \
96853    zend_inference.h \
96854    zend_optimizer.h \
96855    zend_ssa.h; do
96856      hp_hf="$header_path/$header_file"
96857
96858
96859  unique=`echo $hp_hf|$SED 's/[^a-zA-Z0-9]/_/g'`
96860
96861  cmd="echo $ac_n \"\$INSTALLHEADERS$unique$ac_c\""
96862  if test -n "$unique" && test "`eval $cmd`" = "" ; then
96863    eval "INSTALLHEADERS$unique=set"
96864
96865        INSTALL_HEADERS="$INSTALL_HEADERS $hp_hf"
96866
96867  fi
96868
96869    done
96870
96871
96872
96873
96874
96875  case TSRM in
96876  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
96877  /*) ac_srcdir=`echo "TSRM"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
96878  *) ac_srcdir="$abs_srcdir/TSRM/"; ac_bdir="TSRM/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
96879  esac
96880
96881
96882
96883  b_c_pre=$php_c_pre
96884  b_cxx_pre=$php_cxx_pre
96885  b_c_meta=$php_c_meta
96886  b_cxx_meta=$php_cxx_meta
96887  b_c_post=$php_c_post
96888  b_cxx_post=$php_cxx_post
96889  b_lo=$php_lo
96890
96891
96892  old_IFS=$IFS
96893  for ac_src in TSRM.c; do
96894
96895      IFS=.
96896      set $ac_src
96897      ac_obj=$1
96898      IFS=$old_IFS
96899
96900      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
96901
96902      case $ac_src in
96903        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96904        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96905        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96906        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
96907      esac
96908
96909      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
96910
96911    cat >>Makefile.objects<<EOF
96912-include $ac_bdir$ac_obj.dep
96913$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
96914	$ac_comp
96915EOF
96916  done
96917
96918
96919
96920
96921
96922  case main in
96923  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
96924  /*) ac_srcdir=`echo "main"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
96925  *) ac_srcdir="$abs_srcdir/main/"; ac_bdir="main/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
96926  esac
96927
96928
96929
96930  b_c_pre=$php_c_pre
96931  b_cxx_pre=$php_cxx_pre
96932  b_c_meta=$php_c_meta
96933  b_cxx_meta=$php_cxx_meta
96934  b_c_post=$php_c_post
96935  b_cxx_post=$php_cxx_post
96936  b_lo=$php_lo
96937
96938
96939  old_IFS=$IFS
96940  for ac_src in main.c snprintf.c spprintf.c \
96941       fopen_wrappers.c alloca.c  php_scandir.c \
96942       php_ini.c SAPI.c rfc1867.c php_content_types.c strlcpy.c \
96943       strlcat.c explicit_bzero.c reentrancy.c php_variables.c php_ticks.c \
96944       network.c php_open_temporary_file.c \
96945       output.c getopt.c php_syslog.c; do
96946
96947      IFS=.
96948      set $ac_src
96949      ac_obj=$1
96950      IFS=$old_IFS
96951
96952      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
96953
96954      case $ac_src in
96955        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96956        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96957        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
96958        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
96959      esac
96960
96961      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
96962
96963    cat >>Makefile.objects<<EOF
96964-include $ac_bdir$ac_obj.dep
96965$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
96966	$ac_comp
96967EOF
96968  done
96969
96970
96971
96972
96973  case main in
96974  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
96975  /*) ac_srcdir=`echo "main"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
96976  *) ac_srcdir="$abs_srcdir/main/"; ac_bdir="main/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
96977  esac
96978
96979
96980
96981  b_c_pre=$php_c_pre
96982  b_cxx_pre=$php_cxx_pre
96983  b_c_meta=$php_c_meta
96984  b_cxx_meta=$php_cxx_meta
96985  b_c_post=$php_c_post
96986  b_cxx_post=$php_cxx_post
96987  b_lo=$php_lo
96988
96989
96990  old_IFS=$IFS
96991  for ac_src in fastcgi.c; do
96992
96993      IFS=.
96994      set $ac_src
96995      ac_obj=$1
96996      IFS=$old_IFS
96997
96998      PHP_FASTCGI_OBJS="$PHP_FASTCGI_OBJS $ac_bdir$ac_obj.lo"
96999
97000      case $ac_src in
97001        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97002        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97003        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97004        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
97005      esac
97006
97007      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
97008
97009    cat >>Makefile.objects<<EOF
97010-include $ac_bdir$ac_obj.dep
97011$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
97012	$ac_comp
97013EOF
97014  done
97015
97016
97017
97018
97019  case main/streams in
97020  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
97021  /*) ac_srcdir=`echo "main/streams"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
97022  *) ac_srcdir="$abs_srcdir/main/streams/"; ac_bdir="main/streams/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
97023  esac
97024
97025
97026
97027  b_c_pre=$php_c_pre
97028  b_cxx_pre=$php_cxx_pre
97029  b_c_meta=$php_c_meta
97030  b_cxx_meta=$php_cxx_meta
97031  b_c_post=$php_c_post
97032  b_cxx_post=$php_cxx_post
97033  b_lo=$php_lo
97034
97035
97036  old_IFS=$IFS
97037  for ac_src in streams.c cast.c memory.c filter.c \
97038       plain_wrapper.c userspace.c transports.c xp_socket.c mmap.c \
97039       glob_wrapper.c; do
97040
97041      IFS=.
97042      set $ac_src
97043      ac_obj=$1
97044      IFS=$old_IFS
97045
97046      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
97047
97048      case $ac_src in
97049        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97050        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97051        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97052        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
97053      esac
97054
97055      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
97056
97057    cat >>Makefile.objects<<EOF
97058-include $ac_bdir$ac_obj.dep
97059$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
97060	$ac_comp
97061EOF
97062  done
97063
97064
97065
97066
97067
97068  case /main in
97069  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
97070  /*) ac_srcdir=`echo "/main"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
97071  *) ac_srcdir="$abs_srcdir//main/"; ac_bdir="/main/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
97072  esac
97073
97074
97075
97076  b_c_pre=$php_c_pre
97077  b_cxx_pre=$php_cxx_pre
97078  b_c_meta=$php_c_meta
97079  b_cxx_meta=$php_cxx_meta
97080  b_c_post=$php_c_post
97081  b_cxx_post=$php_cxx_post
97082  b_lo=$php_lo
97083
97084
97085  old_IFS=$IFS
97086  for ac_src in internal_functions.c; do
97087
97088      IFS=.
97089      set $ac_src
97090      ac_obj=$1
97091      IFS=$old_IFS
97092
97093      PHP_SAPI_OBJS="$PHP_SAPI_OBJS $ac_bdir$ac_obj.lo"
97094
97095      case $ac_src in
97096        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97097        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97098        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97099        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
97100      esac
97101
97102      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
97103
97104    cat >>Makefile.objects<<EOF
97105-include $ac_bdir$ac_obj.dep
97106$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
97107	$ac_comp
97108EOF
97109  done
97110
97111
97112
97113  case /main in
97114  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
97115  /*) ac_srcdir=`echo "/main"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
97116  *) ac_srcdir="$abs_srcdir//main/"; ac_bdir="/main/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
97117  esac
97118
97119
97120
97121  b_c_pre=$php_c_pre
97122  b_cxx_pre=$php_cxx_pre
97123  b_c_meta=$php_c_meta
97124  b_cxx_meta=$php_cxx_meta
97125  b_c_post=$php_c_post
97126  b_cxx_post=$php_cxx_post
97127  b_lo=$php_lo
97128
97129
97130  old_IFS=$IFS
97131  for ac_src in internal_functions_cli.c; do
97132
97133      IFS=.
97134      set $ac_src
97135      ac_obj=$1
97136      IFS=$old_IFS
97137
97138      PHP_BINARY_OBJS="$PHP_BINARY_OBJS $ac_bdir$ac_obj.lo"
97139
97140      case $ac_src in
97141        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97142        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97143        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97144        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
97145      esac
97146
97147      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
97148
97149    cat >>Makefile.objects<<EOF
97150-include $ac_bdir$ac_obj.dep
97151$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
97152	$ac_comp
97153EOF
97154  done
97155
97156
97157
97158
97159  case Zend in
97160  "") ac_srcdir="$abs_srcdir/"; unset ac_bdir; ac_inc="-I. -I$abs_srcdir" ;;
97161  /*) ac_srcdir=`echo "Zend"|cut -c 2-`"/"; ac_bdir=$ac_srcdir; ac_inc="-I$ac_bdir -I$abs_srcdir/$ac_bdir" ;;
97162  *) ac_srcdir="$abs_srcdir/Zend/"; ac_bdir="Zend/"; ac_inc="-I$ac_bdir -I$ac_srcdir" ;;
97163  esac
97164
97165
97166
97167  b_c_pre=$php_c_pre
97168  b_cxx_pre=$php_cxx_pre
97169  b_c_meta=$php_c_meta
97170  b_cxx_meta=$php_cxx_meta
97171  b_c_post=$php_c_post
97172  b_cxx_post=$php_cxx_post
97173  b_lo=$php_lo
97174
97175
97176  old_IFS=$IFS
97177  for ac_src in \
97178    zend_language_parser.c zend_language_scanner.c \
97179    zend_ini_parser.c zend_ini_scanner.c \
97180    zend_alloc.c zend_compile.c zend_constants.c zend_dtrace.c \
97181    zend_execute_API.c zend_highlight.c zend_llist.c \
97182    zend_vm_opcodes.c zend_opcode.c zend_operators.c zend_ptr_stack.c zend_stack.c \
97183    zend_variables.c zend.c zend_API.c zend_extensions.c zend_hash.c \
97184    zend_list.c zend_builtin_functions.c zend_attributes.c zend_execute.c \
97185    zend_ini.c zend_sort.c zend_multibyte.c zend_stream.c \
97186    zend_iterators.c zend_interfaces.c zend_exceptions.c zend_strtod.c zend_gc.c \
97187    zend_closures.c zend_weakrefs.c zend_float.c zend_string.c zend_signal.c zend_generators.c \
97188    zend_virtual_cwd.c zend_ast.c zend_objects.c zend_object_handlers.c zend_objects_API.c \
97189    zend_default_classes.c zend_inheritance.c zend_smart_str.c zend_cpuinfo.c zend_gdb.c \
97190    zend_observer.c zend_system_id.c zend_enum.c zend_fibers.c \
97191	Optimizer/zend_optimizer.c \
97192	Optimizer/pass1.c \
97193	Optimizer/pass3.c \
97194	Optimizer/optimize_func_calls.c \
97195	Optimizer/block_pass.c \
97196	Optimizer/optimize_temp_vars_5.c \
97197	Optimizer/nop_removal.c \
97198	Optimizer/compact_literals.c \
97199	Optimizer/zend_cfg.c \
97200	Optimizer/zend_dfg.c \
97201	Optimizer/dfa_pass.c \
97202	Optimizer/zend_ssa.c \
97203	Optimizer/zend_inference.c \
97204	Optimizer/zend_func_info.c \
97205	Optimizer/zend_call_graph.c \
97206	Optimizer/sccp.c \
97207	Optimizer/scdf.c \
97208	Optimizer/dce.c \
97209	Optimizer/escape_analysis.c \
97210	Optimizer/compact_vars.c \
97211	Optimizer/zend_dump.c \
97212    ; do
97213
97214      IFS=.
97215      set $ac_src
97216      ac_obj=$1
97217      IFS=$old_IFS
97218
97219      PHP_GLOBAL_OBJS="$PHP_GLOBAL_OBJS $ac_bdir$ac_obj.lo"
97220
97221      case $ac_src in
97222        *.c) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97223        *.s) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97224        *.S) ac_comp="$b_c_pre $ac_inc $b_c_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_c_post" ;;
97225        *.cpp|*.cc|*.cxx) ac_comp="$b_cxx_pre $ac_inc $b_cxx_meta -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -c $ac_srcdir$ac_src -o $ac_bdir$ac_obj.$b_lo $b_cxx_post" ;;
97226      esac
97227
97228      ac_comp="$ac_comp -MMD -MF $ac_bdir$ac_obj.dep -MT $ac_bdir$ac_obj.lo"
97229
97230    cat >>Makefile.objects<<EOF
97231-include $ac_bdir$ac_obj.dep
97232$ac_bdir$ac_obj.lo: $ac_srcdir$ac_src
97233	$ac_comp
97234EOF
97235  done
97236
97237
97238
97239
97240
97241    BUILD_DIR="$BUILD_DIR main main/streams"
97242
97243
97244
97245
97246    BUILD_DIR="$BUILD_DIR TSRM"
97247
97248
97249
97250
97251    BUILD_DIR="$BUILD_DIR Zend Zend/asm Zend/Optimizer"
97252
97253
97254
97255
97256  src=$abs_srcdir/scripts/Makefile.frag
97257  ac_srcdir=$abs_srcdir/scripts
97258  ac_builddir=scripts
97259  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
97260
97261
97262  src=$abs_srcdir/Zend/Makefile.frag
97263  ac_srcdir=$abs_srcdir/Zend
97264  ac_builddir=Zend
97265  test -f "$src" && $SED -e "s#\$(srcdir)#$ac_srcdir#g" -e "s#\$(builddir)#$ac_builddir#g" $src  >> Makefile.fragments
97266
97267
97268
97269  $php_shtool mkdir -p $BUILD_DIR
97270
97271
97272  cat >Makefile <<EOF
97273srcdir = $abs_srcdir
97274builddir = $abs_builddir
97275top_srcdir = $abs_srcdir
97276top_builddir = $abs_builddir
97277EOF
97278  for i in $PHP_VAR_SUBST; do
97279    eval echo "$i = \$$i" >> Makefile
97280  done
97281
97282  cat $abs_srcdir/build/Makefile.global Makefile.fragments Makefile.objects >> Makefile
97283
97284
97285
97286printf "%s\n" "#define HAVE_BUILD_DEFS_H 1" >>confdefs.h
97287
97288
97289$php_shtool mkdir -p pear
97290$php_shtool mkdir -p scripts
97291$php_shtool mkdir -p scripts/man1
97292
97293ALL_OUTPUT_FILES="main/build-defs.h \
97294scripts/phpize scripts/man1/phpize.1 \
97295scripts/php-config scripts/man1/php-config.1 \
97296$PHP_OUTPUT_FILES"
97297
97298ac_config_files="$ac_config_files $ALL_OUTPUT_FILES"
97299
97300
97301
97302
97303ac_config_commands="$ac_config_commands default"
97304
97305cat >confcache <<\_ACEOF
97306# This file is a shell script that caches the results of configure
97307# tests run on this system so they can be shared between configure
97308# scripts and configure runs, see configure's option --config-cache.
97309# It is not useful on other systems.  If it contains results you don't
97310# want to keep, you may remove or edit it.
97311#
97312# config.status only pays attention to the cache file if you give it
97313# the --recheck option to rerun configure.
97314#
97315# `ac_cv_env_foo' variables (set or unset) will be overridden when
97316# loading this file, other *unset* `ac_cv_foo' will be assigned the
97317# following values.
97318
97319_ACEOF
97320
97321# The following way of writing the cache mishandles newlines in values,
97322# but we know of no workaround that is simple, portable, and efficient.
97323# So, we kill variables containing newlines.
97324# Ultrix sh set writes to stderr and can't be redirected directly,
97325# and sets the high bit in the cache file unless we assign to the vars.
97326(
97327  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
97328    eval ac_val=\$$ac_var
97329    case $ac_val in #(
97330    *${as_nl}*)
97331      case $ac_var in #(
97332      *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
97333printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
97334      esac
97335      case $ac_var in #(
97336      _ | IFS | as_nl) ;; #(
97337      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
97338      *) { eval $ac_var=; unset $ac_var;} ;;
97339      esac ;;
97340    esac
97341  done
97342
97343  (set) 2>&1 |
97344    case $as_nl`(ac_space=' '; set) 2>&1` in #(
97345    *${as_nl}ac_space=\ *)
97346      # `set' does not quote correctly, so add quotes: double-quote
97347      # substitution turns \\\\ into \\, and sed turns \\ into \.
97348      sed -n \
97349	"s/'/'\\\\''/g;
97350	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
97351      ;; #(
97352    *)
97353      # `set' quotes correctly as required by POSIX, so do not add quotes.
97354      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
97355      ;;
97356    esac |
97357    sort
97358) |
97359  sed '
97360     /^ac_cv_env_/b end
97361     t clear
97362     :clear
97363     s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
97364     t end
97365     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
97366     :end' >>confcache
97367if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
97368  if test -w "$cache_file"; then
97369    if test "x$cache_file" != "x/dev/null"; then
97370      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
97371printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
97372      if test ! -f "$cache_file" || test -h "$cache_file"; then
97373	cat confcache >"$cache_file"
97374      else
97375        case $cache_file in #(
97376        */* | ?:*)
97377	  mv -f confcache "$cache_file"$$ &&
97378	  mv -f "$cache_file"$$ "$cache_file" ;; #(
97379        *)
97380	  mv -f confcache "$cache_file" ;;
97381	esac
97382      fi
97383    fi
97384  else
97385    { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
97386printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
97387  fi
97388fi
97389rm -f confcache
97390
97391test "x$prefix" = xNONE && prefix=$ac_default_prefix
97392# Let make expand exec_prefix.
97393test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
97394
97395DEFS=-DHAVE_CONFIG_H
97396
97397ac_libobjs=
97398ac_ltlibobjs=
97399U=
97400for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
97401  # 1. Remove the extension, and $U if already installed.
97402  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
97403  ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
97404  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
97405  #    will be set to the directory where LIBOBJS objects are built.
97406  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
97407  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
97408done
97409LIBOBJS=$ac_libobjs
97410
97411LTLIBOBJS=$ac_ltlibobjs
97412
97413
97414
97415  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: patching main/php_config.h.in" >&5
97416printf "%s\n" "$as_me: patching main/php_config.h.in" >&6;}
97417
97418  $SED -e 's/^#undef PACKAGE_[^ ]*/\/\* & \*\//g' < $srcdir/main/php_config.h.in \
97419    > $srcdir/main/php_config.h.in.tmp && mv $srcdir/main/php_config.h.in.tmp $srcdir/main/php_config.h.in
97420
97421
97422: "${CONFIG_STATUS=./config.status}"
97423ac_write_fail=0
97424ac_clean_files_save=$ac_clean_files
97425ac_clean_files="$ac_clean_files $CONFIG_STATUS"
97426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
97427printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
97428as_write_fail=0
97429cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
97430#! $SHELL
97431# Generated by $as_me.
97432# Run this file to recreate the current configuration.
97433# Compiler output produced by configure, useful for debugging
97434# configure, is in config.log if it exists.
97435
97436debug=false
97437ac_cs_recheck=false
97438ac_cs_silent=false
97439
97440SHELL=\${CONFIG_SHELL-$SHELL}
97441export SHELL
97442_ASEOF
97443cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
97444## -------------------- ##
97445## M4sh Initialization. ##
97446## -------------------- ##
97447
97448# Be more Bourne compatible
97449DUALCASE=1; export DUALCASE # for MKS sh
97450as_nop=:
97451if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
97452then :
97453  emulate sh
97454  NULLCMD=:
97455  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
97456  # is contrary to our usage.  Disable this feature.
97457  alias -g '${1+"$@"}'='"$@"'
97458  setopt NO_GLOB_SUBST
97459else $as_nop
97460  case `(set -o) 2>/dev/null` in #(
97461  *posix*) :
97462    set -o posix ;; #(
97463  *) :
97464     ;;
97465esac
97466fi
97467
97468
97469
97470# Reset variables that may have inherited troublesome values from
97471# the environment.
97472
97473# IFS needs to be set, to space, tab, and newline, in precisely that order.
97474# (If _AS_PATH_WALK were called with IFS unset, it would have the
97475# side effect of setting IFS to empty, thus disabling word splitting.)
97476# Quoting is to prevent editors from complaining about space-tab.
97477as_nl='
97478'
97479export as_nl
97480IFS=" ""	$as_nl"
97481
97482PS1='$ '
97483PS2='> '
97484PS4='+ '
97485
97486# Ensure predictable behavior from utilities with locale-dependent output.
97487LC_ALL=C
97488export LC_ALL
97489LANGUAGE=C
97490export LANGUAGE
97491
97492# We cannot yet rely on "unset" to work, but we need these variables
97493# to be unset--not just set to an empty or harmless value--now, to
97494# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh).  This construct
97495# also avoids known problems related to "unset" and subshell syntax
97496# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
97497for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
97498do eval test \${$as_var+y} \
97499  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
97500done
97501
97502# Ensure that fds 0, 1, and 2 are open.
97503if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
97504if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
97505if (exec 3>&2)            ; then :; else exec 2>/dev/null; fi
97506
97507# The user is always right.
97508if ${PATH_SEPARATOR+false} :; then
97509  PATH_SEPARATOR=:
97510  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
97511    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
97512      PATH_SEPARATOR=';'
97513  }
97514fi
97515
97516
97517# Find who we are.  Look in the path if we contain no directory separator.
97518as_myself=
97519case $0 in #((
97520  *[\\/]* ) as_myself=$0 ;;
97521  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
97522for as_dir in $PATH
97523do
97524  IFS=$as_save_IFS
97525  case $as_dir in #(((
97526    '') as_dir=./ ;;
97527    */) ;;
97528    *) as_dir=$as_dir/ ;;
97529  esac
97530    test -r "$as_dir$0" && as_myself=$as_dir$0 && break
97531  done
97532IFS=$as_save_IFS
97533
97534     ;;
97535esac
97536# We did not find ourselves, most probably we were run as `sh COMMAND'
97537# in which case we are not to be found in the path.
97538if test "x$as_myself" = x; then
97539  as_myself=$0
97540fi
97541if test ! -f "$as_myself"; then
97542  printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
97543  exit 1
97544fi
97545
97546
97547
97548# as_fn_error STATUS ERROR [LINENO LOG_FD]
97549# ----------------------------------------
97550# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
97551# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
97552# script with STATUS, using 1 if that was 0.
97553as_fn_error ()
97554{
97555  as_status=$1; test $as_status -eq 0 && as_status=1
97556  if test "$4"; then
97557    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
97558    printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
97559  fi
97560  printf "%s\n" "$as_me: error: $2" >&2
97561  as_fn_exit $as_status
97562} # as_fn_error
97563
97564
97565
97566# as_fn_set_status STATUS
97567# -----------------------
97568# Set $? to STATUS, without forking.
97569as_fn_set_status ()
97570{
97571  return $1
97572} # as_fn_set_status
97573
97574# as_fn_exit STATUS
97575# -----------------
97576# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
97577as_fn_exit ()
97578{
97579  set +e
97580  as_fn_set_status $1
97581  exit $1
97582} # as_fn_exit
97583
97584# as_fn_unset VAR
97585# ---------------
97586# Portably unset VAR.
97587as_fn_unset ()
97588{
97589  { eval $1=; unset $1;}
97590}
97591as_unset=as_fn_unset
97592
97593# as_fn_append VAR VALUE
97594# ----------------------
97595# Append the text in VALUE to the end of the definition contained in VAR. Take
97596# advantage of any shell optimizations that allow amortized linear growth over
97597# repeated appends, instead of the typical quadratic growth present in naive
97598# implementations.
97599if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
97600then :
97601  eval 'as_fn_append ()
97602  {
97603    eval $1+=\$2
97604  }'
97605else $as_nop
97606  as_fn_append ()
97607  {
97608    eval $1=\$$1\$2
97609  }
97610fi # as_fn_append
97611
97612# as_fn_arith ARG...
97613# ------------------
97614# Perform arithmetic evaluation on the ARGs, and store the result in the
97615# global $as_val. Take advantage of shells that can avoid forks. The arguments
97616# must be portable across $(()) and expr.
97617if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
97618then :
97619  eval 'as_fn_arith ()
97620  {
97621    as_val=$(( $* ))
97622  }'
97623else $as_nop
97624  as_fn_arith ()
97625  {
97626    as_val=`expr "$@" || test $? -eq 1`
97627  }
97628fi # as_fn_arith
97629
97630
97631if expr a : '\(a\)' >/dev/null 2>&1 &&
97632   test "X`expr 00001 : '.*\(...\)'`" = X001; then
97633  as_expr=expr
97634else
97635  as_expr=false
97636fi
97637
97638if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
97639  as_basename=basename
97640else
97641  as_basename=false
97642fi
97643
97644if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
97645  as_dirname=dirname
97646else
97647  as_dirname=false
97648fi
97649
97650as_me=`$as_basename -- "$0" ||
97651$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
97652	 X"$0" : 'X\(//\)$' \| \
97653	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
97654printf "%s\n" X/"$0" |
97655    sed '/^.*\/\([^/][^/]*\)\/*$/{
97656	    s//\1/
97657	    q
97658	  }
97659	  /^X\/\(\/\/\)$/{
97660	    s//\1/
97661	    q
97662	  }
97663	  /^X\/\(\/\).*/{
97664	    s//\1/
97665	    q
97666	  }
97667	  s/.*/./; q'`
97668
97669# Avoid depending upon Character Ranges.
97670as_cr_letters='abcdefghijklmnopqrstuvwxyz'
97671as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
97672as_cr_Letters=$as_cr_letters$as_cr_LETTERS
97673as_cr_digits='0123456789'
97674as_cr_alnum=$as_cr_Letters$as_cr_digits
97675
97676
97677# Determine whether it's possible to make 'echo' print without a newline.
97678# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
97679# for compatibility with existing Makefiles.
97680ECHO_C= ECHO_N= ECHO_T=
97681case `echo -n x` in #(((((
97682-n*)
97683  case `echo 'xy\c'` in
97684  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
97685  xy)  ECHO_C='\c';;
97686  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
97687       ECHO_T='	';;
97688  esac;;
97689*)
97690  ECHO_N='-n';;
97691esac
97692
97693# For backward compatibility with old third-party macros, we provide
97694# the shell variables $as_echo and $as_echo_n.  New code should use
97695# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
97696as_echo='printf %s\n'
97697as_echo_n='printf %s'
97698
97699rm -f conf$$ conf$$.exe conf$$.file
97700if test -d conf$$.dir; then
97701  rm -f conf$$.dir/conf$$.file
97702else
97703  rm -f conf$$.dir
97704  mkdir conf$$.dir 2>/dev/null
97705fi
97706if (echo >conf$$.file) 2>/dev/null; then
97707  if ln -s conf$$.file conf$$ 2>/dev/null; then
97708    as_ln_s='ln -s'
97709    # ... but there are two gotchas:
97710    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
97711    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
97712    # In both cases, we have to default to `cp -pR'.
97713    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
97714      as_ln_s='cp -pR'
97715  elif ln conf$$.file conf$$ 2>/dev/null; then
97716    as_ln_s=ln
97717  else
97718    as_ln_s='cp -pR'
97719  fi
97720else
97721  as_ln_s='cp -pR'
97722fi
97723rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
97724rmdir conf$$.dir 2>/dev/null
97725
97726
97727# as_fn_mkdir_p
97728# -------------
97729# Create "$as_dir" as a directory, including parents if necessary.
97730as_fn_mkdir_p ()
97731{
97732
97733  case $as_dir in #(
97734  -*) as_dir=./$as_dir;;
97735  esac
97736  test -d "$as_dir" || eval $as_mkdir_p || {
97737    as_dirs=
97738    while :; do
97739      case $as_dir in #(
97740      *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
97741      *) as_qdir=$as_dir;;
97742      esac
97743      as_dirs="'$as_qdir' $as_dirs"
97744      as_dir=`$as_dirname -- "$as_dir" ||
97745$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
97746	 X"$as_dir" : 'X\(//\)[^/]' \| \
97747	 X"$as_dir" : 'X\(//\)$' \| \
97748	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
97749printf "%s\n" X"$as_dir" |
97750    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
97751	    s//\1/
97752	    q
97753	  }
97754	  /^X\(\/\/\)[^/].*/{
97755	    s//\1/
97756	    q
97757	  }
97758	  /^X\(\/\/\)$/{
97759	    s//\1/
97760	    q
97761	  }
97762	  /^X\(\/\).*/{
97763	    s//\1/
97764	    q
97765	  }
97766	  s/.*/./; q'`
97767      test -d "$as_dir" && break
97768    done
97769    test -z "$as_dirs" || eval "mkdir $as_dirs"
97770  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
97771
97772
97773} # as_fn_mkdir_p
97774if mkdir -p . 2>/dev/null; then
97775  as_mkdir_p='mkdir -p "$as_dir"'
97776else
97777  test -d ./-p && rmdir ./-p
97778  as_mkdir_p=false
97779fi
97780
97781
97782# as_fn_executable_p FILE
97783# -----------------------
97784# Test if FILE is an executable regular file.
97785as_fn_executable_p ()
97786{
97787  test -f "$1" && test -x "$1"
97788} # as_fn_executable_p
97789as_test_x='test -x'
97790as_executable_p=as_fn_executable_p
97791
97792# Sed expression to map a string onto a valid CPP name.
97793as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
97794
97795# Sed expression to map a string onto a valid variable name.
97796as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
97797
97798
97799exec 6>&1
97800## ----------------------------------- ##
97801## Main body of $CONFIG_STATUS script. ##
97802## ----------------------------------- ##
97803_ASEOF
97804test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
97805
97806cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
97807# Save the log message, to keep $0 and so on meaningful, and to
97808# report actual input values of CONFIG_FILES etc. instead of their
97809# values after options handling.
97810ac_log="
97811This file was extended by PHP $as_me 8.1.1, which was
97812generated by GNU Autoconf 2.71.  Invocation command line was
97813
97814  CONFIG_FILES    = $CONFIG_FILES
97815  CONFIG_HEADERS  = $CONFIG_HEADERS
97816  CONFIG_LINKS    = $CONFIG_LINKS
97817  CONFIG_COMMANDS = $CONFIG_COMMANDS
97818  $ $0 $@
97819
97820on `(hostname || uname -n) 2>/dev/null | sed 1q`
97821"
97822
97823_ACEOF
97824
97825case $ac_config_files in *"
97826"*) set x $ac_config_files; shift; ac_config_files=$*;;
97827esac
97828
97829case $ac_config_headers in *"
97830"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
97831esac
97832
97833
97834cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
97835# Files that config.status was made for.
97836config_files="$ac_config_files"
97837config_headers="$ac_config_headers"
97838config_commands="$ac_config_commands"
97839
97840_ACEOF
97841
97842cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
97843ac_cs_usage="\
97844\`$as_me' instantiates files and other configuration actions
97845from templates according to the current configuration.  Unless the files
97846and actions are specified as TAGs, all are instantiated by default.
97847
97848Usage: $0 [OPTION]... [TAG]...
97849
97850  -h, --help       print this help, then exit
97851  -V, --version    print version number and configuration settings, then exit
97852      --config     print configuration, then exit
97853  -q, --quiet, --silent
97854                   do not print progress messages
97855  -d, --debug      don't remove temporary files
97856      --recheck    update $as_me by reconfiguring in the same conditions
97857      --file=FILE[:TEMPLATE]
97858                   instantiate the configuration file FILE
97859      --header=FILE[:TEMPLATE]
97860                   instantiate the configuration header FILE
97861
97862Configuration files:
97863$config_files
97864
97865Configuration headers:
97866$config_headers
97867
97868Configuration commands:
97869$config_commands
97870
97871Report bugs to <https://bugs.php.net>.
97872PHP home page: <https://www.php.net>."
97873
97874_ACEOF
97875ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
97876ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
97877cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
97878ac_cs_config='$ac_cs_config_escaped'
97879ac_cs_version="\\
97880PHP config.status 8.1.1
97881configured by $0, generated by GNU Autoconf 2.71,
97882  with options \\"\$ac_cs_config\\"
97883
97884Copyright (C) 2021 Free Software Foundation, Inc.
97885This config.status script is free software; the Free Software Foundation
97886gives unlimited permission to copy, distribute and modify it."
97887
97888ac_pwd='$ac_pwd'
97889srcdir='$srcdir'
97890test -n "\$AWK" || AWK=awk
97891_ACEOF
97892
97893cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
97894# The default lists apply if the user does not specify any file.
97895ac_need_defaults=:
97896while test $# != 0
97897do
97898  case $1 in
97899  --*=?*)
97900    ac_option=`expr "X$1" : 'X\([^=]*\)='`
97901    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
97902    ac_shift=:
97903    ;;
97904  --*=)
97905    ac_option=`expr "X$1" : 'X\([^=]*\)='`
97906    ac_optarg=
97907    ac_shift=:
97908    ;;
97909  *)
97910    ac_option=$1
97911    ac_optarg=$2
97912    ac_shift=shift
97913    ;;
97914  esac
97915
97916  case $ac_option in
97917  # Handling of the options.
97918  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
97919    ac_cs_recheck=: ;;
97920  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
97921    printf "%s\n" "$ac_cs_version"; exit ;;
97922  --config | --confi | --conf | --con | --co | --c )
97923    printf "%s\n" "$ac_cs_config"; exit ;;
97924  --debug | --debu | --deb | --de | --d | -d )
97925    debug=: ;;
97926  --file | --fil | --fi | --f )
97927    $ac_shift
97928    case $ac_optarg in
97929    *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
97930    '') as_fn_error $? "missing file argument" ;;
97931    esac
97932    as_fn_append CONFIG_FILES " '$ac_optarg'"
97933    ac_need_defaults=false;;
97934  --header | --heade | --head | --hea )
97935    $ac_shift
97936    case $ac_optarg in
97937    *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
97938    esac
97939    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
97940    ac_need_defaults=false;;
97941  --he | --h)
97942    # Conflict between --help and --header
97943    as_fn_error $? "ambiguous option: \`$1'
97944Try \`$0 --help' for more information.";;
97945  --help | --hel | -h )
97946    printf "%s\n" "$ac_cs_usage"; exit ;;
97947  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
97948  | -silent | --silent | --silen | --sile | --sil | --si | --s)
97949    ac_cs_silent=: ;;
97950
97951  # This is an error.
97952  -*) as_fn_error $? "unrecognized option: \`$1'
97953Try \`$0 --help' for more information." ;;
97954
97955  *) as_fn_append ac_config_targets " $1"
97956     ac_need_defaults=false ;;
97957
97958  esac
97959  shift
97960done
97961
97962ac_configure_extra_args=
97963
97964if $ac_cs_silent; then
97965  exec 6>/dev/null
97966  ac_configure_extra_args="$ac_configure_extra_args --silent"
97967fi
97968
97969_ACEOF
97970cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
97971if \$ac_cs_recheck; then
97972  set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
97973  shift
97974  \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
97975  CONFIG_SHELL='$SHELL'
97976  export CONFIG_SHELL
97977  exec "\$@"
97978fi
97979
97980_ACEOF
97981cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
97982exec 5>>config.log
97983{
97984  echo
97985  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
97986## Running $as_me. ##
97987_ASBOX
97988  printf "%s\n" "$ac_log"
97989} >&5
97990
97991_ACEOF
97992cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
97993#
97994# INIT-COMMANDS
97995#
97996
97997
97998if test "\$CONFIG_FILES" = "$ALL_OUTPUT_FILES" || test "\$CONFIG_FILES" = " $ALL_OUTPUT_FILES" || test -z "\$CONFIG_FILES"; then
97999  REDO_ALL=yes
98000fi
98001
98002test -d Zend || $php_shtool mkdir Zend
98003
98004cat >Zend/zend_config.h <<FEO
98005#include <../main/php_config.h>
98006FEO
98007
98008if test -n "\$REDO_ALL"; then
98009  echo "creating main/internal_functions.c"
98010  AWK="$AWK" sh $srcdir/build/genif.sh $srcdir/main/internal_functions.c.in "$EXT_STATIC" > main/internal_functions.c
98011
98012  echo "creating main/internal_functions_cli.c"
98013  AWK="$AWK" sh $srcdir/build/genif.sh $srcdir/main/internal_functions.c.in "$EXT_CLI_STATIC" > main/internal_functions_cli.c
98014
98015    if test "$PHP_SAPI" = "apache2handler"; then
98016      if test "$APACHE_VERSION" -ge 2004001; then
98017        if test -z "$APACHE_THREADED_MPM"; then
98018cat <<X
98019+--------------------------------------------------------------------+
98020|                        *** WARNING ***                             |
98021|                                                                    |
98022| You have built PHP for Apache's current non-threaded MPM.          |
98023| If you change Apache to use a threaded MPM you must reconfigure    |
98024| PHP with --enable-zts                                              |
98025X
98026        fi
98027      fi
98028    fi
98029
98030    if test "$PHP_OCI8" != "no"; then
98031    if test "$PHP_SIGCHILD" != "yes"; then
98032      if test "$PHP_OCI8_INSTANT_CLIENT" = "no"; then
98033cat <<X
98034+--------------------------------------------------------------------+
98035| Notice:                                                            |
98036| If you encounter <defunc> processes when using a local Oracle      |
98037| database, set the value BEQUEATH_DETACH=YES in Oracle Net's        |
98038| sqlnet.ora file on the PHP host, or set the environment variable   |
98039| BEQUEATH_DETACH to YES before starting Apache.  If the problem     |
98040| still occurs, then recompile PHP and specify --enable-sigchild     |
98041| when configuring.                                                  |
98042X
98043      fi
98044    fi
98045  fi
98046
98047fi
98048
98049
98050_ACEOF
98051
98052cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98053
98054# Handling of arguments.
98055for ac_config_target in $ac_config_targets
98056do
98057  case $ac_config_target in
98058    "main/php_config.h") CONFIG_HEADERS="$CONFIG_HEADERS main/php_config.h" ;;
98059    "$ALL_OUTPUT_FILES") CONFIG_FILES="$CONFIG_FILES $ALL_OUTPUT_FILES" ;;
98060    "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
98061
98062  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
98063  esac
98064done
98065
98066
98067# If the user did not use the arguments to specify the items to instantiate,
98068# then the envvar interface is used.  Set only those that are not.
98069# We use the long form for the default assignment because of an extremely
98070# bizarre bug on SunOS 4.1.3.
98071if $ac_need_defaults; then
98072  test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
98073  test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers
98074  test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands
98075fi
98076
98077# Have a temporary directory for convenience.  Make it in the build tree
98078# simply because there is no reason against having it here, and in addition,
98079# creating and moving files from /tmp can sometimes cause problems.
98080# Hook for its removal unless debugging.
98081# Note that there is a small window in which the directory will not be cleaned:
98082# after its creation but before its name has been assigned to `$tmp'.
98083$debug ||
98084{
98085  tmp= ac_tmp=
98086  trap 'exit_status=$?
98087  : "${ac_tmp:=$tmp}"
98088  { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
98089' 0
98090  trap 'as_fn_exit 1' 1 2 13 15
98091}
98092# Create a (secure) tmp directory for tmp files.
98093
98094{
98095  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
98096  test -d "$tmp"
98097}  ||
98098{
98099  tmp=./conf$$-$RANDOM
98100  (umask 077 && mkdir "$tmp")
98101} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
98102ac_tmp=$tmp
98103
98104# Set up the scripts for CONFIG_FILES section.
98105# No need to generate them if there are no CONFIG_FILES.
98106# This happens for instance with `./config.status config.h'.
98107if test -n "$CONFIG_FILES"; then
98108
98109
98110ac_cr=`echo X | tr X '\015'`
98111# On cygwin, bash can eat \r inside `` if the user requested igncr.
98112# But we know of no other shell where ac_cr would be empty at this
98113# point, so we can use a bashism as a fallback.
98114if test "x$ac_cr" = x; then
98115  eval ac_cr=\$\'\\r\'
98116fi
98117ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
98118if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
98119  ac_cs_awk_cr='\\r'
98120else
98121  ac_cs_awk_cr=$ac_cr
98122fi
98123
98124echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
98125_ACEOF
98126
98127
98128{
98129  echo "cat >conf$$subs.awk <<_ACEOF" &&
98130  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
98131  echo "_ACEOF"
98132} >conf$$subs.sh ||
98133  as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
98134ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
98135ac_delim='%!_!# '
98136for ac_last_try in false false false false false :; do
98137  . ./conf$$subs.sh ||
98138    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
98139
98140  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
98141  if test $ac_delim_n = $ac_delim_num; then
98142    break
98143  elif $ac_last_try; then
98144    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
98145  else
98146    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
98147  fi
98148done
98149rm -f conf$$subs.sh
98150
98151cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
98152cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
98153_ACEOF
98154sed -n '
98155h
98156s/^/S["/; s/!.*/"]=/
98157p
98158g
98159s/^[^!]*!//
98160:repl
98161t repl
98162s/'"$ac_delim"'$//
98163t delim
98164:nl
98165h
98166s/\(.\{148\}\)..*/\1/
98167t more1
98168s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
98169p
98170n
98171b repl
98172:more1
98173s/["\\]/\\&/g; s/^/"/; s/$/"\\/
98174p
98175g
98176s/.\{148\}//
98177t nl
98178:delim
98179h
98180s/\(.\{148\}\)..*/\1/
98181t more2
98182s/["\\]/\\&/g; s/^/"/; s/$/"/
98183p
98184b
98185:more2
98186s/["\\]/\\&/g; s/^/"/; s/$/"\\/
98187p
98188g
98189s/.\{148\}//
98190t delim
98191' <conf$$subs.awk | sed '
98192/^[^""]/{
98193  N
98194  s/\n//
98195}
98196' >>$CONFIG_STATUS || ac_write_fail=1
98197rm -f conf$$subs.awk
98198cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
98199_ACAWK
98200cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
98201  for (key in S) S_is_set[key] = 1
98202  FS = ""
98203
98204}
98205{
98206  line = $ 0
98207  nfields = split(line, field, "@")
98208  substed = 0
98209  len = length(field[1])
98210  for (i = 2; i < nfields; i++) {
98211    key = field[i]
98212    keylen = length(key)
98213    if (S_is_set[key]) {
98214      value = S[key]
98215      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
98216      len += length(value) + length(field[++i])
98217      substed = 1
98218    } else
98219      len += 1 + keylen
98220  }
98221
98222  print line
98223}
98224
98225_ACAWK
98226_ACEOF
98227cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98228if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
98229  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
98230else
98231  cat
98232fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
98233  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
98234_ACEOF
98235
98236# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
98237# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
98238# trailing colons and then remove the whole line if VPATH becomes empty
98239# (actually we leave an empty line to preserve line numbers).
98240if test "x$srcdir" = x.; then
98241  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
98242h
98243s///
98244s/^/:/
98245s/[	 ]*$/:/
98246s/:\$(srcdir):/:/g
98247s/:\${srcdir}:/:/g
98248s/:@srcdir@:/:/g
98249s/^:*//
98250s/:*$//
98251x
98252s/\(=[	 ]*\).*/\1/
98253G
98254s/\n//
98255s/^[^=]*=[	 ]*$//
98256}'
98257fi
98258
98259cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98260fi # test -n "$CONFIG_FILES"
98261
98262# Set up the scripts for CONFIG_HEADERS section.
98263# No need to generate them if there are no CONFIG_HEADERS.
98264# This happens for instance with `./config.status Makefile'.
98265if test -n "$CONFIG_HEADERS"; then
98266cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
98267BEGIN {
98268_ACEOF
98269
98270# Transform confdefs.h into an awk script `defines.awk', embedded as
98271# here-document in config.status, that substitutes the proper values into
98272# config.h.in to produce config.h.
98273
98274# Create a delimiter string that does not exist in confdefs.h, to ease
98275# handling of long lines.
98276ac_delim='%!_!# '
98277for ac_last_try in false false :; do
98278  ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
98279  if test -z "$ac_tt"; then
98280    break
98281  elif $ac_last_try; then
98282    as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
98283  else
98284    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
98285  fi
98286done
98287
98288# For the awk script, D is an array of macro values keyed by name,
98289# likewise P contains macro parameters if any.  Preserve backslash
98290# newline sequences.
98291
98292ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
98293sed -n '
98294s/.\{148\}/&'"$ac_delim"'/g
98295t rset
98296:rset
98297s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
98298t def
98299d
98300:def
98301s/\\$//
98302t bsnl
98303s/["\\]/\\&/g
98304s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
98305D["\1"]=" \3"/p
98306s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
98307d
98308:bsnl
98309s/["\\]/\\&/g
98310s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
98311D["\1"]=" \3\\\\\\n"\\/p
98312t cont
98313s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
98314t cont
98315d
98316:cont
98317n
98318s/.\{148\}/&'"$ac_delim"'/g
98319t clear
98320:clear
98321s/\\$//
98322t bsnlc
98323s/["\\]/\\&/g; s/^/"/; s/$/"/p
98324d
98325:bsnlc
98326s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
98327b cont
98328' <confdefs.h | sed '
98329s/'"$ac_delim"'/"\\\
98330"/g' >>$CONFIG_STATUS || ac_write_fail=1
98331
98332cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
98333  for (key in D) D_is_set[key] = 1
98334  FS = ""
98335}
98336/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
98337  line = \$ 0
98338  split(line, arg, " ")
98339  if (arg[1] == "#") {
98340    defundef = arg[2]
98341    mac1 = arg[3]
98342  } else {
98343    defundef = substr(arg[1], 2)
98344    mac1 = arg[2]
98345  }
98346  split(mac1, mac2, "(") #)
98347  macro = mac2[1]
98348  prefix = substr(line, 1, index(line, defundef) - 1)
98349  if (D_is_set[macro]) {
98350    # Preserve the white space surrounding the "#".
98351    print prefix "define", macro P[macro] D[macro]
98352    next
98353  } else {
98354    # Replace #undef with comments.  This is necessary, for example,
98355    # in the case of _POSIX_SOURCE, which is predefined and required
98356    # on some systems where configure will not decide to define it.
98357    if (defundef == "undef") {
98358      print "/*", prefix defundef, macro, "*/"
98359      next
98360    }
98361  }
98362}
98363{ print }
98364_ACAWK
98365_ACEOF
98366cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98367  as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
98368fi # test -n "$CONFIG_HEADERS"
98369
98370
98371eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
98372shift
98373for ac_tag
98374do
98375  case $ac_tag in
98376  :[FHLC]) ac_mode=$ac_tag; continue;;
98377  esac
98378  case $ac_mode$ac_tag in
98379  :[FHL]*:*);;
98380  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
98381  :[FH]-) ac_tag=-:-;;
98382  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
98383  esac
98384  ac_save_IFS=$IFS
98385  IFS=:
98386  set x $ac_tag
98387  IFS=$ac_save_IFS
98388  shift
98389  ac_file=$1
98390  shift
98391
98392  case $ac_mode in
98393  :L) ac_source=$1;;
98394  :[FH])
98395    ac_file_inputs=
98396    for ac_f
98397    do
98398      case $ac_f in
98399      -) ac_f="$ac_tmp/stdin";;
98400      *) # Look for the file first in the build tree, then in the source tree
98401	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
98402	 # because $ac_f cannot contain `:'.
98403	 test -f "$ac_f" ||
98404	   case $ac_f in
98405	   [\\/$]*) false;;
98406	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
98407	   esac ||
98408	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
98409      esac
98410      case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
98411      as_fn_append ac_file_inputs " '$ac_f'"
98412    done
98413
98414    # Let's still pretend it is `configure' which instantiates (i.e., don't
98415    # use $as_me), people would be surprised to read:
98416    #    /* config.h.  Generated by config.status.  */
98417    configure_input='Generated from '`
98418	  printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
98419	`' by configure.'
98420    if test x"$ac_file" != x-; then
98421      configure_input="$ac_file.  $configure_input"
98422      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
98423printf "%s\n" "$as_me: creating $ac_file" >&6;}
98424    fi
98425    # Neutralize special characters interpreted by sed in replacement strings.
98426    case $configure_input in #(
98427    *\&* | *\|* | *\\* )
98428       ac_sed_conf_input=`printf "%s\n" "$configure_input" |
98429       sed 's/[\\\\&|]/\\\\&/g'`;; #(
98430    *) ac_sed_conf_input=$configure_input;;
98431    esac
98432
98433    case $ac_tag in
98434    *:-:* | *:-) cat >"$ac_tmp/stdin" \
98435      || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
98436    esac
98437    ;;
98438  esac
98439
98440  ac_dir=`$as_dirname -- "$ac_file" ||
98441$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
98442	 X"$ac_file" : 'X\(//\)[^/]' \| \
98443	 X"$ac_file" : 'X\(//\)$' \| \
98444	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
98445printf "%s\n" X"$ac_file" |
98446    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
98447	    s//\1/
98448	    q
98449	  }
98450	  /^X\(\/\/\)[^/].*/{
98451	    s//\1/
98452	    q
98453	  }
98454	  /^X\(\/\/\)$/{
98455	    s//\1/
98456	    q
98457	  }
98458	  /^X\(\/\).*/{
98459	    s//\1/
98460	    q
98461	  }
98462	  s/.*/./; q'`
98463  as_dir="$ac_dir"; as_fn_mkdir_p
98464  ac_builddir=.
98465
98466case "$ac_dir" in
98467.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
98468*)
98469  ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
98470  # A ".." for each directory in $ac_dir_suffix.
98471  ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
98472  case $ac_top_builddir_sub in
98473  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
98474  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
98475  esac ;;
98476esac
98477ac_abs_top_builddir=$ac_pwd
98478ac_abs_builddir=$ac_pwd$ac_dir_suffix
98479# for backward compatibility:
98480ac_top_builddir=$ac_top_build_prefix
98481
98482case $srcdir in
98483  .)  # We are building in place.
98484    ac_srcdir=.
98485    ac_top_srcdir=$ac_top_builddir_sub
98486    ac_abs_top_srcdir=$ac_pwd ;;
98487  [\\/]* | ?:[\\/]* )  # Absolute name.
98488    ac_srcdir=$srcdir$ac_dir_suffix;
98489    ac_top_srcdir=$srcdir
98490    ac_abs_top_srcdir=$srcdir ;;
98491  *) # Relative name.
98492    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
98493    ac_top_srcdir=$ac_top_build_prefix$srcdir
98494    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
98495esac
98496ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
98497
98498
98499  case $ac_mode in
98500  :F)
98501  #
98502  # CONFIG_FILE
98503  #
98504
98505_ACEOF
98506
98507cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98508# If the template does not know about datarootdir, expand it.
98509# FIXME: This hack should be removed a few years after 2.60.
98510ac_datarootdir_hack=; ac_datarootdir_seen=
98511ac_sed_dataroot='
98512/datarootdir/ {
98513  p
98514  q
98515}
98516/@datadir@/p
98517/@docdir@/p
98518/@infodir@/p
98519/@localedir@/p
98520/@mandir@/p'
98521case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
98522*datarootdir*) ac_datarootdir_seen=yes;;
98523*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
98524  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
98525printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
98526_ACEOF
98527cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
98528  ac_datarootdir_hack='
98529  s&@datadir@&$datadir&g
98530  s&@docdir@&$docdir&g
98531  s&@infodir@&$infodir&g
98532  s&@localedir@&$localedir&g
98533  s&@mandir@&$mandir&g
98534  s&\\\${datarootdir}&$datarootdir&g' ;;
98535esac
98536_ACEOF
98537
98538# Neutralize VPATH when `$srcdir' = `.'.
98539# Shell code in configure.ac might set extrasub.
98540# FIXME: do we really want to maintain this feature?
98541cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
98542ac_sed_extra="$ac_vpsub
98543$extrasub
98544_ACEOF
98545cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
98546:t
98547/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
98548s|@configure_input@|$ac_sed_conf_input|;t t
98549s&@top_builddir@&$ac_top_builddir_sub&;t t
98550s&@top_build_prefix@&$ac_top_build_prefix&;t t
98551s&@srcdir@&$ac_srcdir&;t t
98552s&@abs_srcdir@&$ac_abs_srcdir&;t t
98553s&@top_srcdir@&$ac_top_srcdir&;t t
98554s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
98555s&@builddir@&$ac_builddir&;t t
98556s&@abs_builddir@&$ac_abs_builddir&;t t
98557s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
98558$ac_datarootdir_hack
98559"
98560eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
98561  >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
98562
98563test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
98564  { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
98565  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' \
98566      "$ac_tmp/out"`; test -z "$ac_out"; } &&
98567  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
98568which seems to be undefined.  Please make sure it is defined" >&5
98569printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
98570which seems to be undefined.  Please make sure it is defined" >&2;}
98571
98572  rm -f "$ac_tmp/stdin"
98573  case $ac_file in
98574  -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
98575  *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
98576  esac \
98577  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
98578 ;;
98579  :H)
98580  #
98581  # CONFIG_HEADER
98582  #
98583  if test x"$ac_file" != x-; then
98584    {
98585      printf "%s\n" "/* $configure_input  */" >&1 \
98586      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
98587    } >"$ac_tmp/config.h" \
98588      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
98589    if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
98590      { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
98591printf "%s\n" "$as_me: $ac_file is unchanged" >&6;}
98592    else
98593      rm -f "$ac_file"
98594      mv "$ac_tmp/config.h" "$ac_file" \
98595	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
98596    fi
98597  else
98598    printf "%s\n" "/* $configure_input  */" >&1 \
98599      && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
98600      || as_fn_error $? "could not create -" "$LINENO" 5
98601  fi
98602 ;;
98603
98604  :C)  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
98605printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
98606 ;;
98607  esac
98608
98609
98610  case $ac_file$ac_mode in
98611    "default":C)
98612cat <<X
98613
98614+--------------------------------------------------------------------+
98615| License:                                                           |
98616| This software is subject to the PHP License, available in this     |
98617| distribution in the file LICENSE. By continuing this installation  |
98618| process, you are bound by the terms of this license agreement.     |
98619| If you do not agree with the terms of this license, you must abort |
98620| the installation process at this point.                            |
98621+--------------------------------------------------------------------+
98622
98623Thank you for using PHP.
98624
98625X
98626 ;;
98627
98628  esac
98629done # for ac_tag
98630
98631
98632as_fn_exit 0
98633_ACEOF
98634ac_clean_files=$ac_clean_files_save
98635
98636test $ac_write_fail = 0 ||
98637  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
98638
98639
98640# configure is writing to config.log, and then calls config.status.
98641# config.status does its own redirection, appending to config.log.
98642# Unfortunately, on DOS this fails, as config.log is still kept open
98643# by configure, so config.status won't be able to write to it; its
98644# output is simply discarded.  So we exec the FD to /dev/null,
98645# effectively closing config.log, so it can be properly (re)opened and
98646# appended to by config.status.  When coming back to configure, we
98647# need to make the FD available again.
98648if test "$no_create" != yes; then
98649  ac_cs_success=:
98650  ac_config_status_args=
98651  test "$silent" = yes &&
98652    ac_config_status_args="$ac_config_status_args --quiet"
98653  exec 5>/dev/null
98654  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
98655  exec 5>>config.log
98656  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
98657  # would make configure fail if this is the last instruction.
98658  $ac_cs_success || as_fn_exit 1
98659fi
98660if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
98661  { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
98662printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
98663fi
98664
98665
98666