2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for PostgreSQL 12devel.
5 # Report bugs to <pgsql-bugs@postgresql.org>.
8 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
14 # Copyright (c) 1996-2018, PostgreSQL Global Development Group
15 ## -------------------- ##
16 ## M4sh Initialization. ##
17 ## -------------------- ##
19 # Be more Bourne compatible
20 DUALCASE=1; export DUALCASE # for MKS sh
21 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25 # is contrary to our usage. Disable this feature.
26 alias -g '${1+"$@"}'='"$@"'
29 case `(set -o) 2>/dev/null` in #(
41 # Printing a long string crashes Solaris 7 /usr/bin/printf.
42 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
45 # Prefer a ksh shell builtin over an external printf program on Solaris,
46 # but without wasting forks for bash or zsh.
47 if test -z "$BASH_VERSION$ZSH_VERSION" \
48 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo_n='print -rn --'
51 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
55 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57 as_echo_n='/usr/ucb/echo -n'
59 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
64 expr "X$arg" : "X\\(.*\\)$as_nl";
65 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
67 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
70 as_echo_n='sh -c $as_echo_n_body as_echo'
73 as_echo='sh -c $as_echo_body as_echo'
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
79 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
87 # We need space, tab and new line, in precisely that order. Quoting is
88 # there to prevent editors from complaining about space-tab.
89 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
90 # splitting by setting IFS to empty value.)
93 # Find who we are. Look in the path if we contain no directory separator.
96 *[\\/]* ) as_myself=$0 ;;
97 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
101 test -z "$as_dir" && as_dir=.
102 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
108 # We did not find ourselves, most probably we were run as `sh COMMAND'
109 # in which case we are not to be found in the path.
110 if test "x$as_myself" = x; then
113 if test ! -f "$as_myself"; then
114 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
118 # Unset variables that we do not need and which cause bugs (e.g. in
119 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
120 # suppresses any "Segmentation fault" message there. '((' could
121 # trigger a bug in pdksh 5.2.14.
122 for as_var in BASH_ENV ENV MAIL MAILPATH
123 do eval test x\${$as_var+set} = xset \
124 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
137 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
139 # Use a proper internal environment variable to ensure we don't fall
140 # into an infinite loop, continuously re-executing ourselves.
141 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
142 _as_can_reexec=no; export _as_can_reexec;
143 # We cannot yet assume a decent shell, so we have to provide a
144 # neutralization value for shells without unset; and this also
145 # works around shells that cannot unset nonexistent variables.
146 # Preserve -v and -x to the replacement shell.
149 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
151 *v*x* | *x*v* ) as_opts=-vx ;;
156 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
157 # Admittedly, this is quite paranoid, since all the known shells bail
158 # out after a failed `exec'.
159 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
162 # We don't want this to propagate to other subprocesses.
163 { _as_can_reexec=; unset _as_can_reexec;}
164 if test "x$CONFIG_SHELL" = x; then
165 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
168 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
169 # is contrary to our usage. Disable this feature.
170 alias -g '\${1+\"\$@\"}'='\"\$@\"'
173 case \`(set -o) 2>/dev/null\` in #(
181 as_required="as_fn_return () { (exit \$1); }
182 as_fn_success () { as_fn_return 0; }
183 as_fn_failure () { as_fn_return 1; }
184 as_fn_ret_success () { return 0; }
185 as_fn_ret_failure () { return 1; }
188 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
189 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
190 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
191 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
192 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
195 exitcode=1; echo positional parameters were not saved.
197 test x\$exitcode = x0 || exit 1
199 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
200 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
201 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
202 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
203 test \$(( 1 + 1 )) = 2 || exit 1"
204 if (eval "$as_required") 2>/dev/null; then :
209 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
214 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
217 test -z "$as_dir" && as_dir=.
221 for as_base in sh bash ksh sh5; do
222 # Try only shells that exist, to save several forks.
223 as_shell=$as_dir/$as_base
224 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
225 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
226 CONFIG_SHELL=$as_shell as_have_required=yes
227 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
235 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
236 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
237 CONFIG_SHELL=$SHELL as_have_required=yes
242 if test "x$CONFIG_SHELL" != x; then :
244 # We cannot yet assume a decent shell, so we have to provide a
245 # neutralization value for shells without unset; and this also
246 # works around shells that cannot unset nonexistent variables.
247 # Preserve -v and -x to the replacement shell.
250 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
252 *v*x* | *x*v* ) as_opts=-vx ;;
257 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
258 # Admittedly, this is quite paranoid, since all the known shells bail
259 # out after a failed `exec'.
260 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
264 if test x$as_have_required = xno; then :
265 $as_echo "$0: This script requires a shell more modern than all"
266 $as_echo "$0: the shells that I found on your system."
267 if test x${ZSH_VERSION+set} = xset ; then
268 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
269 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
271 $as_echo "$0: Please tell bug-autoconf@gnu.org and
272 $0: pgsql-bugs@postgresql.org about your system, including
273 $0: any error possibly output before this message. Then
274 $0: install a modern shell, or manually run the script
275 $0: under such a shell if you do have one."
281 SHELL=${CONFIG_SHELL-/bin/sh}
283 # Unset more variables known to interfere with behavior of common tools.
284 CLICOLOR_FORCE= GREP_OPTIONS=
285 unset CLICOLOR_FORCE GREP_OPTIONS
287 ## --------------------- ##
288 ## M4sh Shell Functions. ##
289 ## --------------------- ##
292 # Portably unset VAR.
295 { eval $1=; unset $1;}
299 # as_fn_set_status STATUS
300 # -----------------------
301 # Set $? to STATUS, without forking.
309 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
319 # Create "$as_dir" as a directory, including parents if necessary.
324 -*) as_dir=./$as_dir;;
326 test -d "$as_dir" || eval $as_mkdir_p || {
330 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
333 as_dirs="'$as_qdir' $as_dirs"
334 as_dir=`$as_dirname -- "$as_dir" ||
335 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
336 X"$as_dir" : 'X\(//\)[^/]' \| \
337 X"$as_dir" : 'X\(//\)$' \| \
338 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
339 $as_echo X"$as_dir" |
340 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
357 test -d "$as_dir" && break
359 test -z "$as_dirs" || eval "mkdir $as_dirs"
360 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
365 # as_fn_executable_p FILE
366 # -----------------------
367 # Test if FILE is an executable regular file.
368 as_fn_executable_p ()
370 test -f "$1" && test -x "$1"
371 } # as_fn_executable_p
372 # as_fn_append VAR VALUE
373 # ----------------------
374 # Append the text in VALUE to the end of the definition contained in VAR. Take
375 # advantage of any shell optimizations that allow amortized linear growth over
376 # repeated appends, instead of the typical quadratic growth present in naive
378 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
379 eval 'as_fn_append ()
392 # Perform arithmetic evaluation on the ARGs, and store the result in the
393 # global $as_val. Take advantage of shells that can avoid forks. The arguments
394 # must be portable across $(()) and expr.
395 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
403 as_val=`expr "$@" || test $? -eq 1`
408 # as_fn_error STATUS ERROR [LINENO LOG_FD]
409 # ----------------------------------------
410 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
411 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
412 # script with STATUS, using 1 if that was 0.
415 as_status=$1; test $as_status -eq 0 && as_status=1
417 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
418 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
420 $as_echo "$as_me: error: $2" >&2
421 as_fn_exit $as_status
424 if expr a : '\(a\)' >/dev/null 2>&1 &&
425 test "X`expr 00001 : '.*\(...\)'`" = X001; then
431 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
437 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
443 as_me=`$as_basename -- "$0" ||
444 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
445 X"$0" : 'X\(//\)$' \| \
446 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
448 sed '/^.*\/\([^/][^/]*\)\/*$/{
462 # Avoid depending upon Character Ranges.
463 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
464 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
465 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
466 as_cr_digits='0123456789'
467 as_cr_alnum=$as_cr_Letters$as_cr_digits
470 as_lineno_1=$LINENO as_lineno_1a=$LINENO
471 as_lineno_2=$LINENO as_lineno_2a=$LINENO
472 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
473 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
474 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
486 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
490 chmod +x "$as_me.lineno" ||
491 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
493 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
494 # already done that, so ensure we don't try to do so again and fall
495 # in an infinite loop. This has already happened in practice.
496 _as_can_reexec=no; export _as_can_reexec
497 # Don't try to exec as it changes $[0], causing all sort of problems
498 # (the dirname of $[0] is not the place where we might find the
499 # original and so on. Autoconf is especially sensitive to this).
501 # Exit status is that of the last command.
505 ECHO_C= ECHO_N= ECHO_T=
506 case `echo -n x` in #(((((
508 case `echo 'xy\c'` in
509 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
511 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
518 rm -f conf$$ conf$$.exe conf$$.file
519 if test -d conf$$.dir; then
520 rm -f conf$$.dir/conf$$.file
523 mkdir conf$$.dir 2>/dev/null
525 if (echo >conf$$.file) 2>/dev/null; then
526 if ln -s conf$$.file conf$$ 2>/dev/null; then
528 # ... but there are two gotchas:
529 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
530 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
531 # In both cases, we have to default to `cp -pR'.
532 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
534 elif ln conf$$.file conf$$ 2>/dev/null; then
542 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
543 rmdir conf$$.dir 2>/dev/null
545 if mkdir -p . 2>/dev/null; then
546 as_mkdir_p='mkdir -p "$as_dir"'
548 test -d ./-p && rmdir ./-p
553 as_executable_p=as_fn_executable_p
555 # Sed expression to map a string onto a valid CPP name.
556 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
558 # Sed expression to map a string onto a valid variable name.
559 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
562 test -n "$DJDIR" || exec 7<&0 </dev/null
566 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
567 # so uname gets run too.
568 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
573 ac_default_prefix=/usr/local
575 ac_config_libobj_dir=.
582 # Identity of this package.
583 PACKAGE_NAME='PostgreSQL'
584 PACKAGE_TARNAME='postgresql'
585 PACKAGE_VERSION='12devel'
586 PACKAGE_STRING='PostgreSQL 12devel'
587 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
590 ac_unique_file="src/backend/access/common/heaptuple.c"
591 ac_default_prefix=/usr/local/pgsql
592 # Factoring default headers for most tests.
593 ac_includes_default="\
595 #ifdef HAVE_SYS_TYPES_H
596 # include <sys/types.h>
598 #ifdef HAVE_SYS_STAT_H
599 # include <sys/stat.h>
605 # ifdef HAVE_STDLIB_H
610 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
615 #ifdef HAVE_STRINGS_H
616 # include <strings.h>
618 #ifdef HAVE_INTTYPES_H
619 # include <inttypes.h>
628 ac_subst_vars='LTLIBOBJS
662 python_additional_libs
805 program_transform_name
818 enable_option_checking
824 enable_integer_datetimes
859 with_libedit_preferred
871 ac_precious_vars='build_alias
894 # Initialize some variables set by options.
896 ac_init_version=false
897 ac_unrecognized_opts=
899 # The variables have the same names as the options, with
900 # dashes changed to underlines.
908 program_transform_name=s,x,x,
916 # Installation directory options.
917 # These are left unexpanded so users can "make install exec_prefix=/foo"
918 # and all the variables that are supposed to be based on exec_prefix
919 # by default will actually change.
920 # Use braces instead of parens because sh, perl, etc. also accept them.
921 # (The list follows the same order as the GNU Coding Standards.)
922 bindir='${exec_prefix}/bin'
923 sbindir='${exec_prefix}/sbin'
924 libexecdir='${exec_prefix}/libexec'
925 datarootdir='${prefix}/share'
926 datadir='${datarootdir}'
927 sysconfdir='${prefix}/etc'
928 sharedstatedir='${prefix}/com'
929 localstatedir='${prefix}/var'
930 includedir='${prefix}/include'
931 oldincludedir='/usr/include'
932 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
933 infodir='${datarootdir}/info'
938 libdir='${exec_prefix}/lib'
939 localedir='${datarootdir}/locale'
940 mandir='${datarootdir}/man'
946 # If the previous option needs an argument, assign it.
947 if test -n "$ac_prev"; then
948 eval $ac_prev=\$ac_option
954 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
959 # Accept the important Cygnus configure options, so we can diagnose typos.
961 case $ac_dashdash$ac_option in
965 -bindir | --bindir | --bindi | --bind | --bin | --bi)
967 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
970 -build | --build | --buil | --bui | --bu)
971 ac_prev=build_alias ;;
972 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
973 build_alias=$ac_optarg ;;
975 -cache-file | --cache-file | --cache-fil | --cache-fi \
976 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
977 ac_prev=cache_file ;;
978 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
979 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
980 cache_file=$ac_optarg ;;
983 cache_file=config.cache ;;
985 -datadir | --datadir | --datadi | --datad)
987 -datadir=* | --datadir=* | --datadi=* | --datad=*)
988 datadir=$ac_optarg ;;
990 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
991 | --dataroo | --dataro | --datar)
992 ac_prev=datarootdir ;;
993 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
994 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
995 datarootdir=$ac_optarg ;;
997 -disable-* | --disable-*)
998 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
999 # Reject names that are not valid shell variable names.
1000 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1001 as_fn_error $? "invalid feature name: $ac_useropt"
1002 ac_useropt_orig=$ac_useropt
1003 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1004 case $ac_user_opts in
1006 "enable_$ac_useropt"
1008 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1009 ac_unrecognized_sep=', ';;
1011 eval enable_$ac_useropt=no ;;
1013 -docdir | --docdir | --docdi | --doc | --do)
1015 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1016 docdir=$ac_optarg ;;
1018 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1020 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1021 dvidir=$ac_optarg ;;
1023 -enable-* | --enable-*)
1024 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1025 # Reject names that are not valid shell variable names.
1026 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1027 as_fn_error $? "invalid feature name: $ac_useropt"
1028 ac_useropt_orig=$ac_useropt
1029 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1030 case $ac_user_opts in
1032 "enable_$ac_useropt"
1034 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1035 ac_unrecognized_sep=', ';;
1037 eval enable_$ac_useropt=\$ac_optarg ;;
1039 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1040 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1041 | --exec | --exe | --ex)
1042 ac_prev=exec_prefix ;;
1043 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1044 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1045 | --exec=* | --exe=* | --ex=*)
1046 exec_prefix=$ac_optarg ;;
1048 -gas | --gas | --ga | --g)
1049 # Obsolete; use --with-gas.
1052 -help | --help | --hel | --he | -h)
1053 ac_init_help=long ;;
1054 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1055 ac_init_help=recursive ;;
1056 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1057 ac_init_help=short ;;
1059 -host | --host | --hos | --ho)
1060 ac_prev=host_alias ;;
1061 -host=* | --host=* | --hos=* | --ho=*)
1062 host_alias=$ac_optarg ;;
1064 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1066 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1068 htmldir=$ac_optarg ;;
1070 -includedir | --includedir | --includedi | --included | --include \
1071 | --includ | --inclu | --incl | --inc)
1072 ac_prev=includedir ;;
1073 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1074 | --includ=* | --inclu=* | --incl=* | --inc=*)
1075 includedir=$ac_optarg ;;
1077 -infodir | --infodir | --infodi | --infod | --info | --inf)
1079 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1080 infodir=$ac_optarg ;;
1082 -libdir | --libdir | --libdi | --libd)
1084 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1085 libdir=$ac_optarg ;;
1087 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1088 | --libexe | --libex | --libe)
1089 ac_prev=libexecdir ;;
1090 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1091 | --libexe=* | --libex=* | --libe=*)
1092 libexecdir=$ac_optarg ;;
1094 -localedir | --localedir | --localedi | --localed | --locale)
1095 ac_prev=localedir ;;
1096 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1097 localedir=$ac_optarg ;;
1099 -localstatedir | --localstatedir | --localstatedi | --localstated \
1100 | --localstate | --localstat | --localsta | --localst | --locals)
1101 ac_prev=localstatedir ;;
1102 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1103 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1104 localstatedir=$ac_optarg ;;
1106 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1108 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1109 mandir=$ac_optarg ;;
1111 -nfp | --nfp | --nf)
1112 # Obsolete; use --without-fp.
1115 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1116 | --no-cr | --no-c | -n)
1119 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1120 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1123 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1124 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1125 | --oldin | --oldi | --old | --ol | --o)
1126 ac_prev=oldincludedir ;;
1127 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1128 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1129 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1130 oldincludedir=$ac_optarg ;;
1132 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1134 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1135 prefix=$ac_optarg ;;
1137 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1138 | --program-pre | --program-pr | --program-p)
1139 ac_prev=program_prefix ;;
1140 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1141 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1142 program_prefix=$ac_optarg ;;
1144 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1145 | --program-suf | --program-su | --program-s)
1146 ac_prev=program_suffix ;;
1147 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1148 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1149 program_suffix=$ac_optarg ;;
1151 -program-transform-name | --program-transform-name \
1152 | --program-transform-nam | --program-transform-na \
1153 | --program-transform-n | --program-transform- \
1154 | --program-transform | --program-transfor \
1155 | --program-transfo | --program-transf \
1156 | --program-trans | --program-tran \
1157 | --progr-tra | --program-tr | --program-t)
1158 ac_prev=program_transform_name ;;
1159 -program-transform-name=* | --program-transform-name=* \
1160 | --program-transform-nam=* | --program-transform-na=* \
1161 | --program-transform-n=* | --program-transform-=* \
1162 | --program-transform=* | --program-transfor=* \
1163 | --program-transfo=* | --program-transf=* \
1164 | --program-trans=* | --program-tran=* \
1165 | --progr-tra=* | --program-tr=* | --program-t=*)
1166 program_transform_name=$ac_optarg ;;
1168 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1170 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1171 pdfdir=$ac_optarg ;;
1173 -psdir | --psdir | --psdi | --psd | --ps)
1175 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1178 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1179 | -silent | --silent | --silen | --sile | --sil)
1182 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1184 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1186 sbindir=$ac_optarg ;;
1188 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1189 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1190 | --sharedst | --shareds | --shared | --share | --shar \
1192 ac_prev=sharedstatedir ;;
1193 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1194 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1195 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1197 sharedstatedir=$ac_optarg ;;
1199 -site | --site | --sit)
1201 -site=* | --site=* | --sit=*)
1204 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1206 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1207 srcdir=$ac_optarg ;;
1209 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1210 | --syscon | --sysco | --sysc | --sys | --sy)
1211 ac_prev=sysconfdir ;;
1212 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1213 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1214 sysconfdir=$ac_optarg ;;
1216 -target | --target | --targe | --targ | --tar | --ta | --t)
1217 ac_prev=target_alias ;;
1218 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1219 target_alias=$ac_optarg ;;
1221 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1224 -version | --version | --versio | --versi | --vers | -V)
1225 ac_init_version=: ;;
1228 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1229 # Reject names that are not valid shell variable names.
1230 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1231 as_fn_error $? "invalid package name: $ac_useropt"
1232 ac_useropt_orig=$ac_useropt
1233 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1234 case $ac_user_opts in
1238 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1239 ac_unrecognized_sep=', ';;
1241 eval with_$ac_useropt=\$ac_optarg ;;
1243 -without-* | --without-*)
1244 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1245 # Reject names that are not valid shell variable names.
1246 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1247 as_fn_error $? "invalid package name: $ac_useropt"
1248 ac_useropt_orig=$ac_useropt
1249 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1250 case $ac_user_opts in
1254 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1255 ac_unrecognized_sep=', ';;
1257 eval with_$ac_useropt=no ;;
1260 # Obsolete; use --with-x.
1263 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1264 | --x-incl | --x-inc | --x-in | --x-i)
1265 ac_prev=x_includes ;;
1266 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1267 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1268 x_includes=$ac_optarg ;;
1270 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1271 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1272 ac_prev=x_libraries ;;
1273 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1274 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1275 x_libraries=$ac_optarg ;;
1277 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1278 Try \`$0 --help' for more information"
1282 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1283 # Reject names that are not valid shell variable names.
1284 case $ac_envvar in #(
1285 '' | [0-9]* | *[!_$as_cr_alnum]* )
1286 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1288 eval $ac_envvar=\$ac_optarg
1289 export $ac_envvar ;;
1292 # FIXME: should be removed in autoconf 3.0.
1293 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1294 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1295 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1296 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1302 if test -n "$ac_prev"; then
1303 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1304 as_fn_error $? "missing argument to $ac_option"
1307 if test -n "$ac_unrecognized_opts"; then
1308 case $enable_option_checking in
1310 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1311 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1315 # Check all directory arguments for consistency.
1316 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1317 datadir sysconfdir sharedstatedir localstatedir includedir \
1318 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1319 libdir localedir mandir
1321 eval ac_val=\$$ac_var
1322 # Remove trailing slashes.
1325 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1326 eval $ac_var=\$ac_val;;
1328 # Be sure to have absolute directory names.
1330 [\\/$]* | ?:[\\/]* ) continue;;
1331 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1333 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1336 # There might be people who depend on the old broken behavior: `$host'
1337 # used to hold the argument of --host etc.
1338 # FIXME: To remove some day.
1341 target=$target_alias
1343 # FIXME: To remove some day.
1344 if test "x$host_alias" != x; then
1345 if test "x$build_alias" = x; then
1346 cross_compiling=maybe
1347 elif test "x$build_alias" != "x$host_alias"; then
1353 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1355 test "$silent" = yes && exec 6>/dev/null
1358 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1359 ac_ls_di=`ls -di .` &&
1360 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1361 as_fn_error $? "working directory cannot be determined"
1362 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1363 as_fn_error $? "pwd does not report name of working directory"
1366 # Find the source files, if location was not specified.
1367 if test -z "$srcdir"; then
1368 ac_srcdir_defaulted=yes
1369 # Try the directory containing this script, then the parent directory.
1370 ac_confdir=`$as_dirname -- "$as_myself" ||
1371 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1372 X"$as_myself" : 'X\(//\)[^/]' \| \
1373 X"$as_myself" : 'X\(//\)$' \| \
1374 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1375 $as_echo X"$as_myself" |
1376 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1394 if test ! -r "$srcdir/$ac_unique_file"; then
1398 ac_srcdir_defaulted=no
1400 if test ! -r "$srcdir/$ac_unique_file"; then
1401 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1402 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1404 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1406 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1408 # When building in place, set srcdir=.
1409 if test "$ac_abs_confdir" = "$ac_pwd"; then
1412 # Remove unnecessary trailing slashes from srcdir.
1413 # Double slashes in file names in object file debugging info
1414 # mess up M-x gdb in Emacs.
1416 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1418 for ac_var in $ac_precious_vars; do
1419 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1420 eval ac_env_${ac_var}_value=\$${ac_var}
1421 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1422 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1426 # Report the --help message.
1428 if test "$ac_init_help" = "long"; then
1429 # Omit some internal or obsolete options to make the list less imposing.
1430 # This message is too long to be a string in the A/UX 3.1 sh.
1432 \`configure' configures PostgreSQL 12devel to adapt to many kinds of systems.
1434 Usage: $0 [OPTION]... [VAR=VALUE]...
1436 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1437 VAR=VALUE. See below for descriptions of some of the useful variables.
1439 Defaults for the options are specified in brackets.
1442 -h, --help display this help and exit
1443 --help=short display options specific to this package
1444 --help=recursive display the short help of all the included packages
1445 -V, --version display version information and exit
1446 -q, --quiet, --silent do not print \`checking ...' messages
1447 --cache-file=FILE cache test results in FILE [disabled]
1448 -C, --config-cache alias for \`--cache-file=config.cache'
1449 -n, --no-create do not create output files
1450 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1452 Installation directories:
1453 --prefix=PREFIX install architecture-independent files in PREFIX
1454 [$ac_default_prefix]
1455 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1458 By default, \`make install' will install all the files in
1459 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1460 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1461 for instance \`--prefix=\$HOME'.
1463 For better control, use the options below.
1465 Fine tuning of the installation directories:
1466 --bindir=DIR user executables [EPREFIX/bin]
1467 --sbindir=DIR system admin executables [EPREFIX/sbin]
1468 --libexecdir=DIR program executables [EPREFIX/libexec]
1469 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1470 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1471 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1472 --libdir=DIR object code libraries [EPREFIX/lib]
1473 --includedir=DIR C header files [PREFIX/include]
1474 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1475 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1476 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1477 --infodir=DIR info documentation [DATAROOTDIR/info]
1478 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1479 --mandir=DIR man documentation [DATAROOTDIR/man]
1480 --docdir=DIR documentation root [DATAROOTDIR/doc/postgresql]
1481 --htmldir=DIR html documentation [DOCDIR]
1482 --dvidir=DIR dvi documentation [DOCDIR]
1483 --pdfdir=DIR pdf documentation [DOCDIR]
1484 --psdir=DIR ps documentation [DOCDIR]
1490 --build=BUILD configure for building on BUILD [guessed]
1491 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1495 if test -n "$ac_init_help"; then
1496 case $ac_init_help in
1497 short | recursive ) echo "Configuration of PostgreSQL 12devel:";;
1502 --disable-option-checking ignore unrecognized --enable/--with options
1503 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1504 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1505 --disable-integer-datetimes
1506 obsolete option, no longer supported
1507 --enable-nls[=LANGUAGES]
1508 enable Native Language Support
1509 --disable-rpath do not embed shared library search path in
1511 --disable-spinlocks do not use spinlocks
1512 --disable-atomics do not use atomic operations
1513 --disable-strong-random do not use a strong random number source
1514 --enable-debug build with debugging symbols (-g)
1515 --enable-profiling build with profiling enabled
1516 --enable-coverage build with coverage testing instrumentation
1517 --enable-dtrace build with DTrace support
1518 --enable-tap-tests enable TAP tests (requires Perl and IPC::Run)
1519 --enable-depend turn on automatic dependency tracking
1520 --enable-cassert enable assertion checks (for debugging)
1521 --disable-thread-safety disable thread-safety in client libraries
1522 --disable-largefile omit support for large files
1523 --disable-float4-byval disable float4 passed by value
1524 --disable-float8-byval disable float8 passed by value
1527 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1528 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1529 --with-extra-version=STRING
1530 append STRING to version
1531 --with-template=NAME override operating system template
1532 --with-includes=DIRS look for additional header files in DIRS
1533 --with-libraries=DIRS look for additional libraries in DIRS
1534 --with-libs=DIRS alternative spelling of --with-libraries
1535 --with-pgport=PORTNUM set default port number [5432]
1536 --with-blocksize=BLOCKSIZE
1537 set table block size in kB [8]
1538 --with-segsize=SEGSIZE set table segment size in GB [1]
1539 --with-wal-blocksize=BLOCKSIZE
1540 set WAL block size in kB [8]
1541 --with-CC=CMD set compiler (deprecated)
1542 --with-llvm build with LLVM based JIT support
1543 --with-icu build with ICU support
1544 --with-tcl build Tcl modules (PL/Tcl)
1545 --with-tclconfig=DIR tclConfig.sh is in DIR
1546 --with-perl build Perl modules (PL/Perl)
1547 --with-python build Python modules (PL/Python)
1548 --with-gssapi build with GSSAPI support
1549 --with-krb-srvnam=NAME default service principal name in Kerberos (GSSAPI)
1551 --with-pam build with PAM support
1552 --with-bsd-auth build with BSD Authentication support
1553 --with-ldap build with LDAP support
1554 --with-bonjour build with Bonjour support
1555 --with-openssl build with OpenSSL support
1556 --with-selinux build with SELinux support
1557 --with-systemd build with systemd support
1558 --without-readline do not use GNU Readline nor BSD Libedit for editing
1559 --with-libedit-preferred
1560 prefer BSD Libedit over GNU Readline
1561 --with-uuid=LIB build contrib/uuid-ossp using LIB (bsd,e2fs,ossp)
1562 --with-ossp-uuid obsolete spelling of --with-uuid=ossp
1563 --with-libxml build with XML support
1564 --with-libxslt use XSLT support when building contrib/xml2
1565 --with-system-tzdata=DIR
1566 use system time zone data in DIR
1567 --without-zlib do not use Zlib
1568 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1570 Some influential environment variables:
1571 CC C compiler command
1572 CFLAGS C compiler flags
1573 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1574 nonstandard directory <lib dir>
1575 LIBS libraries to pass to the linker, e.g. -l<library>
1576 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1577 you have headers in a nonstandard directory <include dir>
1578 CXX C++ compiler command
1579 CXXFLAGS C++ compiler flags
1580 LLVM_CONFIG path to llvm-config command
1581 CLANG path to clang compiler to generate bitcode
1583 PKG_CONFIG path to pkg-config utility
1585 directories to add to pkg-config's search path
1587 path overriding pkg-config's built-in search path
1588 ICU_CFLAGS C compiler flags for ICU, overriding pkg-config
1589 ICU_LIBS linker flags for ICU, overriding pkg-config
1590 LDFLAGS_EX extra linker flags for linking executables only
1591 LDFLAGS_SL extra linker flags for linking shared libraries only
1593 Use these variables to override the choices made by `configure' or to help
1594 it to find libraries and programs with nonstandard names/locations.
1596 Report bugs to <pgsql-bugs@postgresql.org>.
1601 if test "$ac_init_help" = "recursive"; then
1602 # If there are subdirs, report their specific --help.
1603 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1604 test -d "$ac_dir" ||
1605 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1610 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1612 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1613 # A ".." for each directory in $ac_dir_suffix.
1614 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1615 case $ac_top_builddir_sub in
1616 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1617 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1620 ac_abs_top_builddir=$ac_pwd
1621 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1622 # for backward compatibility:
1623 ac_top_builddir=$ac_top_build_prefix
1626 .) # We are building in place.
1628 ac_top_srcdir=$ac_top_builddir_sub
1629 ac_abs_top_srcdir=$ac_pwd ;;
1630 [\\/]* | ?:[\\/]* ) # Absolute name.
1631 ac_srcdir=$srcdir$ac_dir_suffix;
1632 ac_top_srcdir=$srcdir
1633 ac_abs_top_srcdir=$srcdir ;;
1635 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1636 ac_top_srcdir=$ac_top_build_prefix$srcdir
1637 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1639 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1641 cd "$ac_dir" || { ac_status=$?; continue; }
1642 # Check for guested configure.
1643 if test -f "$ac_srcdir/configure.gnu"; then
1645 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1646 elif test -f "$ac_srcdir/configure"; then
1648 $SHELL "$ac_srcdir/configure" --help=recursive
1650 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1652 cd "$ac_pwd" || { ac_status=$?; break; }
1656 test -n "$ac_init_help" && exit $ac_status
1657 if $ac_init_version; then
1659 PostgreSQL configure 12devel
1660 generated by GNU Autoconf 2.69
1662 Copyright (C) 2012 Free Software Foundation, Inc.
1663 This configure script is free software; the Free Software Foundation
1664 gives unlimited permission to copy, distribute and modify it.
1666 Copyright (c) 1996-2018, PostgreSQL Global Development Group
1671 ## ------------------------ ##
1672 ## Autoconf initialization. ##
1673 ## ------------------------ ##
1675 # ac_fn_c_try_compile LINENO
1676 # --------------------------
1677 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1678 ac_fn_c_try_compile ()
1680 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1681 rm -f conftest.$ac_objext
1682 if { { ac_try="$ac_compile"
1684 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1685 *) ac_try_echo=$ac_try;;
1687 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1688 $as_echo "$ac_try_echo"; } >&5
1689 (eval "$ac_compile") 2>conftest.err
1691 if test -s conftest.err; then
1692 grep -v '^ *+' conftest.err >conftest.er1
1693 cat conftest.er1 >&5
1694 mv -f conftest.er1 conftest.err
1696 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1697 test $ac_status = 0; } && {
1698 test -z "$ac_c_werror_flag" ||
1699 test ! -s conftest.err
1700 } && test -s conftest.$ac_objext; then :
1703 $as_echo "$as_me: failed program was:" >&5
1704 sed 's/^/| /' conftest.$ac_ext >&5
1708 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1709 as_fn_set_status $ac_retval
1711 } # ac_fn_c_try_compile
1713 # ac_fn_cxx_try_compile LINENO
1714 # ----------------------------
1715 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1716 ac_fn_cxx_try_compile ()
1718 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1719 rm -f conftest.$ac_objext
1720 if { { ac_try="$ac_compile"
1722 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1723 *) ac_try_echo=$ac_try;;
1725 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1726 $as_echo "$ac_try_echo"; } >&5
1727 (eval "$ac_compile") 2>conftest.err
1729 if test -s conftest.err; then
1730 grep -v '^ *+' conftest.err >conftest.er1
1731 cat conftest.er1 >&5
1732 mv -f conftest.er1 conftest.err
1734 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1735 test $ac_status = 0; } && {
1736 test -z "$ac_cxx_werror_flag" ||
1737 test ! -s conftest.err
1738 } && test -s conftest.$ac_objext; then :
1741 $as_echo "$as_me: failed program was:" >&5
1742 sed 's/^/| /' conftest.$ac_ext >&5
1746 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1747 as_fn_set_status $ac_retval
1749 } # ac_fn_cxx_try_compile
1751 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1752 # ---------------------------------------------
1753 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1755 ac_fn_c_check_decl ()
1757 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1758 as_decl_name=`echo $2|sed 's/ *(.*//'`
1759 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
1760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
1761 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
1762 if eval \${$3+:} false; then :
1763 $as_echo_n "(cached) " >&6
1765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1766 /* end confdefs.h. */
1771 #ifndef $as_decl_name
1773 (void) $as_decl_use;
1775 (void) $as_decl_name;
1783 if ac_fn_c_try_compile "$LINENO"; then :
1788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1792 $as_echo "$ac_res" >&6; }
1793 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1795 } # ac_fn_c_check_decl
1797 # ac_fn_c_try_link LINENO
1798 # -----------------------
1799 # Try to link conftest.$ac_ext, and return whether this succeeded.
1802 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1803 rm -f conftest.$ac_objext conftest$ac_exeext
1804 if { { ac_try="$ac_link"
1806 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1807 *) ac_try_echo=$ac_try;;
1809 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1810 $as_echo "$ac_try_echo"; } >&5
1811 (eval "$ac_link") 2>conftest.err
1813 if test -s conftest.err; then
1814 grep -v '^ *+' conftest.err >conftest.er1
1815 cat conftest.er1 >&5
1816 mv -f conftest.er1 conftest.err
1818 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1819 test $ac_status = 0; } && {
1820 test -z "$ac_c_werror_flag" ||
1821 test ! -s conftest.err
1822 } && test -s conftest$ac_exeext && {
1823 test "$cross_compiling" = yes ||
1824 test -x conftest$ac_exeext
1828 $as_echo "$as_me: failed program was:" >&5
1829 sed 's/^/| /' conftest.$ac_ext >&5
1833 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1834 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1835 # interfere with the next link command; also delete a directory that is
1836 # left behind by Apple's compiler. We do this before executing the actions.
1837 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1838 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1839 as_fn_set_status $ac_retval
1841 } # ac_fn_c_try_link
1843 # ac_fn_c_try_cpp LINENO
1844 # ----------------------
1845 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1848 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1849 if { { ac_try="$ac_cpp conftest.$ac_ext"
1851 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1852 *) ac_try_echo=$ac_try;;
1854 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1855 $as_echo "$ac_try_echo"; } >&5
1856 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1858 if test -s conftest.err; then
1859 grep -v '^ *+' conftest.err >conftest.er1
1860 cat conftest.er1 >&5
1861 mv -f conftest.er1 conftest.err
1863 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1864 test $ac_status = 0; } > conftest.i && {
1865 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1866 test ! -s conftest.err
1870 $as_echo "$as_me: failed program was:" >&5
1871 sed 's/^/| /' conftest.$ac_ext >&5
1875 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1876 as_fn_set_status $ac_retval
1880 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1881 # -------------------------------------------------------
1882 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1883 # the include files in INCLUDES and setting the cache variable VAR
1885 ac_fn_c_check_header_mongrel ()
1887 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1888 if eval \${$3+:} false; then :
1889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1890 $as_echo_n "checking for $2... " >&6; }
1891 if eval \${$3+:} false; then :
1892 $as_echo_n "(cached) " >&6
1895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1896 $as_echo "$ac_res" >&6; }
1898 # Is the header compilable?
1899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1900 $as_echo_n "checking $2 usability... " >&6; }
1901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1902 /* end confdefs.h. */
1906 if ac_fn_c_try_compile "$LINENO"; then :
1907 ac_header_compiler=yes
1909 ac_header_compiler=no
1911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1913 $as_echo "$ac_header_compiler" >&6; }
1915 # Is the header present?
1916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1917 $as_echo_n "checking $2 presence... " >&6; }
1918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1919 /* end confdefs.h. */
1922 if ac_fn_c_try_cpp "$LINENO"; then :
1923 ac_header_preproc=yes
1925 ac_header_preproc=no
1927 rm -f conftest.err conftest.i conftest.$ac_ext
1928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1929 $as_echo "$ac_header_preproc" >&6; }
1931 # So? What about this header?
1932 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1934 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1935 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1936 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1937 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1940 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1941 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1942 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1943 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1944 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1945 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1946 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1947 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1948 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1949 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1950 ( $as_echo "## ---------------------------------------- ##
1951 ## Report this to pgsql-bugs@postgresql.org ##
1952 ## ---------------------------------------- ##"
1953 ) | sed "s/^/$as_me: WARNING: /" >&2
1956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1957 $as_echo_n "checking for $2... " >&6; }
1958 if eval \${$3+:} false; then :
1959 $as_echo_n "(cached) " >&6
1961 eval "$3=\$ac_header_compiler"
1964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1965 $as_echo "$ac_res" >&6; }
1967 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1969 } # ac_fn_c_check_header_mongrel
1971 # ac_fn_c_try_run LINENO
1972 # ----------------------
1973 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1974 # that executables *can* be run.
1977 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1978 if { { ac_try="$ac_link"
1980 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1981 *) ac_try_echo=$ac_try;;
1983 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1984 $as_echo "$ac_try_echo"; } >&5
1985 (eval "$ac_link") 2>&5
1987 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1988 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1989 { { case "(($ac_try" in
1990 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1991 *) ac_try_echo=$ac_try;;
1993 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1994 $as_echo "$ac_try_echo"; } >&5
1995 (eval "$ac_try") 2>&5
1997 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1998 test $ac_status = 0; }; }; then :
2001 $as_echo "$as_me: program exited with status $ac_status" >&5
2002 $as_echo "$as_me: failed program was:" >&5
2003 sed 's/^/| /' conftest.$ac_ext >&5
2005 ac_retval=$ac_status
2007 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2008 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2009 as_fn_set_status $ac_retval
2013 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2014 # -------------------------------------------------------
2015 # Tests whether HEADER exists and can be compiled using the include files in
2016 # INCLUDES, setting the cache variable VAR accordingly.
2017 ac_fn_c_check_header_compile ()
2019 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2021 $as_echo_n "checking for $2... " >&6; }
2022 if eval \${$3+:} false; then :
2023 $as_echo_n "(cached) " >&6
2025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2026 /* end confdefs.h. */
2030 if ac_fn_c_try_compile "$LINENO"; then :
2035 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2039 $as_echo "$ac_res" >&6; }
2040 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2042 } # ac_fn_c_check_header_compile
2044 # ac_fn_c_check_func LINENO FUNC VAR
2045 # ----------------------------------
2046 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2047 ac_fn_c_check_func ()
2049 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2051 $as_echo_n "checking for $2... " >&6; }
2052 if eval \${$3+:} false; then :
2053 $as_echo_n "(cached) " >&6
2055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2056 /* end confdefs.h. */
2057 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2058 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2059 #define $2 innocuous_$2
2061 /* System header to define __stub macros and hopefully few prototypes,
2062 which can conflict with char $2 (); below.
2063 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2064 <limits.h> exists even on freestanding compilers. */
2067 # include <limits.h>
2069 # include <assert.h>
2074 /* Override any GCC internal prototype to avoid an error.
2075 Use char because int might match the return type of a GCC
2076 builtin and then its argument prototype would still apply. */
2081 /* The GNU C library defines this for functions which it implements
2082 to always fail with ENOSYS. Some functions are actually named
2083 something starting with __ and the normal name is an alias. */
2084 #if defined __stub_$2 || defined __stub___$2
2096 if ac_fn_c_try_link "$LINENO"; then :
2101 rm -f core conftest.err conftest.$ac_objext \
2102 conftest$ac_exeext conftest.$ac_ext
2105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2106 $as_echo "$ac_res" >&6; }
2107 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2109 } # ac_fn_c_check_func
2111 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2112 # -------------------------------------------
2113 # Tests whether TYPE exists after having included INCLUDES, setting cache
2114 # variable VAR accordingly.
2115 ac_fn_c_check_type ()
2117 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2119 $as_echo_n "checking for $2... " >&6; }
2120 if eval \${$3+:} false; then :
2121 $as_echo_n "(cached) " >&6
2124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2125 /* end confdefs.h. */
2136 if ac_fn_c_try_compile "$LINENO"; then :
2137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2138 /* end confdefs.h. */
2149 if ac_fn_c_try_compile "$LINENO"; then :
2154 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2156 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2160 $as_echo "$ac_res" >&6; }
2161 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2163 } # ac_fn_c_check_type
2165 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2166 # ----------------------------------------------------
2167 # Tries to find if the field MEMBER exists in type AGGR, after including
2168 # INCLUDES, setting cache variable VAR accordingly.
2169 ac_fn_c_check_member ()
2171 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2173 $as_echo_n "checking for $2.$3... " >&6; }
2174 if eval \${$4+:} false; then :
2175 $as_echo_n "(cached) " >&6
2177 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2178 /* end confdefs.h. */
2190 if ac_fn_c_try_compile "$LINENO"; then :
2193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2194 /* end confdefs.h. */
2200 if (sizeof ac_aggr.$3)
2206 if ac_fn_c_try_compile "$LINENO"; then :
2211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2213 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2217 $as_echo "$ac_res" >&6; }
2218 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2220 } # ac_fn_c_check_member
2222 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2223 # --------------------------------------------
2224 # Tries to find the compile-time value of EXPR in a program that includes
2225 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2227 ac_fn_c_compute_int ()
2229 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2230 if test "$cross_compiling" = yes; then
2231 # Depending upon the size, compute the lo and hi bounds.
2232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2233 /* end confdefs.h. */
2238 static int test_array [1 - 2 * !(($2) >= 0)];
2240 return test_array [0];
2246 if ac_fn_c_try_compile "$LINENO"; then :
2249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2250 /* end confdefs.h. */
2255 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2257 return test_array [0];
2263 if ac_fn_c_try_compile "$LINENO"; then :
2264 ac_hi=$ac_mid; break
2266 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2267 if test $ac_lo -le $ac_mid; then
2271 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2273 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2277 /* end confdefs.h. */
2282 static int test_array [1 - 2 * !(($2) < 0)];
2284 return test_array [0];
2290 if ac_fn_c_try_compile "$LINENO"; then :
2293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2294 /* end confdefs.h. */
2299 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2301 return test_array [0];
2307 if ac_fn_c_try_compile "$LINENO"; then :
2308 ac_lo=$ac_mid; break
2310 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2311 if test $ac_mid -le $ac_hi; then
2315 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2317 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2322 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2324 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2325 # Binary search between lo and hi bounds.
2326 while test "x$ac_lo" != "x$ac_hi"; do
2327 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2329 /* end confdefs.h. */
2334 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2336 return test_array [0];
2342 if ac_fn_c_try_compile "$LINENO"; then :
2345 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2350 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2355 /* end confdefs.h. */
2357 static long int longval () { return $2; }
2358 static unsigned long int ulongval () { return $2; }
2365 FILE *f = fopen ("conftest.val", "w");
2370 long int i = longval ();
2373 fprintf (f, "%ld", i);
2377 unsigned long int i = ulongval ();
2380 fprintf (f, "%lu", i);
2382 /* Do not output a trailing newline, as this causes \r\n confusion
2383 on some platforms. */
2384 return ferror (f) || fclose (f) != 0;
2390 if ac_fn_c_try_run "$LINENO"; then :
2391 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2395 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2396 conftest.$ac_objext conftest.beam conftest.$ac_ext
2400 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2401 as_fn_set_status $ac_retval
2403 } # ac_fn_c_compute_int
2404 cat >config.log <<_ACEOF
2405 This file contains any messages produced by compilers while
2406 running configure, to aid debugging if configure makes a mistake.
2408 It was created by PostgreSQL $as_me 12devel, which was
2409 generated by GNU Autoconf 2.69. Invocation command line was
2421 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2422 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2423 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2424 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2425 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2427 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2428 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2430 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2431 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2432 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2433 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2434 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2435 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2436 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2444 test -z "$as_dir" && as_dir=.
2445 $as_echo "PATH: $as_dir"
2461 # Keep a trace of the command line.
2462 # Strip out --no-create and --no-recursion so they do not pile up.
2463 # Strip out --silent because we don't want to record it for future runs.
2464 # Also quote any args containing shell meta-characters.
2465 # Make two passes to allow for proper duplicate-argument suppression.
2469 ac_must_keep_next=false
2475 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2476 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2477 | -silent | --silent | --silen | --sile | --sil)
2480 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2483 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2485 as_fn_append ac_configure_args1 " '$ac_arg'"
2486 if test $ac_must_keep_next = true; then
2487 ac_must_keep_next=false # Got value, back to normal.
2490 *=* | --config-cache | -C | -disable-* | --disable-* \
2491 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2492 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2493 | -with-* | --with-* | -without-* | --without-* | --x)
2494 case "$ac_configure_args0 " in
2495 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2498 -* ) ac_must_keep_next=true ;;
2501 as_fn_append ac_configure_args " '$ac_arg'"
2506 { ac_configure_args0=; unset ac_configure_args0;}
2507 { ac_configure_args1=; unset ac_configure_args1;}
2509 # When interrupted or exit'd, cleanup temporary files, and complete
2510 # config.log. We remove comments because anyway the quotes in there
2511 # would cause problems or look ugly.
2512 # WARNING: Use '\'' to represent an apostrophe within the trap.
2513 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2514 trap 'exit_status=$?
2515 # Save into config.log some information that might help in debugging.
2519 $as_echo "## ---------------- ##
2520 ## Cache variables. ##
2521 ## ---------------- ##"
2523 # The following way of writing the cache mishandles newlines in values,
2525 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2526 eval ac_val=\$$ac_var
2530 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2531 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2534 _ | IFS | as_nl) ;; #(
2535 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2536 *) { eval $ac_var=; unset $ac_var;} ;;
2541 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2542 *${as_nl}ac_space=\ *)
2544 "s/'\''/'\''\\\\'\'''\''/g;
2545 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2548 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2555 $as_echo "## ----------------- ##
2556 ## Output variables. ##
2557 ## ----------------- ##"
2559 for ac_var in $ac_subst_vars
2561 eval ac_val=\$$ac_var
2563 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2565 $as_echo "$ac_var='\''$ac_val'\''"
2569 if test -n "$ac_subst_files"; then
2570 $as_echo "## ------------------- ##
2571 ## File substitutions. ##
2572 ## ------------------- ##"
2574 for ac_var in $ac_subst_files
2576 eval ac_val=\$$ac_var
2578 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2580 $as_echo "$ac_var='\''$ac_val'\''"
2585 if test -s confdefs.h; then
2586 $as_echo "## ----------- ##
2593 test "$ac_signal" != 0 &&
2594 $as_echo "$as_me: caught signal $ac_signal"
2595 $as_echo "$as_me: exit $exit_status"
2597 rm -f core *.core core.conftest.* &&
2598 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2601 for ac_signal in 1 2 13 15; do
2602 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2606 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2607 rm -f -r conftest* confdefs.h
2609 $as_echo "/* confdefs.h */" > confdefs.h
2611 # Predefined preprocessor variables.
2613 cat >>confdefs.h <<_ACEOF
2614 #define PACKAGE_NAME "$PACKAGE_NAME"
2617 cat >>confdefs.h <<_ACEOF
2618 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2621 cat >>confdefs.h <<_ACEOF
2622 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2625 cat >>confdefs.h <<_ACEOF
2626 #define PACKAGE_STRING "$PACKAGE_STRING"
2629 cat >>confdefs.h <<_ACEOF
2630 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2633 cat >>confdefs.h <<_ACEOF
2634 #define PACKAGE_URL "$PACKAGE_URL"
2638 # Let the site file select an alternate cache file if it wants to.
2639 # Prefer an explicitly selected file to automatically selected ones.
2642 if test -n "$CONFIG_SITE"; then
2643 # We do not want a PATH search for config.site.
2644 case $CONFIG_SITE in #((
2645 -*) ac_site_file1=./$CONFIG_SITE;;
2646 */*) ac_site_file1=$CONFIG_SITE;;
2647 *) ac_site_file1=./$CONFIG_SITE;;
2649 elif test "x$prefix" != xNONE; then
2650 ac_site_file1=$prefix/share/config.site
2651 ac_site_file2=$prefix/etc/config.site
2653 ac_site_file1=$ac_default_prefix/share/config.site
2654 ac_site_file2=$ac_default_prefix/etc/config.site
2656 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2658 test "x$ac_site_file" = xNONE && continue
2659 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2660 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2661 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2662 sed 's/^/| /' "$ac_site_file" >&5
2664 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2665 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2666 as_fn_error $? "failed to load site script $ac_site_file
2667 See \`config.log' for more details" "$LINENO" 5; }
2671 if test -r "$cache_file"; then
2672 # Some versions of bash will fail to source /dev/null (special files
2673 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2674 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2675 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2676 $as_echo "$as_me: loading cache $cache_file" >&6;}
2678 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2679 *) . "./$cache_file";;
2683 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2684 $as_echo "$as_me: creating cache $cache_file" >&6;}
2688 # Check that the precious variables saved in the cache have kept the same
2690 ac_cache_corrupted=false
2691 for ac_var in $ac_precious_vars; do
2692 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2693 eval ac_new_set=\$ac_env_${ac_var}_set
2694 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2695 eval ac_new_val=\$ac_env_${ac_var}_value
2696 case $ac_old_set,$ac_new_set in
2698 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2699 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2700 ac_cache_corrupted=: ;;
2702 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2703 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2704 ac_cache_corrupted=: ;;
2707 if test "x$ac_old_val" != "x$ac_new_val"; then
2708 # differences in whitespace do not lead to failure.
2709 ac_old_val_w=`echo x $ac_old_val`
2710 ac_new_val_w=`echo x $ac_new_val`
2711 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2712 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2713 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2714 ac_cache_corrupted=:
2716 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2717 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2718 eval $ac_var=\$ac_old_val
2720 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2721 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2722 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2723 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2726 # Pass precious variables to config.status.
2727 if test "$ac_new_set" = set; then
2729 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2730 *) ac_arg=$ac_var=$ac_new_val ;;
2732 case " $ac_configure_args " in
2733 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2734 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2738 if $ac_cache_corrupted; then
2739 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2740 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2741 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2742 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2743 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2745 ## -------------------- ##
2746 ## Main body of script. ##
2747 ## -------------------- ##
2750 ac_cpp='$CPP $CPPFLAGS'
2751 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2752 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2753 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2761 for ac_dir in config "$srcdir"/config; do
2762 if test -f "$ac_dir/install-sh"; then
2764 ac_install_sh="$ac_aux_dir/install-sh -c"
2766 elif test -f "$ac_dir/install.sh"; then
2768 ac_install_sh="$ac_aux_dir/install.sh -c"
2770 elif test -f "$ac_dir/shtool"; then
2772 ac_install_sh="$ac_aux_dir/shtool install -c"
2776 if test -z "$ac_aux_dir"; then
2777 as_fn_error $? "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5
2780 # These three variables are undocumented and unsupported,
2781 # and are intended to be withdrawn in a future Autoconf release.
2782 # They can cause serious problems if a builder's source tree is in a directory
2783 # whose full name contains unusual characters.
2784 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2785 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2786 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2790 configure_args=$ac_configure_args
2793 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\)'`
2796 cat >>confdefs.h <<_ACEOF
2797 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2804 # Check whether --with-extra-version was given.
2805 if test "${with_extra_version+set}" = set; then :
2806 withval=$with_extra_version;
2809 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2812 as_fn_error $? "argument required for --with-extra-version option" "$LINENO" 5
2815 PG_VERSION="$PACKAGE_VERSION$withval"
2820 PG_VERSION="$PACKAGE_VERSION"
2825 cat >>confdefs.h <<_ACEOF
2826 #define PG_VERSION "$PG_VERSION"
2830 # Make sure we can run config.sub.
2831 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2832 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2835 $as_echo_n "checking build system type... " >&6; }
2836 if ${ac_cv_build+:} false; then :
2837 $as_echo_n "(cached) " >&6
2839 ac_build_alias=$build_alias
2840 test "x$ac_build_alias" = x &&
2841 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2842 test "x$ac_build_alias" = x &&
2843 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2844 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2845 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2849 $as_echo "$ac_cv_build" >&6; }
2850 case $ac_cv_build in
2852 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2855 ac_save_IFS=$IFS; IFS='-'
2861 # Remember, the first character of IFS is used to create $*,
2862 # except with old shells:
2865 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2869 $as_echo_n "checking host system type... " >&6; }
2870 if ${ac_cv_host+:} false; then :
2871 $as_echo_n "(cached) " >&6
2873 if test "x$host_alias" = x; then
2874 ac_cv_host=$ac_cv_build
2876 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2877 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
2881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2882 $as_echo "$ac_cv_host" >&6; }
2885 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2888 ac_save_IFS=$IFS; IFS='-'
2894 # Remember, the first character of IFS is used to create $*,
2895 # except with old shells:
2898 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which template to use" >&5
2904 $as_echo_n "checking which template to use... " >&6; }
2909 # Check whether --with-template was given.
2910 if test "${with_template+set}" = set; then :
2911 withval=$with_template;
2914 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2917 as_fn_error $? "argument required for --with-template option" "$LINENO" 5
2922 list) echo; ls "$srcdir/src/template"; exit;;
2923 *) if test -f "$srcdir/src/template/$with_template" ; then
2926 as_fn_error $? "'$withval' is not a valid template name. Use 'list' for a list." "$LINENO" 5
2935 # --with-template not given
2938 aix*) template=aix ;;
2939 cygwin*) template=cygwin ;;
2940 darwin*) template=darwin ;;
2941 dragonfly*) template=netbsd ;;
2942 freebsd*) template=freebsd ;;
2943 hpux*) template=hpux ;;
2944 linux*|gnu*|k*bsd*-gnu)
2946 mingw*) template=win32 ;;
2947 netbsd*) template=netbsd ;;
2948 openbsd*) template=openbsd ;;
2949 solaris*) template=solaris ;;
2952 if test x"$template" = x"" ; then
2954 *******************************************************************
2955 PostgreSQL has apparently not been ported to your platform yet.
2956 To try a manual configuration, look into the src/template directory
2957 for a similar platform and use the '--with-template=' option.
2959 Please also contact <pgsql-bugs@postgresql.org> to see about
2960 rectifying this. Include the above 'checking host system type...'
2962 *******************************************************************
2971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $template" >&5
2972 $as_echo "$template" >&6; }
2977 # Initialize default assumption that we do not need separate assembly code
2978 # for TAS (test-and-set). This can be overridden by the template file
2979 # when it's executed.
2986 ## Command line options
2990 # Add non-standard directories to the include path
2995 # Check whether --with-includes was given.
2996 if test "${with_includes+set}" = set; then :
2997 withval=$with_includes;
3000 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3003 as_fn_error $? "argument required for --with-includes option" "$LINENO" 5
3016 # Add non-standard directories to the library search path
3021 # Check whether --with-libraries was given.
3022 if test "${with_libraries+set}" = set; then :
3023 withval=$with_libraries;
3026 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3029 as_fn_error $? "argument required for --with-libraries option" "$LINENO" 5
3032 LIBRARY_DIRS=$withval
3043 # Check whether --with-libs was given.
3044 if test "${with_libs+set}" = set; then :
3048 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3051 as_fn_error $? "argument required for --with-libs option" "$LINENO" 5
3054 LIBRARY_DIRS=$withval
3064 # 64-bit integer date/time storage is now the only option, but to avoid
3065 # unnecessary breakage of build scripts, continue to accept an explicit
3066 # "--enable-integer-datetimes" switch.
3070 # Check whether --enable-integer-datetimes was given.
3071 if test "${enable_integer_datetimes+set}" = set; then :
3072 enableval=$enable_integer_datetimes;
3078 as_fn_error $? "--disable-integer-datetimes is no longer supported" "$LINENO" 5
3081 as_fn_error $? "no argument expected for --enable-integer-datetimes option" "$LINENO" 5
3086 enable_integer_datetimes=yes
3096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is wanted" >&5
3097 $as_echo_n "checking whether NLS is wanted... " >&6; }
3100 # Check whether --enable-nls was given.
3101 if test "${enable_nls+set}" = set; then :
3102 enableval=$enable_nls;
3112 WANTED_LANGUAGES=$enableval
3122 if test "$enable_nls" = yes; then
3124 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
3128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_nls" >&5
3129 $as_echo "$enable_nls" >&6; }
3134 # Default port number (--with-pgport), default 5432
3136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default port number" >&5
3137 $as_echo_n "checking for default port number... " >&6; }
3141 # Check whether --with-pgport was given.
3142 if test "${with_pgport+set}" = set; then :
3143 withval=$with_pgport;
3146 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3149 as_fn_error $? "argument required for --with-pgport option" "$LINENO" 5
3152 default_port=$withval
3161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $default_port" >&5
3162 $as_echo "$default_port" >&6; }
3163 # Need both of these because some places want an integer and some a string
3165 cat >>confdefs.h <<_ACEOF
3166 #define DEF_PGPORT ${default_port}
3170 cat >>confdefs.h <<_ACEOF
3171 #define DEF_PGPORT_STR "${default_port}"
3176 # It's worth validating port; you can get very confusing errors otherwise
3177 if test x"$default_port" = x""; then
3178 as_fn_error $? "invalid --with-pgport specification: empty string" "$LINENO" 5
3179 elif test ! x`echo "$default_port" | sed -e 's/[0-9]*//'` = x""; then
3180 as_fn_error $? "invalid --with-pgport specification: must be a number" "$LINENO" 5
3181 elif test ! x`echo "$default_port" | sed -e 's/^0.//'` = x"$default_port"; then
3182 as_fn_error $? "invalid --with-pgport specification: must not have leading 0" "$LINENO" 5
3183 elif test "$default_port" -lt "1" -o "$default_port" -gt "65535"; then
3184 as_fn_error $? "invalid --with-pgport specification: must be between 1 and 65535" "$LINENO" 5
3188 # '-rpath'-like feature can be disabled
3192 # Check whether --enable-rpath was given.
3193 if test "${enable_rpath+set}" = set; then :
3194 enableval=$enable_rpath;
3203 as_fn_error $? "no argument expected for --enable-rpath option" "$LINENO" 5
3220 # Check whether --enable-spinlocks was given.
3221 if test "${enable_spinlocks+set}" = set; then :
3222 enableval=$enable_spinlocks;
3231 as_fn_error $? "no argument expected for --enable-spinlocks option" "$LINENO" 5
3236 enable_spinlocks=yes
3247 # Check whether --enable-atomics was given.
3248 if test "${enable_atomics+set}" = set; then :
3249 enableval=$enable_atomics;
3258 as_fn_error $? "no argument expected for --enable-atomics option" "$LINENO" 5
3270 # Random number generation
3274 # Check whether --enable-strong-random was given.
3275 if test "${enable_strong_random+set}" = set; then :
3276 enableval=$enable_strong_random;
3285 as_fn_error $? "no argument expected for --enable-strong-random option" "$LINENO" 5
3290 enable_strong_random=yes
3298 # --enable-debug adds -g to compiler flags
3302 # Check whether --enable-debug was given.
3303 if test "${enable_debug+set}" = set; then :
3304 enableval=$enable_debug;
3313 as_fn_error $? "no argument expected for --enable-debug option" "$LINENO" 5
3326 # --enable-profiling enables gcc profiling
3330 # Check whether --enable-profiling was given.
3331 if test "${enable_profiling+set}" = set; then :
3332 enableval=$enable_profiling;
3341 as_fn_error $? "no argument expected for --enable-profiling option" "$LINENO" 5
3353 # --enable-coverage enables generation of code coverage metrics with gcov
3357 # Check whether --enable-coverage was given.
3358 if test "${enable_coverage+set}" = set; then :
3359 enableval=$enable_coverage;
3362 if test -z "$GCOV"; then
3365 # Extract the first word of "$ac_prog", so it can be a program name with args.
3366 set dummy $ac_prog; ac_word=$2
3367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3368 $as_echo_n "checking for $ac_word... " >&6; }
3369 if ${ac_cv_path_GCOV+:} false; then :
3370 $as_echo_n "(cached) " >&6
3374 ac_cv_path_GCOV="$GCOV" # Let the user override the test with a path.
3377 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3381 test -z "$as_dir" && as_dir=.
3382 for ac_exec_ext in '' $ac_executable_extensions; do
3383 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3384 ac_cv_path_GCOV="$as_dir/$ac_word$ac_exec_ext"
3385 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3395 GCOV=$ac_cv_path_GCOV
3396 if test -n "$GCOV"; then
3397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3398 $as_echo "$GCOV" >&6; }
3400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3401 $as_echo "no" >&6; }
3405 test -n "$GCOV" && break
3409 # Report the value of GCOV in configure's output in all cases.
3410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GCOV" >&5
3411 $as_echo_n "checking for GCOV... " >&6; }
3412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
3413 $as_echo "$GCOV" >&6; }
3416 if test -z "$GCOV"; then
3417 as_fn_error $? "gcov not found" "$LINENO" 5
3419 if test -z "$LCOV"; then
3422 # Extract the first word of "$ac_prog", so it can be a program name with args.
3423 set dummy $ac_prog; ac_word=$2
3424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3425 $as_echo_n "checking for $ac_word... " >&6; }
3426 if ${ac_cv_path_LCOV+:} false; then :
3427 $as_echo_n "(cached) " >&6
3431 ac_cv_path_LCOV="$LCOV" # Let the user override the test with a path.
3434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3438 test -z "$as_dir" && as_dir=.
3439 for ac_exec_ext in '' $ac_executable_extensions; do
3440 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3441 ac_cv_path_LCOV="$as_dir/$ac_word$ac_exec_ext"
3442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3452 LCOV=$ac_cv_path_LCOV
3453 if test -n "$LCOV"; then
3454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3455 $as_echo "$LCOV" >&6; }
3457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3458 $as_echo "no" >&6; }
3462 test -n "$LCOV" && break
3466 # Report the value of LCOV in configure's output in all cases.
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCOV" >&5
3468 $as_echo_n "checking for LCOV... " >&6; }
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
3470 $as_echo "$LCOV" >&6; }
3473 if test -z "$LCOV"; then
3474 as_fn_error $? "lcov not found" "$LINENO" 5
3476 if test -z "$GENHTML"; then
3477 for ac_prog in genhtml
3479 # Extract the first word of "$ac_prog", so it can be a program name with args.
3480 set dummy $ac_prog; ac_word=$2
3481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3482 $as_echo_n "checking for $ac_word... " >&6; }
3483 if ${ac_cv_path_GENHTML+:} false; then :
3484 $as_echo_n "(cached) " >&6
3488 ac_cv_path_GENHTML="$GENHTML" # Let the user override the test with a path.
3491 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3495 test -z "$as_dir" && as_dir=.
3496 for ac_exec_ext in '' $ac_executable_extensions; do
3497 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3498 ac_cv_path_GENHTML="$as_dir/$ac_word$ac_exec_ext"
3499 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3509 GENHTML=$ac_cv_path_GENHTML
3510 if test -n "$GENHTML"; then
3511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3512 $as_echo "$GENHTML" >&6; }
3514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3515 $as_echo "no" >&6; }
3519 test -n "$GENHTML" && break
3523 # Report the value of GENHTML in configure's output in all cases.
3524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GENHTML" >&5
3525 $as_echo_n "checking for GENHTML... " >&6; }
3526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5
3527 $as_echo "$GENHTML" >&6; }
3530 if test -z "$GENHTML"; then
3531 as_fn_error $? "genhtml not found" "$LINENO" 5
3538 as_fn_error $? "no argument expected for --enable-coverage option" "$LINENO" 5
3555 # Check whether --enable-dtrace was given.
3556 if test "${enable_dtrace+set}" = set; then :
3557 enableval=$enable_dtrace;
3560 if test -z "$DTRACE"; then
3561 for ac_prog in dtrace
3563 # Extract the first word of "$ac_prog", so it can be a program name with args.
3564 set dummy $ac_prog; ac_word=$2
3565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3566 $as_echo_n "checking for $ac_word... " >&6; }
3567 if ${ac_cv_path_DTRACE+:} false; then :
3568 $as_echo_n "(cached) " >&6
3572 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
3575 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3579 test -z "$as_dir" && as_dir=.
3580 for ac_exec_ext in '' $ac_executable_extensions; do
3581 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3582 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext"
3583 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3593 DTRACE=$ac_cv_path_DTRACE
3594 if test -n "$DTRACE"; then
3595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3596 $as_echo "$DTRACE" >&6; }
3598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3599 $as_echo "no" >&6; }
3603 test -n "$DTRACE" && break
3607 # Report the value of DTRACE in configure's output in all cases.
3608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5
3609 $as_echo_n "checking for DTRACE... " >&6; }
3610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
3611 $as_echo "$DTRACE" >&6; }
3614 if test -z "$DTRACE"; then
3615 as_fn_error $? "dtrace not found" "$LINENO" 5
3623 as_fn_error $? "no argument expected for --enable-dtrace option" "$LINENO" 5
3640 # Check whether --enable-tap-tests was given.
3641 if test "${enable_tap_tests+set}" = set; then :
3642 enableval=$enable_tap_tests;
3651 as_fn_error $? "no argument expected for --enable-tap-tests option" "$LINENO" 5
3666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for block size" >&5
3667 $as_echo_n "checking for block size... " >&6; }
3671 # Check whether --with-blocksize was given.
3672 if test "${with_blocksize+set}" = set; then :
3673 withval=$with_blocksize;
3676 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3679 as_fn_error $? "argument required for --with-blocksize option" "$LINENO" 5
3691 case ${blocksize} in
3698 *) as_fn_error $? "Invalid block size. Allowed values are 1,2,4,8,16,32." "$LINENO" 5
3700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${blocksize}kB" >&5
3701 $as_echo "${blocksize}kB" >&6; }
3704 cat >>confdefs.h <<_ACEOF
3705 #define BLCKSZ ${BLCKSZ}
3710 # Relation segment size
3712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for segment size" >&5
3713 $as_echo_n "checking for segment size... " >&6; }
3717 # Check whether --with-segsize was given.
3718 if test "${with_segsize+set}" = set; then :
3719 withval=$with_segsize;
3722 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3725 as_fn_error $? "argument required for --with-segsize option" "$LINENO" 5
3737 # this expression is set up to avoid unnecessary integer overflow
3738 # blocksize is already guaranteed to be a factor of 1024
3739 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
3740 test $? -eq 0 || exit 1
3741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${segsize}GB" >&5
3742 $as_echo "${segsize}GB" >&6; }
3745 cat >>confdefs.h <<_ACEOF
3746 #define RELSEG_SIZE ${RELSEG_SIZE}
3753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WAL block size" >&5
3754 $as_echo_n "checking for WAL block size... " >&6; }
3758 # Check whether --with-wal-blocksize was given.
3759 if test "${with_wal_blocksize+set}" = set; then :
3760 withval=$with_wal_blocksize;
3763 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3766 as_fn_error $? "argument required for --with-wal-blocksize option" "$LINENO" 5
3769 wal_blocksize=$withval
3778 case ${wal_blocksize} in
3779 1) XLOG_BLCKSZ=1024;;
3780 2) XLOG_BLCKSZ=2048;;
3781 4) XLOG_BLCKSZ=4096;;
3782 8) XLOG_BLCKSZ=8192;;
3783 16) XLOG_BLCKSZ=16384;;
3784 32) XLOG_BLCKSZ=32768;;
3785 64) XLOG_BLCKSZ=65536;;
3786 *) as_fn_error $? "Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." "$LINENO" 5
3788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${wal_blocksize}kB" >&5
3789 $as_echo "${wal_blocksize}kB" >&6; }
3792 cat >>confdefs.h <<_ACEOF
3793 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3801 # For historical reasons you can also use --with-CC to specify the C compiler
3802 # to use, although the standard way to do this is to set the CC environment
3807 # Check whether --with-CC was given.
3808 if test "${with_CC+set}" = set; then :
3812 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3815 as_fn_error $? "argument required for --with-CC option" "$LINENO" 5
3827 aix) pgac_cc_list="gcc xlc"; pgac_cxx_list="g++ xlC";;
3828 *) pgac_cc_list="gcc cc"; pgac_cxx_list="g++ c++";;
3832 ac_cpp='$CPP $CPPFLAGS'
3833 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3834 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3835 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3836 if test -n "$ac_tool_prefix"; then
3837 for ac_prog in $pgac_cc_list
3839 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3840 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3842 $as_echo_n "checking for $ac_word... " >&6; }
3843 if ${ac_cv_prog_CC+:} false; then :
3844 $as_echo_n "(cached) " >&6
3846 if test -n "$CC"; then
3847 ac_cv_prog_CC="$CC" # Let the user override the test.
3849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3853 test -z "$as_dir" && as_dir=.
3854 for ac_exec_ext in '' $ac_executable_extensions; do
3855 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3856 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3857 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3867 if test -n "$CC"; then
3868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3869 $as_echo "$CC" >&6; }
3871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3872 $as_echo "no" >&6; }
3876 test -n "$CC" && break
3879 if test -z "$CC"; then
3881 for ac_prog in $pgac_cc_list
3883 # Extract the first word of "$ac_prog", so it can be a program name with args.
3884 set dummy $ac_prog; ac_word=$2
3885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3886 $as_echo_n "checking for $ac_word... " >&6; }
3887 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3888 $as_echo_n "(cached) " >&6
3890 if test -n "$ac_ct_CC"; then
3891 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3897 test -z "$as_dir" && as_dir=.
3898 for ac_exec_ext in '' $ac_executable_extensions; do
3899 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3900 ac_cv_prog_ac_ct_CC="$ac_prog"
3901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3910 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3911 if test -n "$ac_ct_CC"; then
3912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3913 $as_echo "$ac_ct_CC" >&6; }
3915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3916 $as_echo "no" >&6; }
3920 test -n "$ac_ct_CC" && break
3923 if test "x$ac_ct_CC" = x; then
3926 case $cross_compiling:$ac_tool_warned in
3928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3929 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3930 ac_tool_warned=yes ;;
3937 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3938 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3939 as_fn_error $? "no acceptable C compiler found in \$PATH
3940 See \`config.log' for more details" "$LINENO" 5; }
3942 # Provide some information about the compiler.
3943 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3946 for ac_option in --version -v -V -qversion; do
3947 { { ac_try="$ac_compiler $ac_option >&5"
3949 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3950 *) ac_try_echo=$ac_try;;
3952 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3953 $as_echo "$ac_try_echo"; } >&5
3954 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3956 if test -s conftest.err; then
3958 ... rest of stderr output deleted ...
3959 10q' conftest.err >conftest.er1
3960 cat conftest.er1 >&5
3962 rm -f conftest.er1 conftest.err
3963 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3964 test $ac_status = 0; }
3967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3968 /* end confdefs.h. */
3978 ac_clean_files_save=$ac_clean_files
3979 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3980 # Try to create an executable without -o first, disregard a.out.
3981 # It will help us diagnose broken compilers, and finding out an intuition
3983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3984 $as_echo_n "checking whether the C compiler works... " >&6; }
3985 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3987 # The possible output files:
3988 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3991 for ac_file in $ac_files
3994 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3995 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4000 if { { ac_try="$ac_link_default"
4002 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4003 *) ac_try_echo=$ac_try;;
4005 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4006 $as_echo "$ac_try_echo"; } >&5
4007 (eval "$ac_link_default") 2>&5
4009 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4010 test $ac_status = 0; }; then :
4011 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4012 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4013 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4014 # so that the user can short-circuit this test for compilers unknown to
4016 for ac_file in $ac_files ''
4018 test -f "$ac_file" || continue
4020 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4023 # We found the default executable, but exeext='' is most
4027 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4029 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4031 # We set ac_cv_exeext here because the later test for it is not
4032 # safe: cross compilers may not add the suffix if given an `-o'
4033 # argument, so we may need to know it at that point already.
4034 # Even if this section looks crufty: it has the advantage of
4041 test "$ac_cv_exeext" = no && ac_cv_exeext=
4046 if test -z "$ac_file"; then :
4047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4048 $as_echo "no" >&6; }
4049 $as_echo "$as_me: failed program was:" >&5
4050 sed 's/^/| /' conftest.$ac_ext >&5
4052 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4053 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4054 as_fn_error 77 "C compiler cannot create executables
4055 See \`config.log' for more details" "$LINENO" 5; }
4057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4058 $as_echo "yes" >&6; }
4060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4061 $as_echo_n "checking for C compiler default output file name... " >&6; }
4062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4063 $as_echo "$ac_file" >&6; }
4064 ac_exeext=$ac_cv_exeext
4066 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4067 ac_clean_files=$ac_clean_files_save
4068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4069 $as_echo_n "checking for suffix of executables... " >&6; }
4070 if { { ac_try="$ac_link"
4072 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4073 *) ac_try_echo=$ac_try;;
4075 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4076 $as_echo "$ac_try_echo"; } >&5
4077 (eval "$ac_link") 2>&5
4079 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4080 test $ac_status = 0; }; then :
4081 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4082 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4083 # work properly (i.e., refer to `conftest.exe'), while it won't with
4085 for ac_file in conftest.exe conftest conftest.*; do
4086 test -f "$ac_file" || continue
4088 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4089 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4095 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4096 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4097 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4098 See \`config.log' for more details" "$LINENO" 5; }
4100 rm -f conftest conftest$ac_cv_exeext
4101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4102 $as_echo "$ac_cv_exeext" >&6; }
4104 rm -f conftest.$ac_ext
4105 EXEEXT=$ac_cv_exeext
4107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4108 /* end confdefs.h. */
4113 FILE *f = fopen ("conftest.out", "w");
4114 return ferror (f) || fclose (f) != 0;
4120 ac_clean_files="$ac_clean_files conftest.out"
4121 # Check that the compiler produces executables we can run. If not, either
4122 # the compiler is broken, or we cross compile.
4123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4124 $as_echo_n "checking whether we are cross compiling... " >&6; }
4125 if test "$cross_compiling" != yes; then
4126 { { ac_try="$ac_link"
4128 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4129 *) ac_try_echo=$ac_try;;
4131 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4132 $as_echo "$ac_try_echo"; } >&5
4133 (eval "$ac_link") 2>&5
4135 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4136 test $ac_status = 0; }
4137 if { ac_try='./conftest$ac_cv_exeext'
4138 { { case "(($ac_try" in
4139 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4140 *) ac_try_echo=$ac_try;;
4142 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4143 $as_echo "$ac_try_echo"; } >&5
4144 (eval "$ac_try") 2>&5
4146 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4147 test $ac_status = 0; }; }; then
4150 if test "$cross_compiling" = maybe; then
4153 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4154 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4155 as_fn_error $? "cannot run C compiled programs.
4156 If you meant to cross compile, use \`--host'.
4157 See \`config.log' for more details" "$LINENO" 5; }
4161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4162 $as_echo "$cross_compiling" >&6; }
4164 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4165 ac_clean_files=$ac_clean_files_save
4166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4167 $as_echo_n "checking for suffix of object files... " >&6; }
4168 if ${ac_cv_objext+:} false; then :
4169 $as_echo_n "(cached) " >&6
4171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4172 /* end confdefs.h. */
4182 rm -f conftest.o conftest.obj
4183 if { { ac_try="$ac_compile"
4185 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4186 *) ac_try_echo=$ac_try;;
4188 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4189 $as_echo "$ac_try_echo"; } >&5
4190 (eval "$ac_compile") 2>&5
4192 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4193 test $ac_status = 0; }; then :
4194 for ac_file in conftest.o conftest.obj conftest.*; do
4195 test -f "$ac_file" || continue;
4197 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4198 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4203 $as_echo "$as_me: failed program was:" >&5
4204 sed 's/^/| /' conftest.$ac_ext >&5
4206 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4207 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4208 as_fn_error $? "cannot compute suffix of object files: cannot compile
4209 See \`config.log' for more details" "$LINENO" 5; }
4211 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4214 $as_echo "$ac_cv_objext" >&6; }
4215 OBJEXT=$ac_cv_objext
4217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4218 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4219 if ${ac_cv_c_compiler_gnu+:} false; then :
4220 $as_echo_n "(cached) " >&6
4222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4223 /* end confdefs.h. */
4236 if ac_fn_c_try_compile "$LINENO"; then :
4241 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4242 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4246 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4247 if test $ac_compiler_gnu = yes; then
4252 ac_test_CFLAGS=${CFLAGS+set}
4253 ac_save_CFLAGS=$CFLAGS
4254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4255 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4256 if ${ac_cv_prog_cc_g+:} false; then :
4257 $as_echo_n "(cached) " >&6
4259 ac_save_c_werror_flag=$ac_c_werror_flag
4260 ac_c_werror_flag=yes
4263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4264 /* end confdefs.h. */
4274 if ac_fn_c_try_compile "$LINENO"; then :
4278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4279 /* end confdefs.h. */
4289 if ac_fn_c_try_compile "$LINENO"; then :
4292 ac_c_werror_flag=$ac_save_c_werror_flag
4294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4295 /* end confdefs.h. */
4305 if ac_fn_c_try_compile "$LINENO"; then :
4308 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4313 ac_c_werror_flag=$ac_save_c_werror_flag
4315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4316 $as_echo "$ac_cv_prog_cc_g" >&6; }
4317 if test "$ac_test_CFLAGS" = set; then
4318 CFLAGS=$ac_save_CFLAGS
4319 elif test $ac_cv_prog_cc_g = yes; then
4320 if test "$GCC" = yes; then
4326 if test "$GCC" = yes; then
4332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4333 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4334 if ${ac_cv_prog_cc_c89+:} false; then :
4335 $as_echo_n "(cached) " >&6
4337 ac_cv_prog_cc_c89=no
4339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4340 /* end confdefs.h. */
4344 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4345 struct buf { int x; };
4346 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4347 static char *e (p, i)
4353 static char *f (char * (*g) (char **, int), char **p, ...)
4358 s = g (p, va_arg (v,int));
4363 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4364 function prototypes and stuff, but not '\xHH' hex character constants.
4365 These don't provoke an error unfortunately, instead are silently treated
4366 as 'x'. The following induces an error, until -std is added to get
4367 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4368 array size at least. It's necessary to write '\x00'==0 to get something
4369 that's true only with -std. */
4370 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4372 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4373 inside strings and character constants. */
4375 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4377 int test (int i, double x);
4378 struct s1 {int (*f) (int a);};
4379 struct s2 {int (*f) (double a);};
4380 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4386 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4391 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4392 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4394 CC="$ac_save_CC $ac_arg"
4395 if ac_fn_c_try_compile "$LINENO"; then :
4396 ac_cv_prog_cc_c89=$ac_arg
4398 rm -f core conftest.err conftest.$ac_objext
4399 test "x$ac_cv_prog_cc_c89" != "xno" && break
4401 rm -f conftest.$ac_ext
4406 case "x$ac_cv_prog_cc_c89" in
4408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4409 $as_echo "none needed" >&6; } ;;
4411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4412 $as_echo "unsupported" >&6; } ;;
4414 CC="$CC $ac_cv_prog_cc_c89"
4415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4416 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4418 if test "x$ac_cv_prog_cc_c89" != xno; then :
4423 ac_cpp='$CPP $CPPFLAGS'
4424 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4425 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4426 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
4429 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
4430 if ${ac_cv_prog_cc_c99+:} false; then :
4431 $as_echo_n "(cached) " >&6
4433 ac_cv_prog_cc_c99=no
4435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4436 /* end confdefs.h. */
4438 #include <stdbool.h>
4443 // Check varargs macros. These examples are taken from C99 6.10.3.5.
4444 #define debug(...) fprintf (stderr, __VA_ARGS__)
4445 #define showlist(...) puts (#__VA_ARGS__)
4446 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
4448 test_varargs_macros (void)
4453 debug ("X = %d\n", x);
4454 showlist (The first, second, and third items.);
4455 report (x>y, "x is %d but y is %d", x, y);
4458 // Check long long types.
4459 #define BIG64 18446744073709551615ull
4460 #define BIG32 4294967295ul
4461 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
4463 your preprocessor is broken;
4467 your preprocessor is broken;
4469 static long long int bignum = -9223372036854775807LL;
4470 static unsigned long long int ubignum = BIG64;
4472 struct incomplete_array
4480 const wchar_t *name;
4484 typedef const char *ccp;
4487 test_restrict (ccp restrict text)
4489 // See if C++-style comments work.
4490 // Iterate through items via the restricted pointer.
4491 // Also check for declarations in for loops.
4492 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
4497 // Check varargs and va_copy.
4499 test_varargs (const char *format, ...)
4502 va_start (args, format);
4504 va_copy (args_copy, args);
4515 str = va_arg (args_copy, const char *);
4518 number = va_arg (args_copy, int);
4521 fnumber = va_arg (args_copy, double);
4536 _Bool success = false;
4539 if (test_restrict ("String literal") == 0)
4541 char *restrict newvar = "Another string";
4544 test_varargs ("s, d' f .", "string", 65, 34.234);
4545 test_varargs_macros ();
4547 // Check flexible array members.
4548 struct incomplete_array *ia =
4549 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
4551 for (int i = 0; i < ia->datasize; ++i)
4552 ia->data[i] = i * 1.234;
4554 // Check named initializers.
4555 struct named_init ni = {
4557 .name = L"Test wide string",
4558 .average = 543.34343,
4563 int dynamic_array[ni.number];
4564 dynamic_array[ni.number - 1] = 543;
4566 // work around unused variable warnings
4567 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
4568 || dynamic_array[ni.number - 1] != 543);
4574 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
4576 CC="$ac_save_CC $ac_arg"
4577 if ac_fn_c_try_compile "$LINENO"; then :
4578 ac_cv_prog_cc_c99=$ac_arg
4580 rm -f core conftest.err conftest.$ac_objext
4581 test "x$ac_cv_prog_cc_c99" != "xno" && break
4583 rm -f conftest.$ac_ext
4588 case "x$ac_cv_prog_cc_c99" in
4590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4591 $as_echo "none needed" >&6; } ;;
4593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4594 $as_echo "unsupported" >&6; } ;;
4596 CC="$CC $ac_cv_prog_cc_c99"
4597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4598 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
4600 if test "x$ac_cv_prog_cc_c99" != xno; then :
4606 # Error out if the compiler does not support C99, as the codebase
4608 if test "$ac_cv_prog_cc_c99" = no; then
4609 as_fn_error $? "C compiler \"$CC\" does not support C99" "$LINENO" 5
4613 ac_cpp='$CXXCPP $CPPFLAGS'
4614 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4615 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4616 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
4617 if test -z "$CXX"; then
4618 if test -n "$CCC"; then
4621 if test -n "$ac_tool_prefix"; then
4622 for ac_prog in $pgac_cxx_list
4624 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4625 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4627 $as_echo_n "checking for $ac_word... " >&6; }
4628 if ${ac_cv_prog_CXX+:} false; then :
4629 $as_echo_n "(cached) " >&6
4631 if test -n "$CXX"; then
4632 ac_cv_prog_CXX="$CXX" # Let the user override the test.
4634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4638 test -z "$as_dir" && as_dir=.
4639 for ac_exec_ext in '' $ac_executable_extensions; do
4640 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4641 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
4642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4652 if test -n "$CXX"; then
4653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
4654 $as_echo "$CXX" >&6; }
4656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4657 $as_echo "no" >&6; }
4661 test -n "$CXX" && break
4664 if test -z "$CXX"; then
4666 for ac_prog in $pgac_cxx_list
4668 # Extract the first word of "$ac_prog", so it can be a program name with args.
4669 set dummy $ac_prog; ac_word=$2
4670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4671 $as_echo_n "checking for $ac_word... " >&6; }
4672 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
4673 $as_echo_n "(cached) " >&6
4675 if test -n "$ac_ct_CXX"; then
4676 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
4678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4682 test -z "$as_dir" && as_dir=.
4683 for ac_exec_ext in '' $ac_executable_extensions; do
4684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4685 ac_cv_prog_ac_ct_CXX="$ac_prog"
4686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4695 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
4696 if test -n "$ac_ct_CXX"; then
4697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
4698 $as_echo "$ac_ct_CXX" >&6; }
4700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4701 $as_echo "no" >&6; }
4705 test -n "$ac_ct_CXX" && break
4708 if test "x$ac_ct_CXX" = x; then
4711 case $cross_compiling:$ac_tool_warned in
4713 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4714 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4715 ac_tool_warned=yes ;;
4723 # Provide some information about the compiler.
4724 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
4727 for ac_option in --version -v -V -qversion; do
4728 { { ac_try="$ac_compiler $ac_option >&5"
4730 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4731 *) ac_try_echo=$ac_try;;
4733 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4734 $as_echo "$ac_try_echo"; } >&5
4735 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4737 if test -s conftest.err; then
4739 ... rest of stderr output deleted ...
4740 10q' conftest.err >conftest.er1
4741 cat conftest.er1 >&5
4743 rm -f conftest.er1 conftest.err
4744 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4745 test $ac_status = 0; }
4748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
4749 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
4750 if ${ac_cv_cxx_compiler_gnu+:} false; then :
4751 $as_echo_n "(cached) " >&6
4753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4754 /* end confdefs.h. */
4767 if ac_fn_cxx_try_compile "$LINENO"; then :
4772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4773 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
4776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
4777 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
4778 if test $ac_compiler_gnu = yes; then
4783 ac_test_CXXFLAGS=${CXXFLAGS+set}
4784 ac_save_CXXFLAGS=$CXXFLAGS
4785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
4786 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
4787 if ${ac_cv_prog_cxx_g+:} false; then :
4788 $as_echo_n "(cached) " >&6
4790 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
4791 ac_cxx_werror_flag=yes
4794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4795 /* end confdefs.h. */
4805 if ac_fn_cxx_try_compile "$LINENO"; then :
4806 ac_cv_prog_cxx_g=yes
4809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4810 /* end confdefs.h. */
4820 if ac_fn_cxx_try_compile "$LINENO"; then :
4823 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4826 /* end confdefs.h. */
4836 if ac_fn_cxx_try_compile "$LINENO"; then :
4837 ac_cv_prog_cxx_g=yes
4839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4841 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4844 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4847 $as_echo "$ac_cv_prog_cxx_g" >&6; }
4848 if test "$ac_test_CXXFLAGS" = set; then
4849 CXXFLAGS=$ac_save_CXXFLAGS
4850 elif test $ac_cv_prog_cxx_g = yes; then
4851 if test "$GXX" = yes; then
4857 if test "$GXX" = yes; then
4864 ac_cpp='$CPP $CPPFLAGS'
4865 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4866 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4867 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4870 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
4871 # but has idiosyncrasies of its own. We assume icc will define
4872 # __INTEL_COMPILER regardless of CFLAGS.
4874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4875 /* end confdefs.h. */
4880 #ifndef __INTEL_COMPILER
4887 if ac_fn_c_try_compile "$LINENO"; then :
4892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4894 # Check if it's Sun Studio compiler. We assume that
4895 # __SUNPRO_C will be defined for Sun Studio compilers
4896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4897 /* end confdefs.h. */
4909 if ac_fn_c_try_compile "$LINENO"; then :
4914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4922 # Checked early because subsequent tests depend on it.
4926 # Check whether --with-llvm was given.
4927 if test "${with_llvm+set}" = set; then :
4932 $as_echo "#define USE_LLVM 1" >>confdefs.h
4939 as_fn_error $? "no argument expected for --with-llvm option" "$LINENO" 5
4950 if test "$with_llvm" = yes ; then
4951 for ac_prog in gawk mawk nawk awk
4953 # Extract the first word of "$ac_prog", so it can be a program name with args.
4954 set dummy $ac_prog; ac_word=$2
4955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4956 $as_echo_n "checking for $ac_word... " >&6; }
4957 if ${ac_cv_prog_AWK+:} false; then :
4958 $as_echo_n "(cached) " >&6
4960 if test -n "$AWK"; then
4961 ac_cv_prog_AWK="$AWK" # Let the user override the test.
4963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4967 test -z "$as_dir" && as_dir=.
4968 for ac_exec_ext in '' $ac_executable_extensions; do
4969 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4970 ac_cv_prog_AWK="$ac_prog"
4971 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4981 if test -n "$AWK"; then
4982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4983 $as_echo "$AWK" >&6; }
4985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4986 $as_echo "no" >&6; }
4990 test -n "$AWK" && break
4997 if test -z "$LLVM_CONFIG"; then
4998 for ac_prog in llvm-config llvm-config-6.0 llvm-config-5.0 llvm-config-4.0 llvm-config-3.9
5000 # Extract the first word of "$ac_prog", so it can be a program name with args.
5001 set dummy $ac_prog; ac_word=$2
5002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5003 $as_echo_n "checking for $ac_word... " >&6; }
5004 if ${ac_cv_path_LLVM_CONFIG+:} false; then :
5005 $as_echo_n "(cached) " >&6
5007 case $LLVM_CONFIG in
5009 ac_cv_path_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test with a path.
5012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5016 test -z "$as_dir" && as_dir=.
5017 for ac_exec_ext in '' $ac_executable_extensions; do
5018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5019 ac_cv_path_LLVM_CONFIG="$as_dir/$ac_word$ac_exec_ext"
5020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5030 LLVM_CONFIG=$ac_cv_path_LLVM_CONFIG
5031 if test -n "$LLVM_CONFIG"; then
5032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
5033 $as_echo "$LLVM_CONFIG" >&6; }
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5036 $as_echo "no" >&6; }
5040 test -n "$LLVM_CONFIG" && break
5044 # Report the value of LLVM_CONFIG in configure's output in all cases.
5045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LLVM_CONFIG" >&5
5046 $as_echo_n "checking for LLVM_CONFIG... " >&6; }
5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
5048 $as_echo "$LLVM_CONFIG" >&6; }
5052 # no point continuing if llvm wasn't found
5053 if test -z "$LLVM_CONFIG"; then
5054 as_fn_error $? "llvm-config not found, but required when compiling --with-llvm, specify with LLVM_CONFIG=" "$LINENO" 5
5056 # check if detected $LLVM_CONFIG is executable
5057 pgac_llvm_version="$($LLVM_CONFIG --version 2> /dev/null || echo no)"
5058 if test "x$pgac_llvm_version" = "xno"; then
5059 as_fn_error $? "$LLVM_CONFIG does not work" "$LINENO" 5
5061 # and whether the version is supported
5062 if echo $pgac_llvm_version | $AWK -F '.' '{ if ($1 >= 4 || ($1 == 3 && $2 >= 9)) exit 1; else exit 0;}';then
5063 as_fn_error $? "$LLVM_CONFIG version is $pgac_llvm_version but at least 3.9 is required" "$LINENO" 5
5066 # need clang to create some bitcode files
5068 if test -z "$CLANG"; then
5069 for ac_prog in clang clang-6.0 clang-5.0 clang-4.0 clang-3.9
5071 # Extract the first word of "$ac_prog", so it can be a program name with args.
5072 set dummy $ac_prog; ac_word=$2
5073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5074 $as_echo_n "checking for $ac_word... " >&6; }
5075 if ${ac_cv_path_CLANG+:} false; then :
5076 $as_echo_n "(cached) " >&6
5080 ac_cv_path_CLANG="$CLANG" # Let the user override the test with a path.
5083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5087 test -z "$as_dir" && as_dir=.
5088 for ac_exec_ext in '' $ac_executable_extensions; do
5089 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5090 ac_cv_path_CLANG="$as_dir/$ac_word$ac_exec_ext"
5091 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5101 CLANG=$ac_cv_path_CLANG
5102 if test -n "$CLANG"; then
5103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
5104 $as_echo "$CLANG" >&6; }
5106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5107 $as_echo "no" >&6; }
5111 test -n "$CLANG" && break
5115 # Report the value of CLANG in configure's output in all cases.
5116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CLANG" >&5
5117 $as_echo_n "checking for CLANG... " >&6; }
5118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5
5119 $as_echo "$CLANG" >&6; }
5122 if test -z "$CLANG"; then
5123 as_fn_error $? "clang not found, but required when compiling --with-llvm, specify with CLANG=" "$LINENO" 5
5125 # make sure clang is executable
5126 if test "x$($CLANG --version 2> /dev/null || echo no)" = "xno"; then
5127 as_fn_error $? "$CLANG does not work" "$LINENO" 5
5129 # Could check clang version, but it doesn't seem that
5130 # important. Systems with a new enough LLVM version are usually
5131 # going to have a decent clang version too. It's also not entirely
5132 # clear what the minimum version is.
5134 # Collect compiler flags necessary to build the LLVM dependent
5136 for pgac_option in `$LLVM_CONFIG --cppflags`; do
5137 case $pgac_option in
5138 -I*|-D*) LLVM_CPPFLAGS="$pgac_option $LLVM_CPPFLAGS";;
5142 for pgac_option in `$LLVM_CONFIG --ldflags`; do
5143 case $pgac_option in
5144 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5148 # ABI influencing options, standard influencing options
5149 for pgac_option in `$LLVM_CONFIG --cxxflags`; do
5150 case $pgac_option in
5151 -fno-rtti*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
5152 -std=*) LLVM_CXXFLAGS="$LLVM_CXXFLAGS $pgac_option";;
5156 # Look for components we're interested in, collect necessary
5157 # libs. As some components are optional, we can't just list all of
5158 # them as it'd raise an error.
5160 for pgac_component in `$LLVM_CONFIG --components`; do
5161 case $pgac_component in
5162 engine) pgac_components="$pgac_components $pgac_component";;
5163 debuginfodwarf) pgac_components="$pgac_components $pgac_component";;
5164 orcjit) pgac_components="$pgac_components $pgac_component";;
5165 passes) pgac_components="$pgac_components $pgac_component";;
5166 perfjitevents) pgac_components="$pgac_components $pgac_component";;
5170 # And then get the libraries that need to be linked in for the
5171 # selected components. They're large libraries, we only want to
5172 # link them into the LLVM using shared library.
5173 for pgac_option in `$LLVM_CONFIG --libs --system-libs $pgac_components`; do
5174 case $pgac_option in
5175 -l*) LLVM_LIBS="$LLVM_LIBS $pgac_option";;
5179 LLVM_BINPATH=`$LLVM_CONFIG --bindir`
5181 # Check which functionality is present
5182 SAVE_CPPFLAGS="$CPPFLAGS"
5183 CPPFLAGS="$CPPFLAGS $LLVM_CPPFLAGS"
5184 ac_fn_c_check_decl "$LINENO" "LLVMOrcGetSymbolAddressIn" "ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" "#include <llvm-c/OrcBindings.h>
5186 if test "x$ac_cv_have_decl_LLVMOrcGetSymbolAddressIn" = xyes; then :
5192 cat >>confdefs.h <<_ACEOF
5193 #define HAVE_DECL_LLVMORCGETSYMBOLADDRESSIN $ac_have_decl
5196 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUName" "ac_cv_have_decl_LLVMGetHostCPUName" "#include <llvm-c/TargetMachine.h>
5198 if test "x$ac_cv_have_decl_LLVMGetHostCPUName" = xyes; then :
5204 cat >>confdefs.h <<_ACEOF
5205 #define HAVE_DECL_LLVMGETHOSTCPUNAME $ac_have_decl
5207 ac_fn_c_check_decl "$LINENO" "LLVMGetHostCPUFeatures" "ac_cv_have_decl_LLVMGetHostCPUFeatures" "#include <llvm-c/TargetMachine.h>
5209 if test "x$ac_cv_have_decl_LLVMGetHostCPUFeatures" = xyes; then :
5215 cat >>confdefs.h <<_ACEOF
5216 #define HAVE_DECL_LLVMGETHOSTCPUFEATURES $ac_have_decl
5219 ac_fn_c_check_decl "$LINENO" "LLVMCreateGDBRegistrationListener" "ac_cv_have_decl_LLVMCreateGDBRegistrationListener" "#include <llvm-c/ExecutionEngine.h>
5221 if test "x$ac_cv_have_decl_LLVMCreateGDBRegistrationListener" = xyes; then :
5227 cat >>confdefs.h <<_ACEOF
5228 #define HAVE_DECL_LLVMCREATEGDBREGISTRATIONLISTENER $ac_have_decl
5230 ac_fn_c_check_decl "$LINENO" "LLVMCreatePerfJITEventListener" "ac_cv_have_decl_LLVMCreatePerfJITEventListener" "#include <llvm-c/ExecutionEngine.h>
5232 if test "x$ac_cv_have_decl_LLVMCreatePerfJITEventListener" = xyes; then :
5238 cat >>confdefs.h <<_ACEOF
5239 #define HAVE_DECL_LLVMCREATEPERFJITEVENTLISTENER $ac_have_decl
5242 CPPFLAGS="$SAVE_CPPFLAGS"
5244 # LLVM_CONFIG, CLANG are already output via AC_ARG_VAR
5261 . "$srcdir/src/template/$template" || exit
5263 # C[XX]FLAGS are selected so:
5264 # If the user specifies something in the environment, that is used.
5265 # else: If the template file set something, that is used.
5266 # else: If coverage was enabled, don't set anything.
5267 # else: If the compiler is GCC, then we use -O2.
5268 # else: If the compiler is something else, then we use -O, unless debugging.
5270 if test "$ac_env_CFLAGS_set" = set; then
5271 CFLAGS=$ac_env_CFLAGS_value
5272 elif test "${CFLAGS+set}" = set; then
5273 : # (keep what template set)
5274 elif test "$enable_coverage" = yes; then
5275 : # no optimization by default
5276 elif test "$GCC" = yes; then
5279 # if the user selected debug mode, don't use -O
5280 if test "$enable_debug" != yes; then
5285 if test "$ac_env_CXXFLAGS_set" = set; then
5286 CXXFLAGS=$ac_env_CXXFLAGS_value
5287 elif test "${CXXFLAGS+set}" = set; then
5288 : # (keep what template set)
5289 elif test "$enable_coverage" = yes; then
5290 : # no optimization by default
5291 elif test "$GCC" = yes; then
5294 # if the user selected debug mode, don't use -O
5295 if test "$enable_debug" != yes; then
5300 # When generating bitcode (for inlining) we always want to use -O2
5301 # even when --enable-debug is specified. The bitcode it's not going to
5302 # be used for line-by-line debugging, and JIT inlining doesn't work
5303 # without at least -O1 (otherwise clang will emit 'noinline'
5304 # attributes everywhere), which is bad for testing. Still allow the
5305 # environment to override if done explicitly.
5306 if test "$ac_env_BITCODE_CFLAGS_set" = set; then
5307 BITCODE_CFLAGS=$ac_env_BITCODE_CFLAGS_value
5309 BITCODE_CFLAGS="-O2 $BITCODE_CFLAGS"
5311 if test "$ac_env_BITCODE_CXXFLAGS_set" = set; then
5312 BITCODE_CXXFLAGS=$ac_env_BITCODE_CXXFLAGS_value
5314 BITCODE_CXXFLAGS="-O2 $BITCODE_CXXFLAGS"
5317 # C[XX]FLAGS we determined above will be added back at the end
5320 user_CXXFLAGS=$CXXFLAGS
5322 user_BITCODE_CFLAGS=$BITCODE_CFLAGS
5324 user_BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
5327 # set CFLAGS_VECTOR from the environment, if available
5328 if test "$ac_env_CFLAGS_VECTOR_set" = set; then
5329 CFLAGS_VECTOR=$ac_env_CFLAGS_VECTOR_value
5332 # Some versions of GCC support some additional useful warning flags.
5333 # Check whether they are supported, and add them to CFLAGS if so.
5334 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
5335 # but has its own. Also check other compiler-specific flags here.
5337 if test "$GCC" = yes -a "$ICC" = no; then
5338 CFLAGS="-Wall -Wmissing-prototypes -Wpointer-arith"
5339 CXXFLAGS="-Wall -Wpointer-arith"
5340 # These work in some but not all gcc versions
5342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS" >&5
5343 $as_echo_n "checking whether ${CC} supports -Wdeclaration-after-statement, for CFLAGS... " >&6; }
5344 if ${pgac_cv_prog_CC_cflags__Wdeclaration_after_statement+:} false; then :
5345 $as_echo_n "(cached) " >&6
5347 pgac_save_CFLAGS=$CFLAGS
5350 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5351 ac_save_c_werror_flag=$ac_c_werror_flag
5352 ac_c_werror_flag=yes
5353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5354 /* end confdefs.h. */
5364 if ac_fn_c_try_compile "$LINENO"; then :
5365 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=yes
5367 pgac_cv_prog_CC_cflags__Wdeclaration_after_statement=no
5369 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5370 ac_c_werror_flag=$ac_save_c_werror_flag
5371 CFLAGS="$pgac_save_CFLAGS"
5374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&5
5375 $as_echo "$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" >&6; }
5376 if test x"$pgac_cv_prog_CC_cflags__Wdeclaration_after_statement" = x"yes"; then
5377 CFLAGS="${CFLAGS} -Wdeclaration-after-statement"
5381 # -Wdeclaration-after-statement isn't applicable for C++
5382 # Really don't want VLAs to be used in our dialect of C
5384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Werror=vla, for CFLAGS" >&5
5385 $as_echo_n "checking whether ${CC} supports -Werror=vla, for CFLAGS... " >&6; }
5386 if ${pgac_cv_prog_CC_cflags__Werror_vla+:} false; then :
5387 $as_echo_n "(cached) " >&6
5389 pgac_save_CFLAGS=$CFLAGS
5392 CFLAGS="${CFLAGS} -Werror=vla"
5393 ac_save_c_werror_flag=$ac_c_werror_flag
5394 ac_c_werror_flag=yes
5395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5396 /* end confdefs.h. */
5406 if ac_fn_c_try_compile "$LINENO"; then :
5407 pgac_cv_prog_CC_cflags__Werror_vla=yes
5409 pgac_cv_prog_CC_cflags__Werror_vla=no
5411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5412 ac_c_werror_flag=$ac_save_c_werror_flag
5413 CFLAGS="$pgac_save_CFLAGS"
5416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Werror_vla" >&5
5417 $as_echo "$pgac_cv_prog_CC_cflags__Werror_vla" >&6; }
5418 if test x"$pgac_cv_prog_CC_cflags__Werror_vla" = x"yes"; then
5419 CFLAGS="${CFLAGS} -Werror=vla"
5423 # -Wvla is not applicable for C++
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wendif-labels, for CFLAGS" >&5
5426 $as_echo_n "checking whether ${CC} supports -Wendif-labels, for CFLAGS... " >&6; }
5427 if ${pgac_cv_prog_CC_cflags__Wendif_labels+:} false; then :
5428 $as_echo_n "(cached) " >&6
5430 pgac_save_CFLAGS=$CFLAGS
5433 CFLAGS="${CFLAGS} -Wendif-labels"
5434 ac_save_c_werror_flag=$ac_c_werror_flag
5435 ac_c_werror_flag=yes
5436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5437 /* end confdefs.h. */
5447 if ac_fn_c_try_compile "$LINENO"; then :
5448 pgac_cv_prog_CC_cflags__Wendif_labels=yes
5450 pgac_cv_prog_CC_cflags__Wendif_labels=no
5452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5453 ac_c_werror_flag=$ac_save_c_werror_flag
5454 CFLAGS="$pgac_save_CFLAGS"
5457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wendif_labels" >&5
5458 $as_echo "$pgac_cv_prog_CC_cflags__Wendif_labels" >&6; }
5459 if test x"$pgac_cv_prog_CC_cflags__Wendif_labels" = x"yes"; then
5460 CFLAGS="${CFLAGS} -Wendif-labels"
5464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS" >&5
5465 $as_echo_n "checking whether ${CXX} supports -Wendif-labels, for CXXFLAGS... " >&6; }
5466 if ${pgac_cv_prog_CXX_cxxflags__Wendif_labels+:} false; then :
5467 $as_echo_n "(cached) " >&6
5469 pgac_save_CXXFLAGS=$CXXFLAGS
5472 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5473 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5474 ac_cxx_werror_flag=yes
5476 ac_cpp='$CXXCPP $CPPFLAGS'
5477 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5478 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5479 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5482 /* end confdefs.h. */
5492 if ac_fn_cxx_try_compile "$LINENO"; then :
5493 pgac_cv_prog_CXX_cxxflags__Wendif_labels=yes
5495 pgac_cv_prog_CXX_cxxflags__Wendif_labels=no
5497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5499 ac_cpp='$CPP $CPPFLAGS'
5500 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5501 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5502 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5504 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5505 CXXFLAGS="$pgac_save_CXXFLAGS"
5506 CXX="$pgac_save_CXX"
5508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&5
5509 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wendif_labels" >&6; }
5510 if test x"$pgac_cv_prog_CXX_cxxflags__Wendif_labels" = x"yes"; then
5511 CXXFLAGS="${CXXFLAGS} -Wendif-labels"
5516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS" >&5
5517 $as_echo_n "checking whether ${CC} supports -Wmissing-format-attribute, for CFLAGS... " >&6; }
5518 if ${pgac_cv_prog_CC_cflags__Wmissing_format_attribute+:} false; then :
5519 $as_echo_n "(cached) " >&6
5521 pgac_save_CFLAGS=$CFLAGS
5524 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5525 ac_save_c_werror_flag=$ac_c_werror_flag
5526 ac_c_werror_flag=yes
5527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5528 /* end confdefs.h. */
5538 if ac_fn_c_try_compile "$LINENO"; then :
5539 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=yes
5541 pgac_cv_prog_CC_cflags__Wmissing_format_attribute=no
5543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5544 ac_c_werror_flag=$ac_save_c_werror_flag
5545 CFLAGS="$pgac_save_CFLAGS"
5548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&5
5549 $as_echo "$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" >&6; }
5550 if test x"$pgac_cv_prog_CC_cflags__Wmissing_format_attribute" = x"yes"; then
5551 CFLAGS="${CFLAGS} -Wmissing-format-attribute"
5555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS" >&5
5556 $as_echo_n "checking whether ${CXX} supports -Wmissing-format-attribute, for CXXFLAGS... " >&6; }
5557 if ${pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute+:} false; then :
5558 $as_echo_n "(cached) " >&6
5560 pgac_save_CXXFLAGS=$CXXFLAGS
5563 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5564 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5565 ac_cxx_werror_flag=yes
5567 ac_cpp='$CXXCPP $CPPFLAGS'
5568 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5569 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5570 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5573 /* end confdefs.h. */
5583 if ac_fn_cxx_try_compile "$LINENO"; then :
5584 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=yes
5586 pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute=no
5588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5590 ac_cpp='$CPP $CPPFLAGS'
5591 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5592 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5593 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5595 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5596 CXXFLAGS="$pgac_save_CXXFLAGS"
5597 CXX="$pgac_save_CXX"
5599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&5
5600 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" >&6; }
5601 if test x"$pgac_cv_prog_CXX_cxxflags__Wmissing_format_attribute" = x"yes"; then
5602 CXXFLAGS="${CXXFLAGS} -Wmissing-format-attribute"
5606 # This was included in -Wall/-Wformat in older GCC versions
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-security, for CFLAGS" >&5
5609 $as_echo_n "checking whether ${CC} supports -Wformat-security, for CFLAGS... " >&6; }
5610 if ${pgac_cv_prog_CC_cflags__Wformat_security+:} false; then :
5611 $as_echo_n "(cached) " >&6
5613 pgac_save_CFLAGS=$CFLAGS
5616 CFLAGS="${CFLAGS} -Wformat-security"
5617 ac_save_c_werror_flag=$ac_c_werror_flag
5618 ac_c_werror_flag=yes
5619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5620 /* end confdefs.h. */
5630 if ac_fn_c_try_compile "$LINENO"; then :
5631 pgac_cv_prog_CC_cflags__Wformat_security=yes
5633 pgac_cv_prog_CC_cflags__Wformat_security=no
5635 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5636 ac_c_werror_flag=$ac_save_c_werror_flag
5637 CFLAGS="$pgac_save_CFLAGS"
5640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_security" >&5
5641 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_security" >&6; }
5642 if test x"$pgac_cv_prog_CC_cflags__Wformat_security" = x"yes"; then
5643 CFLAGS="${CFLAGS} -Wformat-security"
5647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -Wformat-security, for CXXFLAGS" >&5
5648 $as_echo_n "checking whether ${CXX} supports -Wformat-security, for CXXFLAGS... " >&6; }
5649 if ${pgac_cv_prog_CXX_cxxflags__Wformat_security+:} false; then :
5650 $as_echo_n "(cached) " >&6
5652 pgac_save_CXXFLAGS=$CXXFLAGS
5655 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5656 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5657 ac_cxx_werror_flag=yes
5659 ac_cpp='$CXXCPP $CPPFLAGS'
5660 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5661 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5662 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5665 /* end confdefs.h. */
5675 if ac_fn_cxx_try_compile "$LINENO"; then :
5676 pgac_cv_prog_CXX_cxxflags__Wformat_security=yes
5678 pgac_cv_prog_CXX_cxxflags__Wformat_security=no
5680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5682 ac_cpp='$CPP $CPPFLAGS'
5683 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5684 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5685 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5687 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5688 CXXFLAGS="$pgac_save_CXXFLAGS"
5689 CXX="$pgac_save_CXX"
5691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__Wformat_security" >&5
5692 $as_echo "$pgac_cv_prog_CXX_cxxflags__Wformat_security" >&6; }
5693 if test x"$pgac_cv_prog_CXX_cxxflags__Wformat_security" = x"yes"; then
5694 CXXFLAGS="${CXXFLAGS} -Wformat-security"
5698 # Disable strict-aliasing rules; needed for gcc 3.3+
5700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
5701 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
5702 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
5703 $as_echo_n "(cached) " >&6
5705 pgac_save_CFLAGS=$CFLAGS
5708 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5709 ac_save_c_werror_flag=$ac_c_werror_flag
5710 ac_c_werror_flag=yes
5711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5712 /* end confdefs.h. */
5722 if ac_fn_c_try_compile "$LINENO"; then :
5723 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
5725 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
5727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5728 ac_c_werror_flag=$ac_save_c_werror_flag
5729 CFLAGS="$pgac_save_CFLAGS"
5732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
5733 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
5734 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
5735 CFLAGS="${CFLAGS} -fno-strict-aliasing"
5739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
5740 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
5741 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
5742 $as_echo_n "(cached) " >&6
5744 pgac_save_CXXFLAGS=$CXXFLAGS
5747 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5748 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5749 ac_cxx_werror_flag=yes
5751 ac_cpp='$CXXCPP $CPPFLAGS'
5752 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5753 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5754 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5757 /* end confdefs.h. */
5767 if ac_fn_cxx_try_compile "$LINENO"; then :
5768 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
5770 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
5772 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5774 ac_cpp='$CPP $CPPFLAGS'
5775 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5776 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5777 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5779 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5780 CXXFLAGS="$pgac_save_CXXFLAGS"
5781 CXX="$pgac_save_CXX"
5783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
5784 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
5785 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
5786 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
5790 # Disable optimizations that assume no overflow; needed for gcc 4.3+
5792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fwrapv, for CFLAGS" >&5
5793 $as_echo_n "checking whether ${CC} supports -fwrapv, for CFLAGS... " >&6; }
5794 if ${pgac_cv_prog_CC_cflags__fwrapv+:} false; then :
5795 $as_echo_n "(cached) " >&6
5797 pgac_save_CFLAGS=$CFLAGS
5800 CFLAGS="${CFLAGS} -fwrapv"
5801 ac_save_c_werror_flag=$ac_c_werror_flag
5802 ac_c_werror_flag=yes
5803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5804 /* end confdefs.h. */
5814 if ac_fn_c_try_compile "$LINENO"; then :
5815 pgac_cv_prog_CC_cflags__fwrapv=yes
5817 pgac_cv_prog_CC_cflags__fwrapv=no
5819 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5820 ac_c_werror_flag=$ac_save_c_werror_flag
5821 CFLAGS="$pgac_save_CFLAGS"
5824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fwrapv" >&5
5825 $as_echo "$pgac_cv_prog_CC_cflags__fwrapv" >&6; }
5826 if test x"$pgac_cv_prog_CC_cflags__fwrapv" = x"yes"; then
5827 CFLAGS="${CFLAGS} -fwrapv"
5831 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fwrapv, for CXXFLAGS" >&5
5832 $as_echo_n "checking whether ${CXX} supports -fwrapv, for CXXFLAGS... " >&6; }
5833 if ${pgac_cv_prog_CXX_cxxflags__fwrapv+:} false; then :
5834 $as_echo_n "(cached) " >&6
5836 pgac_save_CXXFLAGS=$CXXFLAGS
5839 CXXFLAGS="${CXXFLAGS} -fwrapv"
5840 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5841 ac_cxx_werror_flag=yes
5843 ac_cpp='$CXXCPP $CPPFLAGS'
5844 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5845 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5846 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5849 /* end confdefs.h. */
5859 if ac_fn_cxx_try_compile "$LINENO"; then :
5860 pgac_cv_prog_CXX_cxxflags__fwrapv=yes
5862 pgac_cv_prog_CXX_cxxflags__fwrapv=no
5864 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5866 ac_cpp='$CPP $CPPFLAGS'
5867 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5868 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5869 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5871 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5872 CXXFLAGS="$pgac_save_CXXFLAGS"
5873 CXX="$pgac_save_CXX"
5875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fwrapv" >&5
5876 $as_echo "$pgac_cv_prog_CXX_cxxflags__fwrapv" >&6; }
5877 if test x"$pgac_cv_prog_CXX_cxxflags__fwrapv" = x"yes"; then
5878 CXXFLAGS="${CXXFLAGS} -fwrapv"
5882 # Disable FP optimizations that cause various errors on gcc 4.5+ or maybe 4.6+
5884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS" >&5
5885 $as_echo_n "checking whether ${CC} supports -fexcess-precision=standard, for CFLAGS... " >&6; }
5886 if ${pgac_cv_prog_CC_cflags__fexcess_precision_standard+:} false; then :
5887 $as_echo_n "(cached) " >&6
5889 pgac_save_CFLAGS=$CFLAGS
5892 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5893 ac_save_c_werror_flag=$ac_c_werror_flag
5894 ac_c_werror_flag=yes
5895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5896 /* end confdefs.h. */
5906 if ac_fn_c_try_compile "$LINENO"; then :
5907 pgac_cv_prog_CC_cflags__fexcess_precision_standard=yes
5909 pgac_cv_prog_CC_cflags__fexcess_precision_standard=no
5911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5912 ac_c_werror_flag=$ac_save_c_werror_flag
5913 CFLAGS="$pgac_save_CFLAGS"
5916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&5
5917 $as_echo "$pgac_cv_prog_CC_cflags__fexcess_precision_standard" >&6; }
5918 if test x"$pgac_cv_prog_CC_cflags__fexcess_precision_standard" = x"yes"; then
5919 CFLAGS="${CFLAGS} -fexcess-precision=standard"
5923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS" >&5
5924 $as_echo_n "checking whether ${CXX} supports -fexcess-precision=standard, for CXXFLAGS... " >&6; }
5925 if ${pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard+:} false; then :
5926 $as_echo_n "(cached) " >&6
5928 pgac_save_CXXFLAGS=$CXXFLAGS
5931 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5932 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
5933 ac_cxx_werror_flag=yes
5935 ac_cpp='$CXXCPP $CPPFLAGS'
5936 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5937 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5938 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
5940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5941 /* end confdefs.h. */
5951 if ac_fn_cxx_try_compile "$LINENO"; then :
5952 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=yes
5954 pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard=no
5956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5958 ac_cpp='$CPP $CPPFLAGS'
5959 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5960 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5961 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5963 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
5964 CXXFLAGS="$pgac_save_CXXFLAGS"
5965 CXX="$pgac_save_CXX"
5967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&5
5968 $as_echo "$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" >&6; }
5969 if test x"$pgac_cv_prog_CXX_cxxflags__fexcess_precision_standard" = x"yes"; then
5970 CXXFLAGS="${CXXFLAGS} -fexcess-precision=standard"
5974 # Optimization flags for specific files that benefit from vectorization
5975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR" >&5
5976 $as_echo_n "checking whether ${CC} supports -funroll-loops, for CFLAGS_VECTOR... " >&6; }
5977 if ${pgac_cv_prog_CC_cflags__funroll_loops+:} false; then :
5978 $as_echo_n "(cached) " >&6
5980 pgac_save_CFLAGS=$CFLAGS
5983 CFLAGS="${CFLAGS_VECTOR} -funroll-loops"
5984 ac_save_c_werror_flag=$ac_c_werror_flag
5985 ac_c_werror_flag=yes
5986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5987 /* end confdefs.h. */
5997 if ac_fn_c_try_compile "$LINENO"; then :
5998 pgac_cv_prog_CC_cflags__funroll_loops=yes
6000 pgac_cv_prog_CC_cflags__funroll_loops=no
6002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6003 ac_c_werror_flag=$ac_save_c_werror_flag
6004 CFLAGS="$pgac_save_CFLAGS"
6007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__funroll_loops" >&5
6008 $as_echo "$pgac_cv_prog_CC_cflags__funroll_loops" >&6; }
6009 if test x"$pgac_cv_prog_CC_cflags__funroll_loops" = x"yes"; then
6010 CFLAGS_VECTOR="${CFLAGS_VECTOR} -funroll-loops"
6014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR" >&5
6015 $as_echo_n "checking whether ${CC} supports -ftree-vectorize, for CFLAGS_VECTOR... " >&6; }
6016 if ${pgac_cv_prog_CC_cflags__ftree_vectorize+:} false; then :
6017 $as_echo_n "(cached) " >&6
6019 pgac_save_CFLAGS=$CFLAGS
6022 CFLAGS="${CFLAGS_VECTOR} -ftree-vectorize"
6023 ac_save_c_werror_flag=$ac_c_werror_flag
6024 ac_c_werror_flag=yes
6025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6026 /* end confdefs.h. */
6036 if ac_fn_c_try_compile "$LINENO"; then :
6037 pgac_cv_prog_CC_cflags__ftree_vectorize=yes
6039 pgac_cv_prog_CC_cflags__ftree_vectorize=no
6041 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6042 ac_c_werror_flag=$ac_save_c_werror_flag
6043 CFLAGS="$pgac_save_CFLAGS"
6046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__ftree_vectorize" >&5
6047 $as_echo "$pgac_cv_prog_CC_cflags__ftree_vectorize" >&6; }
6048 if test x"$pgac_cv_prog_CC_cflags__ftree_vectorize" = x"yes"; then
6049 CFLAGS_VECTOR="${CFLAGS_VECTOR} -ftree-vectorize"
6053 # We want to suppress clang's unhelpful unused-command-line-argument warnings
6054 # but gcc won't complain about unrecognized -Wno-foo switches, so we have to
6055 # test for the positive form and if that works, add the negative form
6057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS" >&5
6058 $as_echo_n "checking whether ${CC} supports -Wunused-command-line-argument, for NOT_THE_CFLAGS... " >&6; }
6059 if ${pgac_cv_prog_CC_cflags__Wunused_command_line_argument+:} false; then :
6060 $as_echo_n "(cached) " >&6
6062 pgac_save_CFLAGS=$CFLAGS
6065 CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
6066 ac_save_c_werror_flag=$ac_c_werror_flag
6067 ac_c_werror_flag=yes
6068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6069 /* end confdefs.h. */
6079 if ac_fn_c_try_compile "$LINENO"; then :
6080 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=yes
6082 pgac_cv_prog_CC_cflags__Wunused_command_line_argument=no
6084 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6085 ac_c_werror_flag=$ac_save_c_werror_flag
6086 CFLAGS="$pgac_save_CFLAGS"
6089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&5
6090 $as_echo "$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" >&6; }
6091 if test x"$pgac_cv_prog_CC_cflags__Wunused_command_line_argument" = x"yes"; then
6092 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wunused-command-line-argument"
6096 if test -n "$NOT_THE_CFLAGS"; then
6097 CFLAGS="$CFLAGS -Wno-unused-command-line-argument"
6099 # Similarly disable useless truncation warnings from gcc 8+
6101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS" >&5
6102 $as_echo_n "checking whether ${CC} supports -Wformat-truncation, for NOT_THE_CFLAGS... " >&6; }
6103 if ${pgac_cv_prog_CC_cflags__Wformat_truncation+:} false; then :
6104 $as_echo_n "(cached) " >&6
6106 pgac_save_CFLAGS=$CFLAGS
6109 CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
6110 ac_save_c_werror_flag=$ac_c_werror_flag
6111 ac_c_werror_flag=yes
6112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6113 /* end confdefs.h. */
6123 if ac_fn_c_try_compile "$LINENO"; then :
6124 pgac_cv_prog_CC_cflags__Wformat_truncation=yes
6126 pgac_cv_prog_CC_cflags__Wformat_truncation=no
6128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6129 ac_c_werror_flag=$ac_save_c_werror_flag
6130 CFLAGS="$pgac_save_CFLAGS"
6133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wformat_truncation" >&5
6134 $as_echo "$pgac_cv_prog_CC_cflags__Wformat_truncation" >&6; }
6135 if test x"$pgac_cv_prog_CC_cflags__Wformat_truncation" = x"yes"; then
6136 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wformat-truncation"
6140 if test -n "$NOT_THE_CFLAGS"; then
6141 CFLAGS="$CFLAGS -Wno-format-truncation"
6144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS" >&5
6145 $as_echo_n "checking whether ${CC} supports -Wstringop-truncation, for NOT_THE_CFLAGS... " >&6; }
6146 if ${pgac_cv_prog_CC_cflags__Wstringop_truncation+:} false; then :
6147 $as_echo_n "(cached) " >&6
6149 pgac_save_CFLAGS=$CFLAGS
6152 CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
6153 ac_save_c_werror_flag=$ac_c_werror_flag
6154 ac_c_werror_flag=yes
6155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6156 /* end confdefs.h. */
6166 if ac_fn_c_try_compile "$LINENO"; then :
6167 pgac_cv_prog_CC_cflags__Wstringop_truncation=yes
6169 pgac_cv_prog_CC_cflags__Wstringop_truncation=no
6171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6172 ac_c_werror_flag=$ac_save_c_werror_flag
6173 CFLAGS="$pgac_save_CFLAGS"
6176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__Wstringop_truncation" >&5
6177 $as_echo "$pgac_cv_prog_CC_cflags__Wstringop_truncation" >&6; }
6178 if test x"$pgac_cv_prog_CC_cflags__Wstringop_truncation" = x"yes"; then
6179 NOT_THE_CFLAGS="${NOT_THE_CFLAGS} -Wstringop-truncation"
6183 if test -n "$NOT_THE_CFLAGS"; then
6184 CFLAGS="$CFLAGS -Wno-stringop-truncation"
6186 elif test "$ICC" = yes; then
6187 # Intel's compiler has a bug/misoptimization in checking for
6188 # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
6190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -mp1, for CFLAGS" >&5
6191 $as_echo_n "checking whether ${CC} supports -mp1, for CFLAGS... " >&6; }
6192 if ${pgac_cv_prog_CC_cflags__mp1+:} false; then :
6193 $as_echo_n "(cached) " >&6
6195 pgac_save_CFLAGS=$CFLAGS
6198 CFLAGS="${CFLAGS} -mp1"
6199 ac_save_c_werror_flag=$ac_c_werror_flag
6200 ac_c_werror_flag=yes
6201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6202 /* end confdefs.h. */
6212 if ac_fn_c_try_compile "$LINENO"; then :
6213 pgac_cv_prog_CC_cflags__mp1=yes
6215 pgac_cv_prog_CC_cflags__mp1=no
6217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6218 ac_c_werror_flag=$ac_save_c_werror_flag
6219 CFLAGS="$pgac_save_CFLAGS"
6222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__mp1" >&5
6223 $as_echo "$pgac_cv_prog_CC_cflags__mp1" >&6; }
6224 if test x"$pgac_cv_prog_CC_cflags__mp1" = x"yes"; then
6225 CFLAGS="${CFLAGS} -mp1"
6229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -mp1, for CXXFLAGS" >&5
6230 $as_echo_n "checking whether ${CXX} supports -mp1, for CXXFLAGS... " >&6; }
6231 if ${pgac_cv_prog_CXX_cxxflags__mp1+:} false; then :
6232 $as_echo_n "(cached) " >&6
6234 pgac_save_CXXFLAGS=$CXXFLAGS
6237 CXXFLAGS="${CXXFLAGS} -mp1"
6238 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6239 ac_cxx_werror_flag=yes
6241 ac_cpp='$CXXCPP $CPPFLAGS'
6242 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6243 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6244 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6247 /* end confdefs.h. */
6257 if ac_fn_cxx_try_compile "$LINENO"; then :
6258 pgac_cv_prog_CXX_cxxflags__mp1=yes
6260 pgac_cv_prog_CXX_cxxflags__mp1=no
6262 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6264 ac_cpp='$CPP $CPPFLAGS'
6265 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6266 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6267 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6269 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6270 CXXFLAGS="$pgac_save_CXXFLAGS"
6271 CXX="$pgac_save_CXX"
6273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__mp1" >&5
6274 $as_echo "$pgac_cv_prog_CXX_cxxflags__mp1" >&6; }
6275 if test x"$pgac_cv_prog_CXX_cxxflags__mp1" = x"yes"; then
6276 CXXFLAGS="${CXXFLAGS} -mp1"
6280 # Make sure strict aliasing is off (though this is said to be the default)
6282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS" >&5
6283 $as_echo_n "checking whether ${CC} supports -fno-strict-aliasing, for CFLAGS... " >&6; }
6284 if ${pgac_cv_prog_CC_cflags__fno_strict_aliasing+:} false; then :
6285 $as_echo_n "(cached) " >&6
6287 pgac_save_CFLAGS=$CFLAGS
6290 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6291 ac_save_c_werror_flag=$ac_c_werror_flag
6292 ac_c_werror_flag=yes
6293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6294 /* end confdefs.h. */
6304 if ac_fn_c_try_compile "$LINENO"; then :
6305 pgac_cv_prog_CC_cflags__fno_strict_aliasing=yes
6307 pgac_cv_prog_CC_cflags__fno_strict_aliasing=no
6309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6310 ac_c_werror_flag=$ac_save_c_werror_flag
6311 CFLAGS="$pgac_save_CFLAGS"
6314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&5
6315 $as_echo "$pgac_cv_prog_CC_cflags__fno_strict_aliasing" >&6; }
6316 if test x"$pgac_cv_prog_CC_cflags__fno_strict_aliasing" = x"yes"; then
6317 CFLAGS="${CFLAGS} -fno-strict-aliasing"
6321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS" >&5
6322 $as_echo_n "checking whether ${CXX} supports -fno-strict-aliasing, for CXXFLAGS... " >&6; }
6323 if ${pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing+:} false; then :
6324 $as_echo_n "(cached) " >&6
6326 pgac_save_CXXFLAGS=$CXXFLAGS
6329 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6330 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6331 ac_cxx_werror_flag=yes
6333 ac_cpp='$CXXCPP $CPPFLAGS'
6334 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6335 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6336 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6339 /* end confdefs.h. */
6349 if ac_fn_cxx_try_compile "$LINENO"; then :
6350 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=yes
6352 pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing=no
6354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6356 ac_cpp='$CPP $CPPFLAGS'
6357 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6358 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6359 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6361 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6362 CXXFLAGS="$pgac_save_CXXFLAGS"
6363 CXX="$pgac_save_CXX"
6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&5
6366 $as_echo "$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" >&6; }
6367 if test x"$pgac_cv_prog_CXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6368 CXXFLAGS="${CXXFLAGS} -fno-strict-aliasing"
6372 elif test "$PORTNAME" = "aix"; then
6373 # AIX's xlc has to have strict aliasing turned off too
6375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qnoansialias, for CFLAGS" >&5
6376 $as_echo_n "checking whether ${CC} supports -qnoansialias, for CFLAGS... " >&6; }
6377 if ${pgac_cv_prog_CC_cflags__qnoansialias+:} false; then :
6378 $as_echo_n "(cached) " >&6
6380 pgac_save_CFLAGS=$CFLAGS
6383 CFLAGS="${CFLAGS} -qnoansialias"
6384 ac_save_c_werror_flag=$ac_c_werror_flag
6385 ac_c_werror_flag=yes
6386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6387 /* end confdefs.h. */
6397 if ac_fn_c_try_compile "$LINENO"; then :
6398 pgac_cv_prog_CC_cflags__qnoansialias=yes
6400 pgac_cv_prog_CC_cflags__qnoansialias=no
6402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6403 ac_c_werror_flag=$ac_save_c_werror_flag
6404 CFLAGS="$pgac_save_CFLAGS"
6407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qnoansialias" >&5
6408 $as_echo "$pgac_cv_prog_CC_cflags__qnoansialias" >&6; }
6409 if test x"$pgac_cv_prog_CC_cflags__qnoansialias" = x"yes"; then
6410 CFLAGS="${CFLAGS} -qnoansialias"
6414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qnoansialias, for CXXFLAGS" >&5
6415 $as_echo_n "checking whether ${CXX} supports -qnoansialias, for CXXFLAGS... " >&6; }
6416 if ${pgac_cv_prog_CXX_cxxflags__qnoansialias+:} false; then :
6417 $as_echo_n "(cached) " >&6
6419 pgac_save_CXXFLAGS=$CXXFLAGS
6422 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6423 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6424 ac_cxx_werror_flag=yes
6426 ac_cpp='$CXXCPP $CPPFLAGS'
6427 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6428 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6429 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6432 /* end confdefs.h. */
6442 if ac_fn_cxx_try_compile "$LINENO"; then :
6443 pgac_cv_prog_CXX_cxxflags__qnoansialias=yes
6445 pgac_cv_prog_CXX_cxxflags__qnoansialias=no
6447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6449 ac_cpp='$CPP $CPPFLAGS'
6450 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6451 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6452 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6454 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6455 CXXFLAGS="$pgac_save_CXXFLAGS"
6456 CXX="$pgac_save_CXX"
6458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qnoansialias" >&5
6459 $as_echo "$pgac_cv_prog_CXX_cxxflags__qnoansialias" >&6; }
6460 if test x"$pgac_cv_prog_CXX_cxxflags__qnoansialias" = x"yes"; then
6461 CXXFLAGS="${CXXFLAGS} -qnoansialias"
6466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports -qlonglong, for CFLAGS" >&5
6467 $as_echo_n "checking whether ${CC} supports -qlonglong, for CFLAGS... " >&6; }
6468 if ${pgac_cv_prog_CC_cflags__qlonglong+:} false; then :
6469 $as_echo_n "(cached) " >&6
6471 pgac_save_CFLAGS=$CFLAGS
6474 CFLAGS="${CFLAGS} -qlonglong"
6475 ac_save_c_werror_flag=$ac_c_werror_flag
6476 ac_c_werror_flag=yes
6477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6478 /* end confdefs.h. */
6488 if ac_fn_c_try_compile "$LINENO"; then :
6489 pgac_cv_prog_CC_cflags__qlonglong=yes
6491 pgac_cv_prog_CC_cflags__qlonglong=no
6493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6494 ac_c_werror_flag=$ac_save_c_werror_flag
6495 CFLAGS="$pgac_save_CFLAGS"
6498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags__qlonglong" >&5
6499 $as_echo "$pgac_cv_prog_CC_cflags__qlonglong" >&6; }
6500 if test x"$pgac_cv_prog_CC_cflags__qlonglong" = x"yes"; then
6501 CFLAGS="${CFLAGS} -qlonglong"
6505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports -qlonglong, for CXXFLAGS" >&5
6506 $as_echo_n "checking whether ${CXX} supports -qlonglong, for CXXFLAGS... " >&6; }
6507 if ${pgac_cv_prog_CXX_cxxflags__qlonglong+:} false; then :
6508 $as_echo_n "(cached) " >&6
6510 pgac_save_CXXFLAGS=$CXXFLAGS
6513 CXXFLAGS="${CXXFLAGS} -qlonglong"
6514 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6515 ac_cxx_werror_flag=yes
6517 ac_cpp='$CXXCPP $CPPFLAGS'
6518 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6519 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6520 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6523 /* end confdefs.h. */
6533 if ac_fn_cxx_try_compile "$LINENO"; then :
6534 pgac_cv_prog_CXX_cxxflags__qlonglong=yes
6536 pgac_cv_prog_CXX_cxxflags__qlonglong=no
6538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6540 ac_cpp='$CPP $CPPFLAGS'
6541 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6542 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6543 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6545 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6546 CXXFLAGS="$pgac_save_CXXFLAGS"
6547 CXX="$pgac_save_CXX"
6549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags__qlonglong" >&5
6550 $as_echo "$pgac_cv_prog_CXX_cxxflags__qlonglong" >&6; }
6551 if test x"$pgac_cv_prog_CXX_cxxflags__qlonglong" = x"yes"; then
6552 CXXFLAGS="${CXXFLAGS} -qlonglong"
6556 elif test "$PORTNAME" = "hpux"; then
6557 # On some versions of HP-UX, libm functions do not set errno by default.
6558 # Fix that by using +Olibmerrno if the compiler recognizes it.
6560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CC} supports +Olibmerrno, for CFLAGS" >&5
6561 $as_echo_n "checking whether ${CC} supports +Olibmerrno, for CFLAGS... " >&6; }
6562 if ${pgac_cv_prog_CC_cflags_pOlibmerrno+:} false; then :
6563 $as_echo_n "(cached) " >&6
6565 pgac_save_CFLAGS=$CFLAGS
6568 CFLAGS="${CFLAGS} +Olibmerrno"
6569 ac_save_c_werror_flag=$ac_c_werror_flag
6570 ac_c_werror_flag=yes
6571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6572 /* end confdefs.h. */
6582 if ac_fn_c_try_compile "$LINENO"; then :
6583 pgac_cv_prog_CC_cflags_pOlibmerrno=yes
6585 pgac_cv_prog_CC_cflags_pOlibmerrno=no
6587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6588 ac_c_werror_flag=$ac_save_c_werror_flag
6589 CFLAGS="$pgac_save_CFLAGS"
6592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CC_cflags_pOlibmerrno" >&5
6593 $as_echo "$pgac_cv_prog_CC_cflags_pOlibmerrno" >&6; }
6594 if test x"$pgac_cv_prog_CC_cflags_pOlibmerrno" = x"yes"; then
6595 CFLAGS="${CFLAGS} +Olibmerrno"
6599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS" >&5
6600 $as_echo_n "checking whether ${CXX} supports +Olibmerrno, for CXXFLAGS... " >&6; }
6601 if ${pgac_cv_prog_CXX_cxxflags_pOlibmerrno+:} false; then :
6602 $as_echo_n "(cached) " >&6
6604 pgac_save_CXXFLAGS=$CXXFLAGS
6607 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6608 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6609 ac_cxx_werror_flag=yes
6611 ac_cpp='$CXXCPP $CPPFLAGS'
6612 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6613 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6614 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6617 /* end confdefs.h. */
6627 if ac_fn_cxx_try_compile "$LINENO"; then :
6628 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=yes
6630 pgac_cv_prog_CXX_cxxflags_pOlibmerrno=no
6632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6634 ac_cpp='$CPP $CPPFLAGS'
6635 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6636 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6637 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6639 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6640 CXXFLAGS="$pgac_save_CXXFLAGS"
6641 CXX="$pgac_save_CXX"
6643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&5
6644 $as_echo "$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" >&6; }
6645 if test x"$pgac_cv_prog_CXX_cxxflags_pOlibmerrno" = x"yes"; then
6646 CXXFLAGS="${CXXFLAGS} +Olibmerrno"
6652 CFLAGS_VECTOR=$CFLAGS_VECTOR
6655 # Determine flags used to emit bitcode for JIT inlining. Need to test
6656 # for behaviour changing compiler flags, to keep compatibility with
6657 # compiler used for normal postgres code.
6658 if test "$with_llvm" = yes ; then
6659 CLANGXX="$CLANG -xc++"
6661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS" >&5
6662 $as_echo_n "checking whether ${CLANG} supports -fno-strict-aliasing, for BITCODE_CFLAGS... " >&6; }
6663 if ${pgac_cv_prog_CLANG_cflags__fno_strict_aliasing+:} false; then :
6664 $as_echo_n "(cached) " >&6
6666 pgac_save_CFLAGS=$CFLAGS
6669 CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6670 ac_save_c_werror_flag=$ac_c_werror_flag
6671 ac_c_werror_flag=yes
6672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6673 /* end confdefs.h. */
6683 if ac_fn_c_try_compile "$LINENO"; then :
6684 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=yes
6686 pgac_cv_prog_CLANG_cflags__fno_strict_aliasing=no
6688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6689 ac_c_werror_flag=$ac_save_c_werror_flag
6690 CFLAGS="$pgac_save_CFLAGS"
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&5
6694 $as_echo "$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" >&6; }
6695 if test x"$pgac_cv_prog_CLANG_cflags__fno_strict_aliasing" = x"yes"; then
6696 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fno-strict-aliasing"
6699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS" >&5
6700 $as_echo_n "checking whether ${CLANGXX} supports -fno-strict-aliasing, for BITCODE_CXXFLAGS... " >&6; }
6701 if ${pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing+:} false; then :
6702 $as_echo_n "(cached) " >&6
6704 pgac_save_CXXFLAGS=$CXXFLAGS
6707 CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6708 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6709 ac_cxx_werror_flag=yes
6711 ac_cpp='$CXXCPP $CPPFLAGS'
6712 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6713 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6714 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6717 /* end confdefs.h. */
6727 if ac_fn_cxx_try_compile "$LINENO"; then :
6728 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=yes
6730 pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing=no
6732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6734 ac_cpp='$CPP $CPPFLAGS'
6735 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6736 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6737 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6739 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6740 CXXFLAGS="$pgac_save_CXXFLAGS"
6741 CXX="$pgac_save_CXX"
6743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&5
6744 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" >&6; }
6745 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fno_strict_aliasing" = x"yes"; then
6746 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fno-strict-aliasing"
6749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS" >&5
6750 $as_echo_n "checking whether ${CLANG} supports -fwrapv, for BITCODE_CFLAGS... " >&6; }
6751 if ${pgac_cv_prog_CLANG_cflags__fwrapv+:} false; then :
6752 $as_echo_n "(cached) " >&6
6754 pgac_save_CFLAGS=$CFLAGS
6757 CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6758 ac_save_c_werror_flag=$ac_c_werror_flag
6759 ac_c_werror_flag=yes
6760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6761 /* end confdefs.h. */
6771 if ac_fn_c_try_compile "$LINENO"; then :
6772 pgac_cv_prog_CLANG_cflags__fwrapv=yes
6774 pgac_cv_prog_CLANG_cflags__fwrapv=no
6776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6777 ac_c_werror_flag=$ac_save_c_werror_flag
6778 CFLAGS="$pgac_save_CFLAGS"
6781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fwrapv" >&5
6782 $as_echo "$pgac_cv_prog_CLANG_cflags__fwrapv" >&6; }
6783 if test x"$pgac_cv_prog_CLANG_cflags__fwrapv" = x"yes"; then
6784 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fwrapv"
6787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS" >&5
6788 $as_echo_n "checking whether ${CLANGXX} supports -fwrapv, for BITCODE_CXXFLAGS... " >&6; }
6789 if ${pgac_cv_prog_CLANGXX_cxxflags__fwrapv+:} false; then :
6790 $as_echo_n "(cached) " >&6
6792 pgac_save_CXXFLAGS=$CXXFLAGS
6795 CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6796 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6797 ac_cxx_werror_flag=yes
6799 ac_cpp='$CXXCPP $CPPFLAGS'
6800 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6801 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6802 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6805 /* end confdefs.h. */
6815 if ac_fn_cxx_try_compile "$LINENO"; then :
6816 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=yes
6818 pgac_cv_prog_CLANGXX_cxxflags__fwrapv=no
6820 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6822 ac_cpp='$CPP $CPPFLAGS'
6823 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6824 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6825 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6827 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6828 CXXFLAGS="$pgac_save_CXXFLAGS"
6829 CXX="$pgac_save_CXX"
6831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&5
6832 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" >&6; }
6833 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fwrapv" = x"yes"; then
6834 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fwrapv"
6837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS" >&5
6838 $as_echo_n "checking whether ${CLANG} supports -fexcess-precision=standard, for BITCODE_CFLAGS... " >&6; }
6839 if ${pgac_cv_prog_CLANG_cflags__fexcess_precision_standard+:} false; then :
6840 $as_echo_n "(cached) " >&6
6842 pgac_save_CFLAGS=$CFLAGS
6845 CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6846 ac_save_c_werror_flag=$ac_c_werror_flag
6847 ac_c_werror_flag=yes
6848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6849 /* end confdefs.h. */
6859 if ac_fn_c_try_compile "$LINENO"; then :
6860 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=yes
6862 pgac_cv_prog_CLANG_cflags__fexcess_precision_standard=no
6864 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6865 ac_c_werror_flag=$ac_save_c_werror_flag
6866 CFLAGS="$pgac_save_CFLAGS"
6869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&5
6870 $as_echo "$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" >&6; }
6871 if test x"$pgac_cv_prog_CLANG_cflags__fexcess_precision_standard" = x"yes"; then
6872 BITCODE_CFLAGS="${BITCODE_CFLAGS} -fexcess-precision=standard"
6875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS" >&5
6876 $as_echo_n "checking whether ${CLANGXX} supports -fexcess-precision=standard, for BITCODE_CXXFLAGS... " >&6; }
6877 if ${pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard+:} false; then :
6878 $as_echo_n "(cached) " >&6
6880 pgac_save_CXXFLAGS=$CXXFLAGS
6883 CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6884 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
6885 ac_cxx_werror_flag=yes
6887 ac_cpp='$CXXCPP $CPPFLAGS'
6888 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6889 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6890 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6893 /* end confdefs.h. */
6903 if ac_fn_cxx_try_compile "$LINENO"; then :
6904 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=yes
6906 pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard=no
6908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6910 ac_cpp='$CPP $CPPFLAGS'
6911 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6912 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6913 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6915 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
6916 CXXFLAGS="$pgac_save_CXXFLAGS"
6917 CXX="$pgac_save_CXX"
6919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&5
6920 $as_echo "$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" >&6; }
6921 if test x"$pgac_cv_prog_CLANGXX_cxxflags__fexcess_precision_standard" = x"yes"; then
6922 BITCODE_CXXFLAGS="${BITCODE_CXXFLAGS} -fexcess-precision=standard"
6927 # supply -g if --enable-debug
6928 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
6932 if test "$enable_debug" = yes && test "$ac_cv_prog_cxx_g" = yes; then
6933 CXXFLAGS="$CXXFLAGS -g"
6936 # enable code coverage if --enable-coverage
6937 if test "$enable_coverage" = yes; then
6938 if test "$GCC" = yes; then
6939 CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
6940 CXXFLAGS="$CXXFLAGS -fprofile-arcs -ftest-coverage"
6942 as_fn_error $? "--enable-coverage is supported only when using GCC" "$LINENO" 5
6946 # enable profiling if --enable-profiling
6947 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
6948 if test "$GCC" = yes; then
6950 $as_echo "#define PROFILE_PID_DIR 1" >>confdefs.h
6952 CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6953 CXXFLAGS="$CXXFLAGS -pg $PLATFORM_PROFILE_FLAGS"
6955 as_fn_error $? "--enable-profiling is supported only when using GCC" "$LINENO" 5
6959 # We already have this in Makefile.win32, but configure needs it too
6960 if test "$PORTNAME" = "win32"; then
6961 CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
6964 # Now that we're done automatically adding stuff to C[XX]FLAGS, put back the
6965 # user-specified flags (if any) at the end. This lets users override
6966 # the automatic additions.
6967 CFLAGS="$CFLAGS $user_CFLAGS"
6968 CXXFLAGS="$CXXFLAGS $user_CXXFLAGS"
6969 BITCODE_CFLAGS="$BITCODE_CFLAGS $user_BITCODE_CFLAGS"
6970 BITCODE_CXXFLAGS="$BITCODE_CXXFLAGS $user_BITCODE_CXXFLAGS"
6972 BITCODE_CFLAGS=$BITCODE_CFLAGS
6974 BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS
6977 # Check if the compiler still works with the final flag settings
6978 # (note, we're not checking that for CXX, which is optional)
6979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler still works" >&5
6980 $as_echo_n "checking whether the C compiler still works... " >&6; }
6981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6982 /* end confdefs.h. */
6992 if ac_fn_c_try_link "$LINENO"; then :
6993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6994 $as_echo "yes" >&6; }
6996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6997 $as_echo "no" >&6; }
6998 as_fn_error $? "cannot proceed" "$LINENO" 5
7000 rm -f core conftest.err conftest.$ac_objext \
7001 conftest$ac_exeext conftest.$ac_ext
7003 # Defend against gcc -ffast-math
7004 if test "$GCC" = yes; then
7005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7006 /* end confdefs.h. */
7011 #ifdef __FAST_MATH__
7018 if ac_fn_c_try_compile "$LINENO"; then :
7021 as_fn_error $? "do not put -ffast-math in CFLAGS" "$LINENO" 5
7023 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7027 ac_cpp='$CPP $CPPFLAGS'
7028 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7029 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7030 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
7032 $as_echo_n "checking how to run the C preprocessor... " >&6; }
7033 # On Suns, sometimes $CPP names a directory.
7034 if test -n "$CPP" && test -d "$CPP"; then
7037 if test -z "$CPP"; then
7038 if ${ac_cv_prog_CPP+:} false; then :
7039 $as_echo_n "(cached) " >&6
7041 # Double quotes because CPP needs to be expanded
7042 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
7045 for ac_c_preproc_warn_flag in '' yes
7047 # Use a header file that comes with gcc, so configuring glibc
7048 # with a fresh cross-compiler works.
7049 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7050 # <limits.h> exists even on freestanding compilers.
7051 # On the NeXT, cc -E runs the code through the compiler's parser,
7052 # not just through cpp. "Syntax error" is here to catch this case.
7053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7054 /* end confdefs.h. */
7056 # include <limits.h>
7058 # include <assert.h>
7062 if ac_fn_c_try_cpp "$LINENO"; then :
7065 # Broken: fails on valid input.
7068 rm -f conftest.err conftest.i conftest.$ac_ext
7070 # OK, works on sane cases. Now check whether nonexistent headers
7071 # can be detected and how.
7072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7073 /* end confdefs.h. */
7074 #include <ac_nonexistent.h>
7076 if ac_fn_c_try_cpp "$LINENO"; then :
7077 # Broken: success on invalid input.
7080 # Passes both tests.
7084 rm -f conftest.err conftest.i conftest.$ac_ext
7087 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7088 rm -f conftest.i conftest.err conftest.$ac_ext
7089 if $ac_preproc_ok; then :
7101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7102 $as_echo "$CPP" >&6; }
7104 for ac_c_preproc_warn_flag in '' yes
7106 # Use a header file that comes with gcc, so configuring glibc
7107 # with a fresh cross-compiler works.
7108 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7109 # <limits.h> exists even on freestanding compilers.
7110 # On the NeXT, cc -E runs the code through the compiler's parser,
7111 # not just through cpp. "Syntax error" is here to catch this case.
7112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7113 /* end confdefs.h. */
7115 # include <limits.h>
7117 # include <assert.h>
7121 if ac_fn_c_try_cpp "$LINENO"; then :
7124 # Broken: fails on valid input.
7127 rm -f conftest.err conftest.i conftest.$ac_ext
7129 # OK, works on sane cases. Now check whether nonexistent headers
7130 # can be detected and how.
7131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7132 /* end confdefs.h. */
7133 #include <ac_nonexistent.h>
7135 if ac_fn_c_try_cpp "$LINENO"; then :
7136 # Broken: success on invalid input.
7139 # Passes both tests.
7143 rm -f conftest.err conftest.i conftest.$ac_ext
7146 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7147 rm -f conftest.i conftest.err conftest.$ac_ext
7148 if $ac_preproc_ok; then :
7151 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7152 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7153 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
7154 See \`config.log' for more details" "$LINENO" 5; }
7158 ac_cpp='$CPP $CPPFLAGS'
7159 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7160 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7161 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7167 # Set up TAS assembly code if needed; the template file has now had its
7168 # chance to request this.
7170 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
7173 if test "$need_tas" = yes ; then
7182 # Automatic dependency tracking
7186 # Check whether --enable-depend was given.
7187 if test "${enable_depend+set}" = set; then :
7188 enableval=$enable_depend;
7197 as_fn_error $? "no argument expected for --enable-depend option" "$LINENO" 5
7211 # Enable assert checks
7215 # Check whether --enable-cassert was given.
7216 if test "${enable_cassert+set}" = set; then :
7217 enableval=$enable_cassert;
7221 $as_echo "#define USE_ASSERT_CHECKING 1" >>confdefs.h
7228 as_fn_error $? "no argument expected for --enable-cassert option" "$LINENO" 5
7241 # Include directories
7244 IFS="${IFS}${PATH_SEPARATOR}"
7245 # SRCH_INC comes from the template file
7246 for dir in $with_includes $SRCH_INC; do
7247 if test -d "$dir"; then
7248 INCLUDES="$INCLUDES -I$dir"
7250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Include directory $dir does not exist." >&5
7251 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
7259 # Library directories
7262 IFS="${IFS}${PATH_SEPARATOR}"
7263 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
7264 for dir in $LIBRARY_DIRS $SRCH_LIB; do
7265 if test -d "$dir"; then
7266 LIBDIRS="$LIBDIRS -L$dir"
7268 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Library directory $dir does not exist." >&5
7269 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
7275 # Enable thread-safe client libraries
7277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking allow thread-safe client libraries" >&5
7278 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
7281 # Check whether --enable-thread-safety was given.
7282 if test "${enable_thread_safety+set}" = set; then :
7283 enableval=$enable_thread_safety;
7292 as_fn_error $? "no argument expected for --enable-thread-safety option" "$LINENO" 5
7297 enable_thread_safety=yes
7302 if test "$enable_thread_safety" = yes; then
7304 $as_echo "#define ENABLE_THREAD_SAFETY 1" >>confdefs.h
7307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_thread_safety" >&5
7308 $as_echo "$enable_thread_safety" >&6; }
7314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with ICU support" >&5
7315 $as_echo_n "checking whether to build with ICU support... " >&6; }
7319 # Check whether --with-icu was given.
7320 if test "${with_icu+set}" = set; then :
7325 $as_echo "#define USE_ICU 1" >>confdefs.h
7332 as_fn_error $? "no argument expected for --with-icu option" "$LINENO" 5
7342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_icu" >&5
7343 $as_echo "$with_icu" >&6; }
7346 if test "$with_icu" = yes; then
7354 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
7355 if test -n "$ac_tool_prefix"; then
7356 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
7357 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
7358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7359 $as_echo_n "checking for $ac_word... " >&6; }
7360 if ${ac_cv_path_PKG_CONFIG+:} false; then :
7361 $as_echo_n "(cached) " >&6
7365 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
7368 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7372 test -z "$as_dir" && as_dir=.
7373 for ac_exec_ext in '' $ac_executable_extensions; do
7374 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7375 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7376 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7386 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
7387 if test -n "$PKG_CONFIG"; then
7388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
7389 $as_echo "$PKG_CONFIG" >&6; }
7391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7392 $as_echo "no" >&6; }
7397 if test -z "$ac_cv_path_PKG_CONFIG"; then
7398 ac_pt_PKG_CONFIG=$PKG_CONFIG
7399 # Extract the first word of "pkg-config", so it can be a program name with args.
7400 set dummy pkg-config; ac_word=$2
7401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7402 $as_echo_n "checking for $ac_word... " >&6; }
7403 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
7404 $as_echo_n "(cached) " >&6
7406 case $ac_pt_PKG_CONFIG in
7408 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
7411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7415 test -z "$as_dir" && as_dir=.
7416 for ac_exec_ext in '' $ac_executable_extensions; do
7417 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7418 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7419 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7429 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
7430 if test -n "$ac_pt_PKG_CONFIG"; then
7431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
7432 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
7434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7435 $as_echo "no" >&6; }
7438 if test "x$ac_pt_PKG_CONFIG" = x; then
7441 case $cross_compiling:$ac_tool_warned in
7443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7444 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7445 ac_tool_warned=yes ;;
7447 PKG_CONFIG=$ac_pt_PKG_CONFIG
7450 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
7454 if test -n "$PKG_CONFIG"; then
7455 _pkg_min_version=0.9.0
7456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
7457 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
7458 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
7459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7460 $as_echo "yes" >&6; }
7462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7463 $as_echo "no" >&6; }
7469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icu-uc icu-i18n" >&5
7470 $as_echo_n "checking for icu-uc icu-i18n... " >&6; }
7472 if test -n "$ICU_CFLAGS"; then
7473 pkg_cv_ICU_CFLAGS="$ICU_CFLAGS"
7474 elif test -n "$PKG_CONFIG"; then
7475 if test -n "$PKG_CONFIG" && \
7476 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7477 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7479 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7480 test $ac_status = 0; }; then
7481 pkg_cv_ICU_CFLAGS=`$PKG_CONFIG --cflags "icu-uc icu-i18n" 2>/dev/null`
7482 test "x$?" != "x0" && pkg_failed=yes
7489 if test -n "$ICU_LIBS"; then
7490 pkg_cv_ICU_LIBS="$ICU_LIBS"
7491 elif test -n "$PKG_CONFIG"; then
7492 if test -n "$PKG_CONFIG" && \
7493 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-uc icu-i18n\""; } >&5
7494 ($PKG_CONFIG --exists --print-errors "icu-uc icu-i18n") 2>&5
7496 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7497 test $ac_status = 0; }; then
7498 pkg_cv_ICU_LIBS=`$PKG_CONFIG --libs "icu-uc icu-i18n" 2>/dev/null`
7499 test "x$?" != "x0" && pkg_failed=yes
7509 if test $pkg_failed = yes; then
7510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7511 $as_echo "no" >&6; }
7513 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
7514 _pkg_short_errors_supported=yes
7516 _pkg_short_errors_supported=no
7518 if test $_pkg_short_errors_supported = yes; then
7519 ICU_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7521 ICU_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "icu-uc icu-i18n" 2>&1`
7523 # Put the nasty error message in config.log where it belongs
7524 echo "$ICU_PKG_ERRORS" >&5
7526 as_fn_error $? "Package requirements (icu-uc icu-i18n) were not met:
7530 Consider adjusting the PKG_CONFIG_PATH environment variable if you
7531 installed software in a non-standard prefix.
7533 Alternatively, you may set the environment variables ICU_CFLAGS
7534 and ICU_LIBS to avoid the need to call pkg-config.
7535 See the pkg-config man page for more details." "$LINENO" 5
7536 elif test $pkg_failed = untried; then
7537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7538 $as_echo "no" >&6; }
7539 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7540 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7541 as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
7542 is in your PATH or set the PKG_CONFIG environment variable to the full
7545 Alternatively, you may set the environment variables ICU_CFLAGS
7546 and ICU_LIBS to avoid the need to call pkg-config.
7547 See the pkg-config man page for more details.
7549 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
7550 See \`config.log' for more details" "$LINENO" 5; }
7552 ICU_CFLAGS=$pkg_cv_ICU_CFLAGS
7553 ICU_LIBS=$pkg_cv_ICU_LIBS
7554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7555 $as_echo "yes" >&6; }
7561 # Optionally build Tcl modules (PL/Tcl)
7563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Tcl" >&5
7564 $as_echo_n "checking whether to build with Tcl... " >&6; }
7568 # Check whether --with-tcl was given.
7569 if test "${with_tcl+set}" = set; then :
7579 as_fn_error $? "no argument expected for --with-tcl option" "$LINENO" 5
7589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_tcl" >&5
7590 $as_echo "$with_tcl" >&6; }
7593 # We see if the path to the Tcl/Tk configuration scripts is specified.
7594 # This will override the use of tclsh to find the paths to search.
7599 # Check whether --with-tclconfig was given.
7600 if test "${with_tclconfig+set}" = set; then :
7601 withval=$with_tclconfig;
7604 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7607 as_fn_error $? "argument required for --with-tclconfig option" "$LINENO" 5
7619 # Optionally build Perl modules (PL/Perl)
7621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Perl modules" >&5
7622 $as_echo_n "checking whether to build Perl modules... " >&6; }
7626 # Check whether --with-perl was given.
7627 if test "${with_perl+set}" = set; then :
7637 as_fn_error $? "no argument expected for --with-perl option" "$LINENO" 5
7647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_perl" >&5
7648 $as_echo "$with_perl" >&6; }
7652 # Optionally build Python modules (PL/Python)
7654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build Python modules" >&5
7655 $as_echo_n "checking whether to build Python modules... " >&6; }
7659 # Check whether --with-python was given.
7660 if test "${with_python+set}" = set; then :
7661 withval=$with_python;
7670 as_fn_error $? "no argument expected for --with-python option" "$LINENO" 5
7680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_python" >&5
7681 $as_echo "$with_python" >&6; }
7687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with GSSAPI support" >&5
7688 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
7692 # Check whether --with-gssapi was given.
7693 if test "${with_gssapi+set}" = set; then :
7694 withval=$with_gssapi;
7699 $as_echo "#define ENABLE_GSS 1" >>confdefs.h
7701 krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
7708 as_fn_error $? "no argument expected for --with-gssapi option" "$LINENO" 5
7718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_gssapi" >&5
7719 $as_echo "$with_gssapi" >&6; }
7727 # Kerberos configuration parameters
7732 # Check whether --with-krb-srvnam was given.
7733 if test "${with_krb_srvnam+set}" = set; then :
7734 withval=$with_krb_srvnam;
7737 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7740 as_fn_error $? "argument required for --with-krb-srvnam option" "$LINENO" 5
7748 with_krb_srvnam="postgres"
7754 cat >>confdefs.h <<_ACEOF
7755 #define PG_KRB_SRVNAM "$with_krb_srvnam"
7763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with PAM support" >&5
7764 $as_echo_n "checking whether to build with PAM support... " >&6; }
7768 # Check whether --with-pam was given.
7769 if test "${with_pam+set}" = set; then :
7774 $as_echo "#define USE_PAM 1" >>confdefs.h
7781 as_fn_error $? "no argument expected for --with-pam option" "$LINENO" 5
7791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_pam" >&5
7792 $as_echo "$with_pam" >&6; }
7798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with BSD Authentication support" >&5
7799 $as_echo_n "checking whether to build with BSD Authentication support... " >&6; }
7803 # Check whether --with-bsd-auth was given.
7804 if test "${with_bsd_auth+set}" = set; then :
7805 withval=$with_bsd_auth;
7809 $as_echo "#define USE_BSD_AUTH 1" >>confdefs.h
7816 as_fn_error $? "no argument expected for --with-bsd-auth option" "$LINENO" 5
7826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bsd_auth" >&5
7827 $as_echo "$with_bsd_auth" >&6; }
7833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with LDAP support" >&5
7834 $as_echo_n "checking whether to build with LDAP support... " >&6; }
7838 # Check whether --with-ldap was given.
7839 if test "${with_ldap+set}" = set; then :
7844 $as_echo "#define USE_LDAP 1" >>confdefs.h
7851 as_fn_error $? "no argument expected for --with-ldap option" "$LINENO" 5
7861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_ldap" >&5
7862 $as_echo "$with_ldap" >&6; }
7869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with Bonjour support" >&5
7870 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
7874 # Check whether --with-bonjour was given.
7875 if test "${with_bonjour+set}" = set; then :
7876 withval=$with_bonjour;
7880 $as_echo "#define USE_BONJOUR 1" >>confdefs.h
7887 as_fn_error $? "no argument expected for --with-bonjour option" "$LINENO" 5
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_bonjour" >&5
7898 $as_echo "$with_bonjour" >&6; }
7904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with OpenSSL support" >&5
7905 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
7909 # Check whether --with-openssl was given.
7910 if test "${with_openssl+set}" = set; then :
7911 withval=$with_openssl;
7915 $as_echo "#define USE_OPENSSL 1" >>confdefs.h
7922 as_fn_error $? "no argument expected for --with-openssl option" "$LINENO" 5
7932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_openssl" >&5
7933 $as_echo "$with_openssl" >&6; }
7939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with SELinux support" >&5
7940 $as_echo_n "checking whether to build with SELinux support... " >&6; }
7944 # Check whether --with-selinux was given.
7945 if test "${with_selinux+set}" = set; then :
7946 withval=$with_selinux;
7955 as_fn_error $? "no argument expected for --with-selinux option" "$LINENO" 5
7966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_selinux" >&5
7967 $as_echo "$with_selinux" >&6; }
7972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with systemd support" >&5
7973 $as_echo_n "checking whether to build with systemd support... " >&6; }
7977 # Check whether --with-systemd was given.
7978 if test "${with_systemd+set}" = set; then :
7979 withval=$with_systemd;
7983 $as_echo "#define USE_SYSTEMD 1" >>confdefs.h
7990 as_fn_error $? "no argument expected for --with-systemd option" "$LINENO" 5
8001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_systemd" >&5
8002 $as_echo "$with_systemd" >&6; }
8010 # Check whether --with-readline was given.
8011 if test "${with_readline+set}" = set; then :
8012 withval=$with_readline;
8021 as_fn_error $? "no argument expected for --with-readline option" "$LINENO" 5
8031 # readline on MinGW has problems with backslashes in psql and other bugs.
8032 # This is particularly a problem with non-US code pages.
8033 # Therefore disable its use until we understand the cause. 2004-07-20
8034 if test "$PORTNAME" = "win32"; then
8035 if test "$with_readline" = yes; then
8036 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Readline does not work on MinGW --- disabling" >&5
8037 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
8049 # Check whether --with-libedit-preferred was given.
8050 if test "${with_libedit_preferred+set}" = set; then :
8051 withval=$with_libedit_preferred;
8060 as_fn_error $? "no argument expected for --with-libedit-preferred option" "$LINENO" 5
8065 with_libedit_preferred=no
8075 # There are at least three UUID libraries in common use: the FreeBSD/NetBSD
8076 # library, the e2fsprogs libuuid (now part of util-linux-ng), and the OSSP
8077 # UUID library. More than one of these might be present on a given platform,
8078 # so we make the user say which one she wants.
8083 # Check whether --with-uuid was given.
8084 if test "${with_uuid+set}" = set; then :
8088 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
8091 as_fn_error $? "argument required for --with-uuid option" "$LINENO" 5
8101 if test x"$with_uuid" = x"" ; then
8107 # Check whether --with-ossp-uuid was given.
8108 if test "${with_ossp_uuid+set}" = set; then :
8109 withval=$with_ossp_uuid;
8118 as_fn_error $? "no argument expected for --with-ossp-uuid option" "$LINENO" 5
8128 if test "$with_ossp_uuid" = yes ; then
8132 if test "$with_uuid" = bsd ; then
8134 $as_echo "#define HAVE_UUID_BSD 1" >>confdefs.h
8136 UUID_EXTRA_OBJS="md5.o sha1.o"
8137 elif test "$with_uuid" = e2fs ; then
8139 $as_echo "#define HAVE_UUID_E2FS 1" >>confdefs.h
8141 UUID_EXTRA_OBJS="md5.o sha1.o"
8142 elif test "$with_uuid" = ossp ; then
8144 $as_echo "#define HAVE_UUID_OSSP 1" >>confdefs.h
8147 elif test "$with_uuid" = no ; then
8150 as_fn_error $? "--with-uuid must specify one of bsd, e2fs, or ossp" "$LINENO" 5
8162 # Check whether --with-libxml was given.
8163 if test "${with_libxml+set}" = set; then :
8164 withval=$with_libxml;
8168 $as_echo "#define USE_LIBXML 1" >>confdefs.h
8175 as_fn_error $? "no argument expected for --with-libxml option" "$LINENO" 5
8186 if test "$with_libxml" = yes ; then
8187 if test -z "$XML2_CONFIG"; then
8188 for ac_prog in xml2-config
8190 # Extract the first word of "$ac_prog", so it can be a program name with args.
8191 set dummy $ac_prog; ac_word=$2
8192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8193 $as_echo_n "checking for $ac_word... " >&6; }
8194 if ${ac_cv_path_XML2_CONFIG+:} false; then :
8195 $as_echo_n "(cached) " >&6
8197 case $XML2_CONFIG in
8199 ac_cv_path_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test with a path.
8202 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8206 test -z "$as_dir" && as_dir=.
8207 for ac_exec_ext in '' $ac_executable_extensions; do
8208 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8209 ac_cv_path_XML2_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8210 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8220 XML2_CONFIG=$ac_cv_path_XML2_CONFIG
8221 if test -n "$XML2_CONFIG"; then
8222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
8223 $as_echo "$XML2_CONFIG" >&6; }
8225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8226 $as_echo "no" >&6; }
8230 test -n "$XML2_CONFIG" && break
8234 # Report the value of XML2_CONFIG in configure's output in all cases.
8235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML2_CONFIG" >&5
8236 $as_echo_n "checking for XML2_CONFIG... " >&6; }
8237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XML2_CONFIG" >&5
8238 $as_echo "$XML2_CONFIG" >&6; }
8241 if test -n "$XML2_CONFIG"; then
8242 for pgac_option in `$XML2_CONFIG --cflags`; do
8243 case $pgac_option in
8244 -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
8247 for pgac_option in `$XML2_CONFIG --libs`; do
8248 case $pgac_option in
8249 -L*) LDFLAGS="$LDFLAGS $pgac_option";;
8263 # Check whether --with-libxslt was given.
8264 if test "${with_libxslt+set}" = set; then :
8265 withval=$with_libxslt;
8269 $as_echo "#define USE_LIBXSLT 1" >>confdefs.h
8276 as_fn_error $? "no argument expected for --with-libxslt option" "$LINENO" 5
8296 # Check whether --with-system-tzdata was given.
8297 if test "${with_system_tzdata+set}" = set; then :
8298 withval=$with_system_tzdata;
8301 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8304 as_fn_error $? "argument required for --with-system-tzdata option" "$LINENO" 5
8322 # Check whether --with-zlib was given.
8323 if test "${with_zlib+set}" = set; then :
8333 as_fn_error $? "no argument expected for --with-zlib option" "$LINENO" 5
8349 # Assume system is ELF if it predefines __ELF__ as 1,
8350 # otherwise believe host_os based default.
8352 freebsd1*|freebsd2*) elf=no;;
8353 freebsd3*|freebsd4*) elf=yes;;
8357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
8358 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
8359 if ${ac_cv_path_GREP+:} false; then :
8360 $as_echo_n "(cached) " >&6
8362 if test -z "$GREP"; then
8363 ac_path_GREP_found=false
8364 # Loop through the user's path and test for each of PROGNAME-LIST
8365 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8366 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8369 test -z "$as_dir" && as_dir=.
8370 for ac_prog in grep ggrep; do
8371 for ac_exec_ext in '' $ac_executable_extensions; do
8372 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
8373 as_fn_executable_p "$ac_path_GREP" || continue
8374 # Check for GNU ac_path_GREP and select it if it is found.
8375 # Check for GNU $ac_path_GREP
8376 case `"$ac_path_GREP" --version 2>&1` in
8378 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
8381 $as_echo_n 0123456789 >"conftest.in"
8384 cat "conftest.in" "conftest.in" >"conftest.tmp"
8385 mv "conftest.tmp" "conftest.in"
8386 cp "conftest.in" "conftest.nl"
8387 $as_echo 'GREP' >> "conftest.nl"
8388 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8389 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8390 as_fn_arith $ac_count + 1 && ac_count=$as_val
8391 if test $ac_count -gt ${ac_path_GREP_max-0}; then
8392 # Best one so far, save it but keep looking for a better one
8393 ac_cv_path_GREP="$ac_path_GREP"
8394 ac_path_GREP_max=$ac_count
8396 # 10*(2^10) chars as input seems more than enough
8397 test $ac_count -gt 10 && break
8399 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8402 $ac_path_GREP_found && break 3
8407 if test -z "$ac_cv_path_GREP"; then
8408 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8411 ac_cv_path_GREP=$GREP
8415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
8416 $as_echo "$ac_cv_path_GREP" >&6; }
8417 GREP="$ac_cv_path_GREP"
8420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
8421 $as_echo_n "checking for egrep... " >&6; }
8422 if ${ac_cv_path_EGREP+:} false; then :
8423 $as_echo_n "(cached) " >&6
8425 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
8426 then ac_cv_path_EGREP="$GREP -E"
8428 if test -z "$EGREP"; then
8429 ac_path_EGREP_found=false
8430 # Loop through the user's path and test for each of PROGNAME-LIST
8431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8432 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8435 test -z "$as_dir" && as_dir=.
8436 for ac_prog in egrep; do
8437 for ac_exec_ext in '' $ac_executable_extensions; do
8438 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
8439 as_fn_executable_p "$ac_path_EGREP" || continue
8440 # Check for GNU ac_path_EGREP and select it if it is found.
8441 # Check for GNU $ac_path_EGREP
8442 case `"$ac_path_EGREP" --version 2>&1` in
8444 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
8447 $as_echo_n 0123456789 >"conftest.in"
8450 cat "conftest.in" "conftest.in" >"conftest.tmp"
8451 mv "conftest.tmp" "conftest.in"
8452 cp "conftest.in" "conftest.nl"
8453 $as_echo 'EGREP' >> "conftest.nl"
8454 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8455 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8456 as_fn_arith $ac_count + 1 && ac_count=$as_val
8457 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
8458 # Best one so far, save it but keep looking for a better one
8459 ac_cv_path_EGREP="$ac_path_EGREP"
8460 ac_path_EGREP_max=$ac_count
8462 # 10*(2^10) chars as input seems more than enough
8463 test $ac_count -gt 10 && break
8465 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8468 $ac_path_EGREP_found && break 3
8473 if test -z "$ac_cv_path_EGREP"; then
8474 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8477 ac_cv_path_EGREP=$EGREP
8482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
8483 $as_echo "$ac_cv_path_EGREP" >&6; }
8484 EGREP="$ac_cv_path_EGREP"
8487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8488 /* end confdefs.h. */
8494 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8495 $EGREP "yes" >/dev/null 2>&1; then :
8498 if test "X$elf" = "Xyes" ; then
8512 CPPFLAGS="$CPPFLAGS $INCLUDES"
8513 LDFLAGS="$LDFLAGS $LIBDIRS"
8519 # Check whether --with-gnu-ld was given.
8520 if test "${with_gnu_ld+set}" = set; then :
8521 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8527 if test "$GCC" = yes; then
8528 # Check if gcc -print-prog-name=ld gives a path.
8529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
8530 $as_echo_n "checking for ld used by GCC... " >&6; }
8533 # gcc leaves a trailing carriage return which upsets mingw
8534 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8536 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8539 # Accept absolute paths.
8540 [\\/]* | [A-Za-z]:[\\/]*)
8541 re_direlt='/[^/][^/]*/\.\./'
8542 # Canonicalize the path of ld
8543 ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
8544 while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
8545 ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
8547 test -z "$LD" && LD="$ac_prog"
8550 # If it fails, then pretend we aren't using GCC.
8554 # If it is relative, then search for the first ld in PATH.
8558 elif test "$with_gnu_ld" = yes; then
8559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8560 $as_echo_n "checking for GNU ld... " >&6; }
8562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8563 $as_echo_n "checking for non-GNU ld... " >&6; }
8565 if ${ac_cv_path_LD+:} false; then :
8566 $as_echo_n "(cached) " >&6
8568 if test -z "$LD"; then
8569 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
8570 for ac_dir in $PATH; do
8571 test -z "$ac_dir" && ac_dir=.
8572 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8573 ac_cv_path_LD="$ac_dir/$ac_prog"
8574 # Check to see if the program is GNU ld. I'd rather use --version,
8575 # but apparently some GNU ld's only accept -v.
8576 # Break only if it was the GNU/non-GNU ld that we prefer.
8577 if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
8578 test "$with_gnu_ld" != no && break
8580 test "$with_gnu_ld" != yes && break
8586 ac_cv_path_LD="$LD" # Let the user override the test with a path.
8591 if test -n "$LD"; then
8592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8593 $as_echo "$LD" >&6; }
8595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8596 $as_echo "no" >&6; }
8598 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8600 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8601 if ${ac_cv_prog_gnu_ld+:} false; then :
8602 $as_echo_n "(cached) " >&6
8604 # I'd rather use --version here, but apparently some GNU ld's only accept -v.
8605 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
8606 ac_cv_prog_gnu_ld=yes
8608 ac_cv_prog_gnu_ld=no
8611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gnu_ld" >&5
8612 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
8613 with_gnu_ld=$ac_cv_prog_gnu_ld
8618 if test -n "$ac_tool_prefix"; then
8619 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8620 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8622 $as_echo_n "checking for $ac_word... " >&6; }
8623 if ${ac_cv_prog_RANLIB+:} false; then :
8624 $as_echo_n "(cached) " >&6
8626 if test -n "$RANLIB"; then
8627 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8633 test -z "$as_dir" && as_dir=.
8634 for ac_exec_ext in '' $ac_executable_extensions; do
8635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8636 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8646 RANLIB=$ac_cv_prog_RANLIB
8647 if test -n "$RANLIB"; then
8648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8649 $as_echo "$RANLIB" >&6; }
8651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8652 $as_echo "no" >&6; }
8657 if test -z "$ac_cv_prog_RANLIB"; then
8658 ac_ct_RANLIB=$RANLIB
8659 # Extract the first word of "ranlib", so it can be a program name with args.
8660 set dummy ranlib; ac_word=$2
8661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8662 $as_echo_n "checking for $ac_word... " >&6; }
8663 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8664 $as_echo_n "(cached) " >&6
8666 if test -n "$ac_ct_RANLIB"; then
8667 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8673 test -z "$as_dir" && as_dir=.
8674 for ac_exec_ext in '' $ac_executable_extensions; do
8675 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8676 ac_cv_prog_ac_ct_RANLIB="ranlib"
8677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8686 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8687 if test -n "$ac_ct_RANLIB"; then
8688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8689 $as_echo "$ac_ct_RANLIB" >&6; }
8691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8692 $as_echo "no" >&6; }
8695 if test "x$ac_ct_RANLIB" = x; then
8698 case $cross_compiling:$ac_tool_warned in
8700 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8701 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8702 ac_tool_warned=yes ;;
8704 RANLIB=$ac_ct_RANLIB
8707 RANLIB="$ac_cv_prog_RANLIB"
8711 if test -n "$ac_tool_prefix"; then
8712 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8713 set dummy ${ac_tool_prefix}strip; ac_word=$2
8714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8715 $as_echo_n "checking for $ac_word... " >&6; }
8716 if ${ac_cv_prog_STRIP+:} false; then :
8717 $as_echo_n "(cached) " >&6
8719 if test -n "$STRIP"; then
8720 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8722 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8726 test -z "$as_dir" && as_dir=.
8727 for ac_exec_ext in '' $ac_executable_extensions; do
8728 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8729 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8730 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8739 STRIP=$ac_cv_prog_STRIP
8740 if test -n "$STRIP"; then
8741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8742 $as_echo "$STRIP" >&6; }
8744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8745 $as_echo "no" >&6; }
8750 if test -z "$ac_cv_prog_STRIP"; then
8752 # Extract the first word of "strip", so it can be a program name with args.
8753 set dummy strip; ac_word=$2
8754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8755 $as_echo_n "checking for $ac_word... " >&6; }
8756 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8757 $as_echo_n "(cached) " >&6
8759 if test -n "$ac_ct_STRIP"; then
8760 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8762 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8766 test -z "$as_dir" && as_dir=.
8767 for ac_exec_ext in '' $ac_executable_extensions; do
8768 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8769 ac_cv_prog_ac_ct_STRIP="strip"
8770 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8779 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8780 if test -n "$ac_ct_STRIP"; then
8781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8782 $as_echo "$ac_ct_STRIP" >&6; }
8784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8785 $as_echo "no" >&6; }
8788 if test "x$ac_ct_STRIP" = x; then
8791 case $cross_compiling:$ac_tool_warned in
8793 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8794 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8795 ac_tool_warned=yes ;;
8800 STRIP="$ac_cv_prog_STRIP"
8804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is possible to strip libraries" >&5
8805 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
8806 if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
8807 STRIP_STATIC_LIB="$STRIP -x"
8808 STRIP_SHARED_LIB="$STRIP --strip-unneeded"
8809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8810 $as_echo "yes" >&6; }
8815 STRIP_STATIC_LIB=$STRIP
8816 STRIP_SHARED_LIB=$STRIP
8817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8818 $as_echo "yes" >&6; }
8823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8824 $as_echo "no" >&6; }
8831 if test -n "$ac_tool_prefix"; then
8832 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
8833 set dummy ${ac_tool_prefix}ar; ac_word=$2
8834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8835 $as_echo_n "checking for $ac_word... " >&6; }
8836 if ${ac_cv_prog_AR+:} false; then :
8837 $as_echo_n "(cached) " >&6
8839 if test -n "$AR"; then
8840 ac_cv_prog_AR="$AR" # Let the user override the test.
8842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8846 test -z "$as_dir" && as_dir=.
8847 for ac_exec_ext in '' $ac_executable_extensions; do
8848 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8849 ac_cv_prog_AR="${ac_tool_prefix}ar"
8850 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8860 if test -n "$AR"; then
8861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8862 $as_echo "$AR" >&6; }
8864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8865 $as_echo "no" >&6; }
8870 if test -z "$ac_cv_prog_AR"; then
8872 # Extract the first word of "ar", so it can be a program name with args.
8873 set dummy ar; ac_word=$2
8874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8875 $as_echo_n "checking for $ac_word... " >&6; }
8876 if ${ac_cv_prog_ac_ct_AR+:} false; then :
8877 $as_echo_n "(cached) " >&6
8879 if test -n "$ac_ct_AR"; then
8880 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8882 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8886 test -z "$as_dir" && as_dir=.
8887 for ac_exec_ext in '' $ac_executable_extensions; do
8888 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8889 ac_cv_prog_ac_ct_AR="ar"
8890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8899 ac_ct_AR=$ac_cv_prog_ac_ct_AR
8900 if test -n "$ac_ct_AR"; then
8901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8902 $as_echo "$ac_ct_AR" >&6; }
8904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8905 $as_echo "no" >&6; }
8908 if test "x$ac_ct_AR" = x; then
8911 case $cross_compiling:$ac_tool_warned in
8913 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8914 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8915 ac_tool_warned=yes ;;
8923 if test "$PORTNAME" = "win32"; then
8924 if test -n "$ac_tool_prefix"; then
8925 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8926 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8928 $as_echo_n "checking for $ac_word... " >&6; }
8929 if ${ac_cv_prog_DLLTOOL+:} false; then :
8930 $as_echo_n "(cached) " >&6
8932 if test -n "$DLLTOOL"; then
8933 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8939 test -z "$as_dir" && as_dir=.
8940 for ac_exec_ext in '' $ac_executable_extensions; do
8941 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8942 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8952 DLLTOOL=$ac_cv_prog_DLLTOOL
8953 if test -n "$DLLTOOL"; then
8954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8955 $as_echo "$DLLTOOL" >&6; }
8957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8958 $as_echo "no" >&6; }
8963 if test -z "$ac_cv_prog_DLLTOOL"; then
8964 ac_ct_DLLTOOL=$DLLTOOL
8965 # Extract the first word of "dlltool", so it can be a program name with args.
8966 set dummy dlltool; ac_word=$2
8967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8968 $as_echo_n "checking for $ac_word... " >&6; }
8969 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8970 $as_echo_n "(cached) " >&6
8972 if test -n "$ac_ct_DLLTOOL"; then
8973 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8979 test -z "$as_dir" && as_dir=.
8980 for ac_exec_ext in '' $ac_executable_extensions; do
8981 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8982 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8983 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8992 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8993 if test -n "$ac_ct_DLLTOOL"; then
8994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8995 $as_echo "$ac_ct_DLLTOOL" >&6; }
8997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8998 $as_echo "no" >&6; }
9001 if test "x$ac_ct_DLLTOOL" = x; then
9004 case $cross_compiling:$ac_tool_warned in
9006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9007 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9008 ac_tool_warned=yes ;;
9010 DLLTOOL=$ac_ct_DLLTOOL
9013 DLLTOOL="$ac_cv_prog_DLLTOOL"
9016 if test -n "$ac_tool_prefix"; then
9017 # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
9018 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
9019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9020 $as_echo_n "checking for $ac_word... " >&6; }
9021 if ${ac_cv_prog_DLLWRAP+:} false; then :
9022 $as_echo_n "(cached) " >&6
9024 if test -n "$DLLWRAP"; then
9025 ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
9027 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9031 test -z "$as_dir" && as_dir=.
9032 for ac_exec_ext in '' $ac_executable_extensions; do
9033 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9034 ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
9035 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9044 DLLWRAP=$ac_cv_prog_DLLWRAP
9045 if test -n "$DLLWRAP"; then
9046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLWRAP" >&5
9047 $as_echo "$DLLWRAP" >&6; }
9049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9050 $as_echo "no" >&6; }
9055 if test -z "$ac_cv_prog_DLLWRAP"; then
9056 ac_ct_DLLWRAP=$DLLWRAP
9057 # Extract the first word of "dllwrap", so it can be a program name with args.
9058 set dummy dllwrap; ac_word=$2
9059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9060 $as_echo_n "checking for $ac_word... " >&6; }
9061 if ${ac_cv_prog_ac_ct_DLLWRAP+:} false; then :
9062 $as_echo_n "(cached) " >&6
9064 if test -n "$ac_ct_DLLWRAP"; then
9065 ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
9067 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9071 test -z "$as_dir" && as_dir=.
9072 for ac_exec_ext in '' $ac_executable_extensions; do
9073 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9074 ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
9075 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9084 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
9085 if test -n "$ac_ct_DLLWRAP"; then
9086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLWRAP" >&5
9087 $as_echo "$ac_ct_DLLWRAP" >&6; }
9089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9090 $as_echo "no" >&6; }
9093 if test "x$ac_ct_DLLWRAP" = x; then
9096 case $cross_compiling:$ac_tool_warned in
9098 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9099 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9100 ac_tool_warned=yes ;;
9102 DLLWRAP=$ac_ct_DLLWRAP
9105 DLLWRAP="$ac_cv_prog_DLLWRAP"
9108 if test -n "$ac_tool_prefix"; then
9109 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
9110 set dummy ${ac_tool_prefix}windres; ac_word=$2
9111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9112 $as_echo_n "checking for $ac_word... " >&6; }
9113 if ${ac_cv_prog_WINDRES+:} false; then :
9114 $as_echo_n "(cached) " >&6
9116 if test -n "$WINDRES"; then
9117 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
9119 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9123 test -z "$as_dir" && as_dir=.
9124 for ac_exec_ext in '' $ac_executable_extensions; do
9125 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9126 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
9127 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9136 WINDRES=$ac_cv_prog_WINDRES
9137 if test -n "$WINDRES"; then
9138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
9139 $as_echo "$WINDRES" >&6; }
9141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9142 $as_echo "no" >&6; }
9147 if test -z "$ac_cv_prog_WINDRES"; then
9148 ac_ct_WINDRES=$WINDRES
9149 # Extract the first word of "windres", so it can be a program name with args.
9150 set dummy windres; ac_word=$2
9151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9152 $as_echo_n "checking for $ac_word... " >&6; }
9153 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
9154 $as_echo_n "(cached) " >&6
9156 if test -n "$ac_ct_WINDRES"; then
9157 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
9159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9163 test -z "$as_dir" && as_dir=.
9164 for ac_exec_ext in '' $ac_executable_extensions; do
9165 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9166 ac_cv_prog_ac_ct_WINDRES="windres"
9167 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9176 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
9177 if test -n "$ac_ct_WINDRES"; then
9178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
9179 $as_echo "$ac_ct_WINDRES" >&6; }
9181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9182 $as_echo "no" >&6; }
9185 if test "x$ac_ct_WINDRES" = x; then
9188 case $cross_compiling:$ac_tool_warned in
9190 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9191 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9192 ac_tool_warned=yes ;;
9194 WINDRES=$ac_ct_WINDRES
9197 WINDRES="$ac_cv_prog_WINDRES"
9202 # Find a good install program. We prefer a C program (faster),
9203 # so one script is as good as another. But avoid the broken or
9204 # incompatible versions:
9205 # SysV /etc/install, /usr/sbin/install
9206 # SunOS /usr/etc/install
9207 # IRIX /sbin/install
9209 # AmigaOS /C/install, which installs bootblocks on floppy discs
9210 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
9211 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
9212 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
9213 # OS/2's system install, which has a completely different semantic
9214 # ./install, which can be erroneously created by make from ./install.sh.
9215 # Reject install programs that cannot install multiple files.
9216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
9217 $as_echo_n "checking for a BSD-compatible install... " >&6; }
9218 if test -z "$INSTALL"; then
9219 if ${ac_cv_path_install+:} false; then :
9220 $as_echo_n "(cached) " >&6
9222 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9226 test -z "$as_dir" && as_dir=.
9227 # Account for people who put trailing slashes in PATH elements.
9228 case $as_dir/ in #((
9229 ./ | .// | /[cC]/* | \
9230 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
9231 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
9234 # OSF1 and SCO ODT 3.0 have their own names for install.
9235 # Don't use installbsd from OSF since it installs stuff as root
9237 for ac_prog in ginstall scoinst install; do
9238 for ac_exec_ext in '' $ac_executable_extensions; do
9239 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
9240 if test $ac_prog = install &&
9241 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
9242 # AIX install. It has an incompatible calling convention.
9244 elif test $ac_prog = install &&
9245 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
9246 # program-specific install script used by HP pwplus--don't use.
9249 rm -rf conftest.one conftest.two conftest.dir
9250 echo one > conftest.one
9251 echo two > conftest.two
9253 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
9254 test -s conftest.one && test -s conftest.two &&
9255 test -s conftest.dir/conftest.one &&
9256 test -s conftest.dir/conftest.two
9258 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
9271 rm -rf conftest.one conftest.two conftest.dir
9274 if test "${ac_cv_path_install+set}" = set; then
9275 INSTALL=$ac_cv_path_install
9277 # As a last resort, use the slow shell script. Don't cache a
9278 # value for INSTALL within a source directory, because that will
9279 # break other packages using the cache if that directory is
9280 # removed, or if the value is a relative name.
9281 INSTALL=$ac_install_sh
9284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
9285 $as_echo "$INSTALL" >&6; }
9287 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
9288 # It thinks the first close brace ends the variable substitution.
9289 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
9291 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
9293 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
9295 # When Autoconf chooses install-sh as install program it tries to generate
9296 # a relative path to it in each makefile where it substitutes it. This clashes
9297 # with our Makefile.global concept. This workaround helps.
9299 *install-sh*) install_bin='';;
9300 *) install_bin=$INSTALL;;
9304 if test -z "$TAR"; then
9307 # Extract the first word of "$ac_prog", so it can be a program name with args.
9308 set dummy $ac_prog; ac_word=$2
9309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9310 $as_echo_n "checking for $ac_word... " >&6; }
9311 if ${ac_cv_path_TAR+:} false; then :
9312 $as_echo_n "(cached) " >&6
9316 ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9323 test -z "$as_dir" && as_dir=.
9324 for ac_exec_ext in '' $ac_executable_extensions; do
9325 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9326 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9338 if test -n "$TAR"; then
9339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9340 $as_echo "$TAR" >&6; }
9342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9343 $as_echo "no" >&6; }
9347 test -n "$TAR" && break
9351 # Report the value of TAR in configure's output in all cases.
9352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9353 $as_echo_n "checking for TAR... " >&6; }
9354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9355 $as_echo "$TAR" >&6; }
9358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
9359 $as_echo_n "checking whether ln -s works... " >&6; }
9361 if test "$LN_S" = "ln -s"; then
9362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9363 $as_echo "yes" >&6; }
9365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
9366 $as_echo "no, using $LN_S" >&6; }
9369 for ac_prog in gawk mawk nawk awk
9371 # Extract the first word of "$ac_prog", so it can be a program name with args.
9372 set dummy $ac_prog; ac_word=$2
9373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9374 $as_echo_n "checking for $ac_word... " >&6; }
9375 if ${ac_cv_prog_AWK+:} false; then :
9376 $as_echo_n "(cached) " >&6
9378 if test -n "$AWK"; then
9379 ac_cv_prog_AWK="$AWK" # Let the user override the test.
9381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9385 test -z "$as_dir" && as_dir=.
9386 for ac_exec_ext in '' $ac_executable_extensions; do
9387 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9388 ac_cv_prog_AWK="$ac_prog"
9389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9399 if test -n "$AWK"; then
9400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
9401 $as_echo "$AWK" >&6; }
9403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9404 $as_echo "no" >&6; }
9408 test -n "$AWK" && break
9411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
9412 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
9413 if test -z "$MKDIR_P"; then
9414 if ${ac_cv_path_mkdir+:} false; then :
9415 $as_echo_n "(cached) " >&6
9417 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9418 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
9421 test -z "$as_dir" && as_dir=.
9422 for ac_prog in mkdir gmkdir; do
9423 for ac_exec_ext in '' $ac_executable_extensions; do
9424 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
9425 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
9426 'mkdir (GNU coreutils) '* | \
9427 'mkdir (coreutils) '* | \
9428 'mkdir (fileutils) '4.1*)
9429 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
9439 test -d ./--version && rmdir ./--version
9440 if test "${ac_cv_path_mkdir+set}" = set; then
9441 MKDIR_P="$ac_cv_path_mkdir -p"
9443 # As a last resort, use the slow shell script. Don't cache a
9444 # value for MKDIR_P within a source directory, because that will
9445 # break other packages using the cache if that directory is
9446 # removed, or if the value is a relative name.
9447 MKDIR_P="$ac_install_sh -d"
9450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
9451 $as_echo "$MKDIR_P" >&6; }
9453 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
9454 # a relative path to it in each makefile where it substitutes it. This clashes
9455 # with our Makefile.global concept. This workaround helps.
9457 *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
9460 if test -z "$BISON"; then
9461 for ac_prog in bison
9463 # Extract the first word of "$ac_prog", so it can be a program name with args.
9464 set dummy $ac_prog; ac_word=$2
9465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9466 $as_echo_n "checking for $ac_word... " >&6; }
9467 if ${ac_cv_path_BISON+:} false; then :
9468 $as_echo_n "(cached) " >&6
9472 ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
9475 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9479 test -z "$as_dir" && as_dir=.
9480 for ac_exec_ext in '' $ac_executable_extensions; do
9481 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9482 ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
9483 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9493 BISON=$ac_cv_path_BISON
9494 if test -n "$BISON"; then
9495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9496 $as_echo "$BISON" >&6; }
9498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9499 $as_echo "no" >&6; }
9503 test -n "$BISON" && break
9507 # Report the value of BISON in configure's output in all cases.
9508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BISON" >&5
9509 $as_echo_n "checking for BISON... " >&6; }
9510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
9511 $as_echo "$BISON" >&6; }
9515 if test "$BISON"; then
9516 pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
9517 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_bison_version" >&5
9518 $as_echo "$as_me: using $pgac_bison_version" >&6;}
9519 if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
9521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9522 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9523 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
9524 $as_echo "$as_me: WARNING:
9525 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
9526 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
9529 # Bison >=3.0 issues warnings about %name-prefix="base_yy", instead
9530 # of the now preferred %name-prefix "base_yy", but the latter
9531 # doesn't work with Bison 2.3 or less. So for now we silence the
9532 # deprecation warnings.
9533 if echo "$pgac_bison_version" | $AWK '{ if ($4 >= 3) exit 0; else exit 1;}'
9535 BISONFLAGS="$BISONFLAGS -Wno-deprecated"
9539 if test -z "$BISON"; then
9540 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9541 *** Without Bison you will not be able to build PostgreSQL from Git nor
9542 *** change any of the parser definition files. You can obtain Bison from
9543 *** a GNU mirror site. (If you are using the official distribution of
9544 *** PostgreSQL then you do not need to worry about this, because the Bison
9545 *** output is pre-generated.)" >&5
9546 $as_echo "$as_me: WARNING:
9547 *** Without Bison you will not be able to build PostgreSQL from Git nor
9548 *** change any of the parser definition files. You can obtain Bison from
9549 *** a GNU mirror site. (If you are using the official distribution of
9550 *** PostgreSQL then you do not need to worry about this, because the Bison
9551 *** output is pre-generated.)" >&2;}
9553 # We don't need AC_SUBST(BISON) because PGAC_PATH_PROGS did it
9556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flex" >&5
9557 $as_echo_n "checking for flex... " >&6; }
9558 if ${pgac_cv_path_flex+:} false; then :
9559 $as_echo_n "(cached) " >&6
9561 # Let the user override the test
9562 if test -n "$FLEX"; then
9563 pgac_cv_path_flex=$FLEX
9567 for pgac_dir in $PATH; do
9569 if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
9572 for pgac_prog in flex lex; do
9573 pgac_candidate="$pgac_dir/$pgac_prog"
9574 if test -f "$pgac_candidate" \
9575 && $pgac_candidate --version </dev/null >/dev/null 2>&1
9577 echo '%%' > conftest.l
9578 if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
9579 pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
9580 if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 == 2 && ($2 > 5 || ($2 == 5 && $3 >= 31))) exit 0; else exit 1;}'
9582 pgac_cv_path_flex=$pgac_candidate
9585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9586 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9587 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
9588 $as_echo "$as_me: WARNING:
9589 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
9590 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
9596 rm -f conftest.l lex.yy.c
9597 : ${pgac_cv_path_flex=no}
9601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_path_flex" >&5
9602 $as_echo "$pgac_cv_path_flex" >&6; }
9603 if test x"$pgac_cv_path_flex" = x"no"; then
9604 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9605 *** Without Flex you will not be able to build PostgreSQL from Git nor
9606 *** change any of the scanner definition files. You can obtain Flex from
9607 *** a GNU mirror site. (If you are using the official distribution of
9608 *** PostgreSQL then you do not need to worry about this because the Flex
9609 *** output is pre-generated.)" >&5
9610 $as_echo "$as_me: WARNING:
9611 *** Without Flex you will not be able to build PostgreSQL from Git nor
9612 *** change any of the scanner definition files. You can obtain Flex from
9613 *** a GNU mirror site. (If you are using the official distribution of
9614 *** PostgreSQL then you do not need to worry about this because the Flex
9615 *** output is pre-generated.)" >&2;}
9619 FLEX=$pgac_cv_path_flex
9620 pgac_flex_version=`$FLEX --version 2>/dev/null`
9621 { $as_echo "$as_me:${as_lineno-$LINENO}: using $pgac_flex_version" >&5
9622 $as_echo "$as_me: using $pgac_flex_version" >&6;}
9629 if test -z "$PERL"; then
9632 # Extract the first word of "$ac_prog", so it can be a program name with args.
9633 set dummy $ac_prog; ac_word=$2
9634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9635 $as_echo_n "checking for $ac_word... " >&6; }
9636 if ${ac_cv_path_PERL+:} false; then :
9637 $as_echo_n "(cached) " >&6
9641 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
9644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9648 test -z "$as_dir" && as_dir=.
9649 for ac_exec_ext in '' $ac_executable_extensions; do
9650 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9651 ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
9652 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9662 PERL=$ac_cv_path_PERL
9663 if test -n "$PERL"; then
9664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9665 $as_echo "$PERL" >&6; }
9667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9668 $as_echo "no" >&6; }
9672 test -n "$PERL" && break
9676 # Report the value of PERL in configure's output in all cases.
9677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PERL" >&5
9678 $as_echo_n "checking for PERL... " >&6; }
9679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
9680 $as_echo "$PERL" >&6; }
9684 if test "$PERL"; then
9685 pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'`
9686 { $as_echo "$as_me:${as_lineno-$LINENO}: using perl $pgac_perl_version" >&5
9687 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
9688 if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
9689 $AWK '{ if ($1 == 5 && $2 >= 8) exit 1; else exit 0;}'
9691 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9692 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9693 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
9694 $as_echo "$as_me: WARNING:
9695 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
9696 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
9701 if test -z "$PERL"; then
9702 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
9703 *** Without Perl you will not be able to build PostgreSQL from Git.
9704 *** You can obtain Perl from any CPAN mirror site.
9705 *** (If you are using the official distribution of PostgreSQL then you do not
9706 *** need to worry about this, because the Perl output is pre-generated.)" >&5
9707 $as_echo "$as_me: WARNING:
9708 *** Without Perl you will not be able to build PostgreSQL from Git.
9709 *** You can obtain Perl from any CPAN mirror site.
9710 *** (If you are using the official distribution of PostgreSQL then you do not
9711 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
9714 if test "$with_perl" = yes; then
9715 if test -z "$PERL"; then
9716 as_fn_error $? "Perl not found" "$LINENO" 5
9719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl archlibexp" >&5
9720 $as_echo_n "checking for Perl archlibexp... " >&6; }
9721 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
9722 test "$PORTNAME" = "win32" && perl_archlibexp=`echo $perl_archlibexp | sed 's,\\\\,/,g'`
9723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_archlibexp" >&5
9724 $as_echo "$perl_archlibexp" >&6; }
9725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl privlibexp" >&5
9726 $as_echo_n "checking for Perl privlibexp... " >&6; }
9727 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
9728 test "$PORTNAME" = "win32" && perl_privlibexp=`echo $perl_privlibexp | sed 's,\\\\,/,g'`
9729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_privlibexp" >&5
9730 $as_echo "$perl_privlibexp" >&6; }
9731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Perl useshrplib" >&5
9732 $as_echo_n "checking for Perl useshrplib... " >&6; }
9733 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
9734 test "$PORTNAME" = "win32" && perl_useshrplib=`echo $perl_useshrplib | sed 's,\\\\,/,g'`
9735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_useshrplib" >&5
9736 $as_echo "$perl_useshrplib" >&6; }
9737 if test "$perl_useshrplib" != yes && test "$perl_useshrplib" != true; then
9738 as_fn_error $? "cannot build PL/Perl because libperl is not a shared library
9739 You might have to rebuild your Perl installation. Refer to the
9740 documentation for details. Use --without-perl to disable building
9741 PL/Perl." "$LINENO" 5
9744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS recommended by Perl" >&5
9745 $as_echo_n "checking for CFLAGS recommended by Perl... " >&6; }
9746 perl_ccflags=`$PERL -MConfig -e 'print $Config{ccflags}'`
9747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_ccflags" >&5
9748 $as_echo "$perl_ccflags" >&6; }
9749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLAGS to compile embedded Perl" >&5
9750 $as_echo_n "checking for CFLAGS to compile embedded Perl... " >&6; }
9751 perl_embed_ccflags=`$PERL -MConfig -e 'foreach $f (split(" ",$Config{ccflags})) {print $f, " " if ($f =~ /^-D[^_]/ || $f =~ /^-D_USE_32BIT_TIME_T/)}'`
9752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ccflags" >&5
9753 $as_echo "$perl_embed_ccflags" >&6; }
9756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flags to link embedded Perl" >&5
9757 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
9758 if test "$PORTNAME" = "win32" ; then
9759 perl_lib=`basename $perl_archlibexp/CORE/perl[5-9]*.lib .lib`
9760 if test -e "$perl_archlibexp/CORE/$perl_lib.lib"; then
9761 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9763 perl_lib=`basename $perl_archlibexp/CORE/libperl[5-9]*.a .a | sed 's/^lib//'`
9764 if test -e "$perl_archlibexp/CORE/lib$perl_lib.a"; then
9765 perl_embed_ldflags="-L$perl_archlibexp/CORE -l$perl_lib"
9769 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
9770 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
9771 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
9773 if test -z "$perl_embed_ldflags" ; then
9774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9775 $as_echo "no" >&6; }
9776 as_fn_error $? "could not determine flags for linking embedded Perl.
9777 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
9778 installed." "$LINENO" 5
9780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_embed_ldflags" >&5
9781 $as_echo "$perl_embed_ldflags" >&6; }
9786 if test "$with_python" = yes; then
9787 if test -z "$PYTHON"; then
9788 for ac_prog in python
9790 # Extract the first word of "$ac_prog", so it can be a program name with args.
9791 set dummy $ac_prog; ac_word=$2
9792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9793 $as_echo_n "checking for $ac_word... " >&6; }
9794 if ${ac_cv_path_PYTHON+:} false; then :
9795 $as_echo_n "(cached) " >&6
9799 ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
9802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9806 test -z "$as_dir" && as_dir=.
9807 for ac_exec_ext in '' $ac_executable_extensions; do
9808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9809 ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
9810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9820 PYTHON=$ac_cv_path_PYTHON
9821 if test -n "$PYTHON"; then
9822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9823 $as_echo "$PYTHON" >&6; }
9825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9826 $as_echo "no" >&6; }
9830 test -n "$PYTHON" && break
9834 # Report the value of PYTHON in configure's output in all cases.
9835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PYTHON" >&5
9836 $as_echo_n "checking for PYTHON... " >&6; }
9837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
9838 $as_echo "$PYTHON" >&6; }
9841 if test x"$PYTHON" = x""; then
9842 as_fn_error $? "Python not found" "$LINENO" 5
9846 python_fullversion=`${PYTHON} -c "import sys; print(sys.version)" | sed q`
9847 { $as_echo "$as_me:${as_lineno-$LINENO}: using python $python_fullversion" >&5
9848 $as_echo "$as_me: using python $python_fullversion" >&6;}
9849 # python_fullversion is typically n.n.n plus some trailing junk
9850 python_majorversion=`echo "$python_fullversion" | sed 's/^\([0-9]*\).*/\1/'`
9851 python_minorversion=`echo "$python_fullversion" | sed 's/^[0-9]*\.\([0-9]*\).*/\1/'`
9852 python_version=`echo "$python_fullversion" | sed 's/^\([0-9]*\.[0-9]*\).*/\1/'`
9853 # Reject unsupported Python versions as soon as practical.
9854 if test "$python_majorversion" -lt 3 -a "$python_minorversion" -lt 4; then
9855 as_fn_error $? "Python version $python_version is too old (version 2.4 or later is required)" "$LINENO" 5
9858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Python distutils module" >&5
9859 $as_echo_n "checking for Python distutils module... " >&6; }
9860 if "${PYTHON}" -c 'import distutils' 2>&5
9862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9863 $as_echo "yes" >&6; }
9865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9866 $as_echo "no" >&6; }
9867 as_fn_error $? "distutils module not found" "$LINENO" 5
9870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python configuration directory" >&5
9871 $as_echo_n "checking Python configuration directory... " >&6; }
9872 python_configdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBPL'))))"`
9873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_configdir" >&5
9874 $as_echo "$python_configdir" >&6; }
9876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Python include directories" >&5
9877 $as_echo_n "checking Python include directories... " >&6; }
9878 python_includespec=`${PYTHON} -c "
9879 import distutils.sysconfig
9880 a = '-I' + distutils.sysconfig.get_python_inc(False)
9881 b = '-I' + distutils.sysconfig.get_python_inc(True)
9885 print(a + ' ' + b)"`
9886 if test "$PORTNAME" = win32 ; then
9887 python_includespec=`echo $python_includespec | sed 's,[\],/,g'`
9889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $python_includespec" >&5
9890 $as_echo "$python_includespec" >&6; }
9894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link an embedded Python application" >&5
9895 $as_echo_n "checking how to link an embedded Python application... " >&6; }
9897 python_libdir=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
9898 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
9900 # If LDLIBRARY exists and has a shlib extension, use it verbatim.
9901 ldlibrary=`echo "${python_ldlibrary}" | sed -e 's/\.so$//' -e 's/\.dll$//' -e 's/\.dylib$//' -e 's/\.sl$//'`
9902 if test -e "${python_libdir}/${python_ldlibrary}" -a x"${python_ldlibrary}" != x"${ldlibrary}"
9904 ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
9907 # Otherwise, guess the base name of the shlib.
9908 # LDVERSION was added in Python 3.2, before that use VERSION,
9909 # or failing that, $python_version from _PGAC_CHECK_PYTHON_DIRS.
9910 python_ldversion=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDVERSION'))))"`
9911 if test x"${python_ldversion}" != x""; then
9912 ldlibrary="python${python_ldversion}"
9914 python_version_var=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('VERSION'))))"`
9915 if test x"${python_version_var}" != x""; then
9916 ldlibrary="python${python_version_var}"
9918 ldlibrary="python${python_version}"
9921 # Search for a likely-looking file.
9923 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9925 # We don't know the platform DLSUFFIX here, so check 'em all.
9926 for e in .so .dll .dylib .sl; do
9927 if test -e "$d/lib${ldlibrary}$e"; then
9934 # Some platforms (OpenBSD) require us to accept a bare versioned shlib
9935 # (".so.n.n") as well. However, check this only after failing to find
9936 # ".so" anywhere, because yet other platforms (Debian) put the .so
9937 # symlink in a different directory from the underlying versioned shlib.
9938 if test "$found_shlib" != 1; then
9939 for d in "${python_libdir}" "${python_configdir}" /usr/lib64 /usr/lib
9941 for f in "$d/lib${ldlibrary}.so."* ; do
9942 if test -e "$f"; then
9950 # As usual, Windows has its own ideas. Possible default library
9951 # locations include c:/Windows/System32 and (for Cygwin) /usr/bin,
9952 # and the "lib" prefix might not be there.
9953 if test "$found_shlib" != 1 -a \( "$PORTNAME" = win32 -o "$PORTNAME" = cygwin \); then
9954 for d in "${python_libdir}" "${python_configdir}" c:/Windows/System32 /usr/bin
9956 for f in "$d/lib${ldlibrary}.dll" "$d/${ldlibrary}.dll" ; do
9957 if test -e "$f"; then
9966 if test "$found_shlib" != 1; then
9967 as_fn_error $? "could not find shared library for Python
9968 You might have to rebuild your Python installation. Refer to the
9969 documentation for details. Use --without-python to disable building
9970 PL/Python." "$LINENO" 5
9972 python_libspec="-L${python_libdir} -l${ldlibrary}"
9974 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
9976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${python_libspec} ${python_additional_libs}" >&5
9977 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
9983 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
9984 if test -z "$ZIC"; then
9987 # Extract the first word of "$ac_prog", so it can be a program name with args.
9988 set dummy $ac_prog; ac_word=$2
9989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9990 $as_echo_n "checking for $ac_word... " >&6; }
9991 if ${ac_cv_path_ZIC+:} false; then :
9992 $as_echo_n "(cached) " >&6
9996 ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
9999 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10000 for as_dir in $PATH
10003 test -z "$as_dir" && as_dir=.
10004 for ac_exec_ext in '' $ac_executable_extensions; do
10005 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10006 ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
10007 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10017 ZIC=$ac_cv_path_ZIC
10018 if test -n "$ZIC"; then
10019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
10020 $as_echo "$ZIC" >&6; }
10022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10023 $as_echo "no" >&6; }
10027 test -n "$ZIC" && break
10031 # Report the value of ZIC in configure's output in all cases.
10032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIC" >&5
10033 $as_echo_n "checking for ZIC... " >&6; }
10034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIC" >&5
10035 $as_echo "$ZIC" >&6; }
10038 if test -z "$ZIC"; then
10040 When cross-compiling, either use the option --with-system-tzdata to use
10041 existing time-zone data, or set the environment variable ZIC to a zic
10042 program to use during the build." "$LINENO" 5
10049 # For each platform, we need to know about any special compile and link
10050 # libraries, and whether the normal C function names are thread-safe.
10051 # See the comment at the top of src/port/thread.c for more information.
10052 # WIN32 doesn't need the pthread tests; it always uses threads
10054 # These tests are run before the library-tests, because linking with the
10055 # other libraries can pull in the pthread functions as a side-effect. We
10056 # want to use the -pthread or similar flags directly, and not rely on
10057 # the side-effects of linking with some other library.
10059 # note: We have to use AS_IF here rather than plain if. The AC_CHECK_HEADER
10060 # invocation below is the first one in the script, and autoconf generates
10061 # additional code for that, which must not be inside the if-block. AS_IF
10062 # knows how to do that.
10063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
10064 $as_echo_n "checking for ANSI C header files... " >&6; }
10065 if ${ac_cv_header_stdc+:} false; then :
10066 $as_echo_n "(cached) " >&6
10068 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10069 /* end confdefs.h. */
10070 #include <stdlib.h>
10071 #include <stdarg.h>
10072 #include <string.h>
10083 if ac_fn_c_try_compile "$LINENO"; then :
10084 ac_cv_header_stdc=yes
10086 ac_cv_header_stdc=no
10088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10090 if test $ac_cv_header_stdc = yes; then
10091 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10093 /* end confdefs.h. */
10094 #include <string.h>
10097 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10098 $EGREP "memchr" >/dev/null 2>&1; then :
10101 ac_cv_header_stdc=no
10107 if test $ac_cv_header_stdc = yes; then
10108 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10110 /* end confdefs.h. */
10111 #include <stdlib.h>
10114 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10115 $EGREP "free" >/dev/null 2>&1; then :
10118 ac_cv_header_stdc=no
10124 if test $ac_cv_header_stdc = yes; then
10125 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10126 if test "$cross_compiling" = yes; then :
10129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10130 /* end confdefs.h. */
10132 #include <stdlib.h>
10133 #if ((' ' & 0x0FF) == 0x020)
10134 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10135 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10137 # define ISLOWER(c) \
10138 (('a' <= (c) && (c) <= 'i') \
10139 || ('j' <= (c) && (c) <= 'r') \
10140 || ('s' <= (c) && (c) <= 'z'))
10141 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10144 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10149 for (i = 0; i < 256; i++)
10150 if (XOR (islower (i), ISLOWER (i))
10151 || toupper (i) != TOUPPER (i))
10156 if ac_fn_c_try_run "$LINENO"; then :
10159 ac_cv_header_stdc=no
10161 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10162 conftest.$ac_objext conftest.beam conftest.$ac_ext
10167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
10168 $as_echo "$ac_cv_header_stdc" >&6; }
10169 if test $ac_cv_header_stdc = yes; then
10171 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
10175 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
10176 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10177 inttypes.h stdint.h unistd.h
10179 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10180 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10182 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10183 cat >>confdefs.h <<_ACEOF
10184 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10192 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then :
10198 ac_cpp='$CPP $CPPFLAGS'
10199 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10200 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10201 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10205 # We used to check for pthread.h first, but this fails if pthread.h
10206 # requires special compiler flags (e.g. on Tru64 or Sequent).
10207 # It gets checked for in the link test anyway.
10209 # First of all, check if the user has set any of the PTHREAD_LIBS,
10210 # etcetera environment variables, and if threads linking works using
10212 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
10213 save_CFLAGS="$CFLAGS"
10214 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10216 LIBS="$PTHREAD_LIBS $LIBS"
10217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
10218 $as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
10219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10220 /* end confdefs.h. */
10222 /* Override any GCC internal prototype to avoid an error.
10223 Use char because int might match the return type of a GCC
10224 builtin and then its argument prototype would still apply. */
10228 char pthread_join ();
10232 return pthread_join ();
10237 if ac_fn_c_try_link "$LINENO"; then :
10240 rm -f core conftest.err conftest.$ac_objext \
10241 conftest$ac_exeext conftest.$ac_ext
10242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
10243 $as_echo "$ax_pthread_ok" >&6; }
10244 if test x"$ax_pthread_ok" = xno; then
10249 CFLAGS="$save_CFLAGS"
10252 # We must check for the threads library under a number of different
10253 # names; the ordering is very important because some systems
10254 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
10255 # libraries is broken (non-POSIX).
10257 # Create a list of thread flags to try. Items starting with a "-" are
10258 # C compiler flags, and other items are library names, except for "none"
10259 # which indicates that we try without any flags at all, and "pthread-config"
10260 # which is a program returning the flags for the Pth emulation library.
10262 ax_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mt -mthreads pthread --thread-safe pthread-config"
10264 # The ordering *is* (sometimes) important. Some notes on the
10265 # individual items follow:
10267 # pthreads: AIX (must check this before -lpthread)
10268 # none: in case threads are in libc; should be tried before -Kthread and
10269 # other compiler flags to prevent continual compiler warnings
10270 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
10271 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
10272 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
10273 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
10274 # -pthreads: Solaris/gcc
10275 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
10276 # doesn't hurt to check since this sometimes defines pthreads and
10277 # -D_REENTRANT too), HP C (must be checked before -lpthread, which
10278 # is present but should not be used directly)
10279 # -mthreads: Mingw32/gcc, Lynx/gcc
10280 # pthread: Linux, etcetera
10281 # --thread-safe: KAI C++
10282 # pthread-config: use pthread-config program (for GNU Pth library)
10288 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
10289 # multi-threading and also sets -lpthread."
10291 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
10296 # IBM z/OS requires a feature-test macro to be defined in order to
10297 # enable POSIX threads at all, so give the user a hint if this is
10298 # not set. (We don't define these ourselves, as they can affect
10299 # other portions of the system API in unpredictable ways.)
10301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10302 /* end confdefs.h. */
10304 # if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
10305 AX_PTHREAD_ZOS_MISSING
10309 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10310 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
10311 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
10312 $as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
10320 # Newer versions of Solaris require the "-mt -lpthread" pair, and we
10321 # check that first. On some older versions, libc contains stubbed
10322 # (non-functional) versions of the pthreads routines, so link-based
10323 # tests will erroneously succeed. (We need to link with -pthreads/-mt/
10324 # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
10325 # a function called by this macro, so we could check for that, but
10326 # who knows whether they'll stub that too in a future libc.) So
10327 # we'll look for -pthreads and -lpthread shortly thereafter.
10329 ax_pthread_flags="-mt,pthread -pthreads -pthread pthread $ax_pthread_flags"
10333 # Older versions of Clang only give a warning instead of an error for an
10334 # unrecognized option, unless we specify -Werror. (We throw in some extra
10335 # Clang warning flags for good measure.)
10337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler needs certain flags to reject unknown flags" >&5
10338 $as_echo_n "checking if compiler needs certain flags to reject unknown flags... " >&6; }
10339 if ${ax_cv_PTHREAD_REJECT_UNKNOWN+:} false; then :
10340 $as_echo_n "(cached) " >&6
10342 ax_cv_PTHREAD_REJECT_UNKNOWN=unknown
10343 save_CFLAGS="$CFLAGS"
10344 ax_pthread_extra_flags="-Wunknown-warning-option -Wunused-command-line-argument"
10345 CFLAGS="$CFLAGS $ax_pthread_extra_flags -Wfoobaz -foobaz"
10346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10347 /* end confdefs.h. */
10357 if ac_fn_c_try_compile "$LINENO"; then :
10358 ax_cv_PTHREAD_REJECT_UNKNOWN="-Werror $ax_pthread_extra_flags"
10360 ax_cv_PTHREAD_REJECT_UNKNOWN=no
10362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10363 CFLAGS="$save_CFLAGS"
10366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_REJECT_UNKNOWN" >&5
10367 $as_echo "$ax_cv_PTHREAD_REJECT_UNKNOWN" >&6; }
10368 ax_pthread_extra_flags=
10369 if test "x$ax_cv_PTHREAD_REJECT_UNKNOWN" != "xno"; then :
10370 ax_pthread_extra_flags="$ax_cv_PTHREAD_REJECT_UNKNOWN"
10373 if test x"$ax_pthread_ok" = xno; then
10374 for flag in $ax_pthread_flags; do
10378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
10379 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
10383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
10384 $as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
10385 PTHREAD_CFLAGS="-mt"
10386 PTHREAD_LIBS="-lpthread"
10390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
10391 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
10392 PTHREAD_CFLAGS="$flag"
10396 # Extract the first word of "pthread-config", so it can be a program name with args.
10397 set dummy pthread-config; ac_word=$2
10398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10399 $as_echo_n "checking for $ac_word... " >&6; }
10400 if ${ac_cv_prog_ax_pthread_config+:} false; then :
10401 $as_echo_n "(cached) " >&6
10403 if test -n "$ax_pthread_config"; then
10404 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
10406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10407 for as_dir in $PATH
10410 test -z "$as_dir" && as_dir=.
10411 for ac_exec_ext in '' $ac_executable_extensions; do
10412 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10413 ac_cv_prog_ax_pthread_config="yes"
10414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10421 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
10424 ax_pthread_config=$ac_cv_prog_ax_pthread_config
10425 if test -n "$ax_pthread_config"; then
10426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
10427 $as_echo "$ax_pthread_config" >&6; }
10429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10430 $as_echo "no" >&6; }
10434 if test x"$ax_pthread_config" = xno; then continue; fi
10435 PTHREAD_CFLAGS="`pthread-config --cflags`"
10436 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
10440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
10441 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
10442 PTHREAD_LIBS="-l$flag"
10447 save_CFLAGS="$CFLAGS"
10448 LIBS="$PTHREAD_LIBS $LIBS"
10449 CFLAGS="$CFLAGS $PTHREAD_CFLAGS $ax_pthread_extra_flags"
10451 # Check for various functions. We must include pthread.h,
10452 # since some functions may be macros. (On the Sequent, we
10453 # need a special flag -Kthread to make this header compile.)
10454 # We check for pthread_join because it is in -lpthread on IRIX
10455 # while pthread_create is in libc. We check for pthread_attr_init
10456 # due to DEC craziness with -lpthreads. We check for
10457 # pthread_cleanup_push because it is one of the few pthread
10458 # functions on Solaris that doesn't have a non-functional libc stub.
10459 # We try pthread_create on general principles.
10460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10461 /* end confdefs.h. */
10462 #include <pthread.h>
10463 static void routine(void *a) { a = 0; }
10464 static void *start_routine(void *a) { return a; }
10468 pthread_t th; pthread_attr_t attr;
10469 pthread_create(&th, 0, start_routine, 0);
10470 pthread_join(th, 0);
10471 pthread_attr_init(&attr);
10472 pthread_cleanup_push(routine, 0);
10473 pthread_cleanup_pop(0) /* ; */
10478 if ac_fn_c_try_link "$LINENO"; then :
10481 rm -f core conftest.err conftest.$ac_objext \
10482 conftest$ac_exeext conftest.$ac_ext
10485 CFLAGS="$save_CFLAGS"
10487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
10488 $as_echo "$ax_pthread_ok" >&6; }
10489 if test "x$ax_pthread_ok" = xyes; then
10498 # Various other checks:
10499 if test "x$ax_pthread_ok" = xyes; then
10501 LIBS="$PTHREAD_LIBS $LIBS"
10502 save_CFLAGS="$CFLAGS"
10503 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10505 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
10506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
10507 $as_echo_n "checking for joinable pthread attribute... " >&6; }
10508 if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
10509 $as_echo_n "(cached) " >&6
10511 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
10512 for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
10513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10514 /* end confdefs.h. */
10515 #include <pthread.h>
10519 int attr = $attr; return attr /* ; */
10524 if ac_fn_c_try_link "$LINENO"; then :
10525 ax_cv_PTHREAD_JOINABLE_ATTR=$attr; break
10527 rm -f core conftest.err conftest.$ac_objext \
10528 conftest$ac_exeext conftest.$ac_ext
10532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
10533 $as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
10534 if test "$ax_cv_PTHREAD_JOINABLE_ATTR" != unknown && \
10535 test "$ax_cv_PTHREAD_JOINABLE_ATTR" != PTHREAD_CREATE_JOINABLE; then :
10537 cat >>confdefs.h <<_ACEOF
10538 #define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
10543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
10544 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
10545 if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
10546 $as_echo_n "(cached) " >&6
10548 ax_cv_PTHREAD_SPECIAL_FLAGS=no
10549 ax_pthread_special_flags_added=no
10550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10551 /* end confdefs.h. */
10553 # if !defined(_REENTRANT) && !defined(_THREAD_SAFE)
10554 AX_PTHREAD_NEED_SPECIAL_FLAG
10558 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10559 $EGREP "AX_PTHREAD_NEED_SPECIAL_FLAG" >/dev/null 2>&1; then :
10562 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_THREAD_SAFE"
10564 darwin* | hpux* | osf* | solaris*)
10565 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_REENTRANT"
10574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
10575 $as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
10576 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
10577 test "x$ax_pthread_special_flags_added" != "xyes"; then :
10578 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
10579 ax_pthread_special_flags_added=yes
10582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
10583 $as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
10584 if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
10585 $as_echo_n "(cached) " >&6
10587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10588 /* end confdefs.h. */
10589 #include <pthread.h>
10593 int i = PTHREAD_PRIO_INHERIT;
10598 if ac_fn_c_try_link "$LINENO"; then :
10599 ax_cv_PTHREAD_PRIO_INHERIT=yes
10601 ax_cv_PTHREAD_PRIO_INHERIT=no
10603 rm -f core conftest.err conftest.$ac_objext \
10604 conftest$ac_exeext conftest.$ac_ext
10607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
10608 $as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
10609 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes"; then :
10611 $as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
10616 CFLAGS="$save_CFLAGS"
10618 # More AIX lossage: compile with *_r variant
10619 if test "x$GCC" != xyes; then
10623 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
10624 #handle absolute path differently from PATH based program lookup
10627 if as_fn_executable_p ${CC}_r; then :
10628 PTHREAD_CC="${CC}_r"
10631 for ac_prog in ${CC}_r
10633 # Extract the first word of "$ac_prog", so it can be a program name with args.
10634 set dummy $ac_prog; ac_word=$2
10635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10636 $as_echo_n "checking for $ac_word... " >&6; }
10637 if ${ac_cv_prog_PTHREAD_CC+:} false; then :
10638 $as_echo_n "(cached) " >&6
10640 if test -n "$PTHREAD_CC"; then
10641 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
10643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10644 for as_dir in $PATH
10647 test -z "$as_dir" && as_dir=.
10648 for ac_exec_ext in '' $ac_executable_extensions; do
10649 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10650 ac_cv_prog_PTHREAD_CC="$ac_prog"
10651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10660 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
10661 if test -n "$PTHREAD_CC"; then
10662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
10663 $as_echo "$PTHREAD_CC" >&6; }
10665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10666 $as_echo "no" >&6; }
10670 test -n "$PTHREAD_CC" && break
10672 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10683 test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
10689 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
10690 if test x"$ax_pthread_ok" = xyes; then
10692 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10700 ac_cpp='$CPP $CPPFLAGS'
10701 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10702 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10703 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10707 # Some platforms use these, so just define them. They can't hurt if they
10708 # are not supported. For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
10709 # enables 5-arg getpwuid_r, among other things.
10710 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
10712 # Check for *_r functions
10715 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
10716 LIBS="$LIBS $PTHREAD_LIBS"
10718 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10719 if test "x$ac_cv_header_pthread_h" = xyes; then :
10723 pthread.h not found; use --disable-thread-safety to disable thread safety" "$LINENO" 5
10728 for ac_func in strerror_r getpwuid_r gethostbyname_r
10730 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10731 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10732 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10733 cat >>confdefs.h <<_ACEOF
10734 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10741 # Do test here with the proper thread flags
10742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns int" >&5
10743 $as_echo_n "checking whether strerror_r returns int... " >&6; }
10744 if ${pgac_cv_func_strerror_r_int+:} false; then :
10745 $as_echo_n "(cached) " >&6
10747 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10748 /* end confdefs.h. */
10749 #include <string.h>
10754 int strerror_r(int, char *, size_t);
10756 /* Older AIX has 'int' for the third argument so we don't test the args. */
10763 if ac_fn_c_try_compile "$LINENO"; then :
10764 pgac_cv_func_strerror_r_int=yes
10766 pgac_cv_func_strerror_r_int=no
10768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_strerror_r_int" >&5
10771 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
10772 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
10774 $as_echo "#define STRERROR_R_INT 1" >>confdefs.h
10785 # do not use values from template file
10798 ## Most libraries are included only if they demonstrably provide a function
10799 ## we need, but libm is an exception: always include it, because there are
10800 ## too many compilers that play cute optimization games that will break
10801 ## probes for standard functions such as pow().
10804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lm" >&5
10805 $as_echo_n "checking for main in -lm... " >&6; }
10806 if ${ac_cv_lib_m_main+:} false; then :
10807 $as_echo_n "(cached) " >&6
10809 ac_check_lib_save_LIBS=$LIBS
10811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10812 /* end confdefs.h. */
10823 if ac_fn_c_try_link "$LINENO"; then :
10824 ac_cv_lib_m_main=yes
10826 ac_cv_lib_m_main=no
10828 rm -f core conftest.err conftest.$ac_objext \
10829 conftest$ac_exeext conftest.$ac_ext
10830 LIBS=$ac_check_lib_save_LIBS
10832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_main" >&5
10833 $as_echo "$ac_cv_lib_m_main" >&6; }
10834 if test "x$ac_cv_lib_m_main" = xyes; then :
10835 cat >>confdefs.h <<_ACEOF
10836 #define HAVE_LIBM 1
10843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setproctitle" >&5
10844 $as_echo_n "checking for library containing setproctitle... " >&6; }
10845 if ${ac_cv_search_setproctitle+:} false; then :
10846 $as_echo_n "(cached) " >&6
10848 ac_func_search_save_LIBS=$LIBS
10849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10850 /* end confdefs.h. */
10852 /* Override any GCC internal prototype to avoid an error.
10853 Use char because int might match the return type of a GCC
10854 builtin and then its argument prototype would still apply. */
10858 char setproctitle ();
10862 return setproctitle ();
10867 for ac_lib in '' util; do
10868 if test -z "$ac_lib"; then
10869 ac_res="none required"
10872 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10874 if ac_fn_c_try_link "$LINENO"; then :
10875 ac_cv_search_setproctitle=$ac_res
10877 rm -f core conftest.err conftest.$ac_objext \
10879 if ${ac_cv_search_setproctitle+:} false; then :
10883 if ${ac_cv_search_setproctitle+:} false; then :
10886 ac_cv_search_setproctitle=no
10888 rm conftest.$ac_ext
10889 LIBS=$ac_func_search_save_LIBS
10891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setproctitle" >&5
10892 $as_echo "$ac_cv_search_setproctitle" >&6; }
10893 ac_res=$ac_cv_search_setproctitle
10894 if test "$ac_res" != no; then :
10895 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
10900 $as_echo_n "checking for library containing dlopen... " >&6; }
10901 if ${ac_cv_search_dlopen+:} false; then :
10902 $as_echo_n "(cached) " >&6
10904 ac_func_search_save_LIBS=$LIBS
10905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10906 /* end confdefs.h. */
10908 /* Override any GCC internal prototype to avoid an error.
10909 Use char because int might match the return type of a GCC
10910 builtin and then its argument prototype would still apply. */
10923 for ac_lib in '' dl; do
10924 if test -z "$ac_lib"; then
10925 ac_res="none required"
10928 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10930 if ac_fn_c_try_link "$LINENO"; then :
10931 ac_cv_search_dlopen=$ac_res
10933 rm -f core conftest.err conftest.$ac_objext \
10935 if ${ac_cv_search_dlopen+:} false; then :
10939 if ${ac_cv_search_dlopen+:} false; then :
10942 ac_cv_search_dlopen=no
10944 rm conftest.$ac_ext
10945 LIBS=$ac_func_search_save_LIBS
10947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
10948 $as_echo "$ac_cv_search_dlopen" >&6; }
10949 ac_res=$ac_cv_search_dlopen
10950 if test "$ac_res" != no; then :
10951 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
10955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing socket" >&5
10956 $as_echo_n "checking for library containing socket... " >&6; }
10957 if ${ac_cv_search_socket+:} false; then :
10958 $as_echo_n "(cached) " >&6
10960 ac_func_search_save_LIBS=$LIBS
10961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10962 /* end confdefs.h. */
10964 /* Override any GCC internal prototype to avoid an error.
10965 Use char because int might match the return type of a GCC
10966 builtin and then its argument prototype would still apply. */
10979 for ac_lib in '' socket ws2_32; do
10980 if test -z "$ac_lib"; then
10981 ac_res="none required"
10984 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10986 if ac_fn_c_try_link "$LINENO"; then :
10987 ac_cv_search_socket=$ac_res
10989 rm -f core conftest.err conftest.$ac_objext \
10991 if ${ac_cv_search_socket+:} false; then :
10995 if ${ac_cv_search_socket+:} false; then :
10998 ac_cv_search_socket=no
11000 rm conftest.$ac_ext
11001 LIBS=$ac_func_search_save_LIBS
11003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_socket" >&5
11004 $as_echo "$ac_cv_search_socket" >&6; }
11005 ac_res=$ac_cv_search_socket
11006 if test "$ac_res" != no; then :
11007 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shl_load" >&5
11012 $as_echo_n "checking for library containing shl_load... " >&6; }
11013 if ${ac_cv_search_shl_load+:} false; then :
11014 $as_echo_n "(cached) " >&6
11016 ac_func_search_save_LIBS=$LIBS
11017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11018 /* end confdefs.h. */
11020 /* Override any GCC internal prototype to avoid an error.
11021 Use char because int might match the return type of a GCC
11022 builtin and then its argument prototype would still apply. */
11030 return shl_load ();
11035 for ac_lib in '' dld; do
11036 if test -z "$ac_lib"; then
11037 ac_res="none required"
11040 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11042 if ac_fn_c_try_link "$LINENO"; then :
11043 ac_cv_search_shl_load=$ac_res
11045 rm -f core conftest.err conftest.$ac_objext \
11047 if ${ac_cv_search_shl_load+:} false; then :
11051 if ${ac_cv_search_shl_load+:} false; then :
11054 ac_cv_search_shl_load=no
11056 rm conftest.$ac_ext
11057 LIBS=$ac_func_search_save_LIBS
11059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shl_load" >&5
11060 $as_echo "$ac_cv_search_shl_load" >&6; }
11061 ac_res=$ac_cv_search_shl_load
11062 if test "$ac_res" != no; then :
11063 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getopt_long" >&5
11068 $as_echo_n "checking for library containing getopt_long... " >&6; }
11069 if ${ac_cv_search_getopt_long+:} false; then :
11070 $as_echo_n "(cached) " >&6
11072 ac_func_search_save_LIBS=$LIBS
11073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11074 /* end confdefs.h. */
11076 /* Override any GCC internal prototype to avoid an error.
11077 Use char because int might match the return type of a GCC
11078 builtin and then its argument prototype would still apply. */
11082 char getopt_long ();
11086 return getopt_long ();
11091 for ac_lib in '' getopt gnugetopt; do
11092 if test -z "$ac_lib"; then
11093 ac_res="none required"
11096 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11098 if ac_fn_c_try_link "$LINENO"; then :
11099 ac_cv_search_getopt_long=$ac_res
11101 rm -f core conftest.err conftest.$ac_objext \
11103 if ${ac_cv_search_getopt_long+:} false; then :
11107 if ${ac_cv_search_getopt_long+:} false; then :
11110 ac_cv_search_getopt_long=no
11112 rm conftest.$ac_ext
11113 LIBS=$ac_func_search_save_LIBS
11115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getopt_long" >&5
11116 $as_echo "$ac_cv_search_getopt_long" >&6; }
11117 ac_res=$ac_cv_search_getopt_long
11118 if test "$ac_res" != no; then :
11119 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing crypt" >&5
11124 $as_echo_n "checking for library containing crypt... " >&6; }
11125 if ${ac_cv_search_crypt+:} false; then :
11126 $as_echo_n "(cached) " >&6
11128 ac_func_search_save_LIBS=$LIBS
11129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11130 /* end confdefs.h. */
11132 /* Override any GCC internal prototype to avoid an error.
11133 Use char because int might match the return type of a GCC
11134 builtin and then its argument prototype would still apply. */
11147 for ac_lib in '' crypt; do
11148 if test -z "$ac_lib"; then
11149 ac_res="none required"
11152 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11154 if ac_fn_c_try_link "$LINENO"; then :
11155 ac_cv_search_crypt=$ac_res
11157 rm -f core conftest.err conftest.$ac_objext \
11159 if ${ac_cv_search_crypt+:} false; then :
11163 if ${ac_cv_search_crypt+:} false; then :
11166 ac_cv_search_crypt=no
11168 rm conftest.$ac_ext
11169 LIBS=$ac_func_search_save_LIBS
11171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_crypt" >&5
11172 $as_echo "$ac_cv_search_crypt" >&6; }
11173 ac_res=$ac_cv_search_crypt
11174 if test "$ac_res" != no; then :
11175 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_open" >&5
11180 $as_echo_n "checking for library containing shm_open... " >&6; }
11181 if ${ac_cv_search_shm_open+:} false; then :
11182 $as_echo_n "(cached) " >&6
11184 ac_func_search_save_LIBS=$LIBS
11185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11186 /* end confdefs.h. */
11188 /* Override any GCC internal prototype to avoid an error.
11189 Use char because int might match the return type of a GCC
11190 builtin and then its argument prototype would still apply. */
11198 return shm_open ();
11203 for ac_lib in '' rt; do
11204 if test -z "$ac_lib"; then
11205 ac_res="none required"
11208 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11210 if ac_fn_c_try_link "$LINENO"; then :
11211 ac_cv_search_shm_open=$ac_res
11213 rm -f core conftest.err conftest.$ac_objext \
11215 if ${ac_cv_search_shm_open+:} false; then :
11219 if ${ac_cv_search_shm_open+:} false; then :
11222 ac_cv_search_shm_open=no
11224 rm conftest.$ac_ext
11225 LIBS=$ac_func_search_save_LIBS
11227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_open" >&5
11228 $as_echo "$ac_cv_search_shm_open" >&6; }
11229 ac_res=$ac_cv_search_shm_open
11230 if test "$ac_res" != no; then :
11231 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shm_unlink" >&5
11236 $as_echo_n "checking for library containing shm_unlink... " >&6; }
11237 if ${ac_cv_search_shm_unlink+:} false; then :
11238 $as_echo_n "(cached) " >&6
11240 ac_func_search_save_LIBS=$LIBS
11241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11242 /* end confdefs.h. */
11244 /* Override any GCC internal prototype to avoid an error.
11245 Use char because int might match the return type of a GCC
11246 builtin and then its argument prototype would still apply. */
11250 char shm_unlink ();
11254 return shm_unlink ();
11259 for ac_lib in '' rt; do
11260 if test -z "$ac_lib"; then
11261 ac_res="none required"
11264 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11266 if ac_fn_c_try_link "$LINENO"; then :
11267 ac_cv_search_shm_unlink=$ac_res
11269 rm -f core conftest.err conftest.$ac_objext \
11271 if ${ac_cv_search_shm_unlink+:} false; then :
11275 if ${ac_cv_search_shm_unlink+:} false; then :
11278 ac_cv_search_shm_unlink=no
11280 rm conftest.$ac_ext
11281 LIBS=$ac_func_search_save_LIBS
11283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shm_unlink" >&5
11284 $as_echo "$ac_cv_search_shm_unlink" >&6; }
11285 ac_res=$ac_cv_search_shm_unlink
11286 if test "$ac_res" != no; then :
11287 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
11292 $as_echo_n "checking for library containing clock_gettime... " >&6; }
11293 if ${ac_cv_search_clock_gettime+:} false; then :
11294 $as_echo_n "(cached) " >&6
11296 ac_func_search_save_LIBS=$LIBS
11297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11298 /* end confdefs.h. */
11300 /* Override any GCC internal prototype to avoid an error.
11301 Use char because int might match the return type of a GCC
11302 builtin and then its argument prototype would still apply. */
11306 char clock_gettime ();
11310 return clock_gettime ();
11315 for ac_lib in '' rt posix4; do
11316 if test -z "$ac_lib"; then
11317 ac_res="none required"
11320 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11322 if ac_fn_c_try_link "$LINENO"; then :
11323 ac_cv_search_clock_gettime=$ac_res
11325 rm -f core conftest.err conftest.$ac_objext \
11327 if ${ac_cv_search_clock_gettime+:} false; then :
11331 if ${ac_cv_search_clock_gettime+:} false; then :
11334 ac_cv_search_clock_gettime=no
11336 rm conftest.$ac_ext
11337 LIBS=$ac_func_search_save_LIBS
11339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
11340 $as_echo "$ac_cv_search_clock_gettime" >&6; }
11341 ac_res=$ac_cv_search_clock_gettime
11342 if test "$ac_res" != no; then :
11343 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
11349 $as_echo_n "checking for library containing fdatasync... " >&6; }
11350 if ${ac_cv_search_fdatasync+:} false; then :
11351 $as_echo_n "(cached) " >&6
11353 ac_func_search_save_LIBS=$LIBS
11354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11355 /* end confdefs.h. */
11357 /* Override any GCC internal prototype to avoid an error.
11358 Use char because int might match the return type of a GCC
11359 builtin and then its argument prototype would still apply. */
11367 return fdatasync ();
11372 for ac_lib in '' rt posix4; do
11373 if test -z "$ac_lib"; then
11374 ac_res="none required"
11377 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11379 if ac_fn_c_try_link "$LINENO"; then :
11380 ac_cv_search_fdatasync=$ac_res
11382 rm -f core conftest.err conftest.$ac_objext \
11384 if ${ac_cv_search_fdatasync+:} false; then :
11388 if ${ac_cv_search_fdatasync+:} false; then :
11391 ac_cv_search_fdatasync=no
11393 rm conftest.$ac_ext
11394 LIBS=$ac_func_search_save_LIBS
11396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
11397 $as_echo "$ac_cv_search_fdatasync" >&6; }
11398 ac_res=$ac_cv_search_fdatasync
11399 if test "$ac_res" != no; then :
11400 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11404 # Required for thread_test.c on Solaris
11405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sched_yield" >&5
11406 $as_echo_n "checking for library containing sched_yield... " >&6; }
11407 if ${ac_cv_search_sched_yield+:} false; then :
11408 $as_echo_n "(cached) " >&6
11410 ac_func_search_save_LIBS=$LIBS
11411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11412 /* end confdefs.h. */
11414 /* Override any GCC internal prototype to avoid an error.
11415 Use char because int might match the return type of a GCC
11416 builtin and then its argument prototype would still apply. */
11420 char sched_yield ();
11424 return sched_yield ();
11429 for ac_lib in '' rt; do
11430 if test -z "$ac_lib"; then
11431 ac_res="none required"
11434 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11436 if ac_fn_c_try_link "$LINENO"; then :
11437 ac_cv_search_sched_yield=$ac_res
11439 rm -f core conftest.err conftest.$ac_objext \
11441 if ${ac_cv_search_sched_yield+:} false; then :
11445 if ${ac_cv_search_sched_yield+:} false; then :
11448 ac_cv_search_sched_yield=no
11450 rm conftest.$ac_ext
11451 LIBS=$ac_func_search_save_LIBS
11453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sched_yield" >&5
11454 $as_echo "$ac_cv_search_sched_yield" >&6; }
11455 ac_res=$ac_cv_search_sched_yield
11456 if test "$ac_res" != no; then :
11457 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11461 # Required for thread_test.c on Solaris 2.5:
11462 # Other ports use it too (HP-UX) so test unconditionally
11463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname_r" >&5
11464 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
11465 if ${ac_cv_search_gethostbyname_r+:} false; then :
11466 $as_echo_n "(cached) " >&6
11468 ac_func_search_save_LIBS=$LIBS
11469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11470 /* end confdefs.h. */
11472 /* Override any GCC internal prototype to avoid an error.
11473 Use char because int might match the return type of a GCC
11474 builtin and then its argument prototype would still apply. */
11478 char gethostbyname_r ();
11482 return gethostbyname_r ();
11487 for ac_lib in '' nsl; do
11488 if test -z "$ac_lib"; then
11489 ac_res="none required"
11492 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11494 if ac_fn_c_try_link "$LINENO"; then :
11495 ac_cv_search_gethostbyname_r=$ac_res
11497 rm -f core conftest.err conftest.$ac_objext \
11499 if ${ac_cv_search_gethostbyname_r+:} false; then :
11503 if ${ac_cv_search_gethostbyname_r+:} false; then :
11506 ac_cv_search_gethostbyname_r=no
11508 rm conftest.$ac_ext
11509 LIBS=$ac_func_search_save_LIBS
11511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname_r" >&5
11512 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
11513 ac_res=$ac_cv_search_gethostbyname_r
11514 if test "$ac_res" != no; then :
11515 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing shmget" >&5
11521 $as_echo_n "checking for library containing shmget... " >&6; }
11522 if ${ac_cv_search_shmget+:} false; then :
11523 $as_echo_n "(cached) " >&6
11525 ac_func_search_save_LIBS=$LIBS
11526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11527 /* end confdefs.h. */
11529 /* Override any GCC internal prototype to avoid an error.
11530 Use char because int might match the return type of a GCC
11531 builtin and then its argument prototype would still apply. */
11544 for ac_lib in '' cygipc; do
11545 if test -z "$ac_lib"; then
11546 ac_res="none required"
11549 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11551 if ac_fn_c_try_link "$LINENO"; then :
11552 ac_cv_search_shmget=$ac_res
11554 rm -f core conftest.err conftest.$ac_objext \
11556 if ${ac_cv_search_shmget+:} false; then :
11560 if ${ac_cv_search_shmget+:} false; then :
11563 ac_cv_search_shmget=no
11565 rm conftest.$ac_ext
11566 LIBS=$ac_func_search_save_LIBS
11568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_shmget" >&5
11569 $as_echo "$ac_cv_search_shmget" >&6; }
11570 ac_res=$ac_cv_search_shmget
11571 if test "$ac_res" != no; then :
11572 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11577 if test "$with_readline" = yes; then
11580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing readline" >&5
11581 $as_echo_n "checking for library containing readline... " >&6; }
11582 if ${pgac_cv_check_readline+:} false; then :
11583 $as_echo_n "(cached) " >&6
11585 pgac_cv_check_readline=no
11586 pgac_save_LIBS=$LIBS
11587 if test x"$with_libedit_preferred" != x"yes"
11588 then READLINE_ORDER="-lreadline -ledit"
11589 else READLINE_ORDER="-ledit -lreadline"
11591 for pgac_rllib in $READLINE_ORDER ; do
11592 for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
11593 LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
11594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11595 /* end confdefs.h. */
11597 /* Override any GCC internal prototype to avoid an error.
11598 Use char because int might match the return type of a GCC
11599 builtin and then its argument prototype would still apply. */
11607 return readline ();
11612 if ac_fn_c_try_link "$LINENO"; then :
11614 # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
11615 # recognize dependent libraries; assume curses is needed if we didn't
11616 # find any dependency.
11618 netbsd* | openbsd* | irix*)
11619 if test x"$pgac_lib" = x"" ; then
11620 pgac_lib=" -lcurses"
11624 pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
11628 rm -f core conftest.err conftest.$ac_objext \
11629 conftest$ac_exeext conftest.$ac_ext
11631 if test "$pgac_cv_check_readline" != no ; then
11635 LIBS=$pgac_save_LIBS
11638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_readline" >&5
11639 $as_echo "$pgac_cv_check_readline" >&6; }
11640 if test "$pgac_cv_check_readline" != no ; then
11641 LIBS="$pgac_cv_check_readline $LIBS"
11643 $as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h
11648 if test x"$pgac_cv_check_readline" = x"no"; then
11649 as_fn_error $? "readline library not found
11650 If you have readline already installed, see config.log for details on the
11651 failure. It is possible the compiler isn't looking in the proper directory.
11652 Use --without-readline to disable readline support." "$LINENO" 5
11656 if test "$with_zlib" = yes; then
11657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflate in -lz" >&5
11658 $as_echo_n "checking for inflate in -lz... " >&6; }
11659 if ${ac_cv_lib_z_inflate+:} false; then :
11660 $as_echo_n "(cached) " >&6
11662 ac_check_lib_save_LIBS=$LIBS
11664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11665 /* end confdefs.h. */
11667 /* Override any GCC internal prototype to avoid an error.
11668 Use char because int might match the return type of a GCC
11669 builtin and then its argument prototype would still apply. */
11682 if ac_fn_c_try_link "$LINENO"; then :
11683 ac_cv_lib_z_inflate=yes
11685 ac_cv_lib_z_inflate=no
11687 rm -f core conftest.err conftest.$ac_objext \
11688 conftest$ac_exeext conftest.$ac_ext
11689 LIBS=$ac_check_lib_save_LIBS
11691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflate" >&5
11692 $as_echo "$ac_cv_lib_z_inflate" >&6; }
11693 if test "x$ac_cv_lib_z_inflate" = xyes; then :
11694 cat >>confdefs.h <<_ACEOF
11695 #define HAVE_LIBZ 1
11701 as_fn_error $? "zlib library not found
11702 If you have zlib already installed, see config.log for details on the
11703 failure. It is possible the compiler isn't looking in the proper directory.
11704 Use --without-zlib to disable zlib support." "$LINENO" 5
11709 if test "$enable_spinlocks" = yes; then
11711 $as_echo "#define HAVE_SPINLOCKS 1" >>confdefs.h
11714 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11715 *** Not using spinlocks will cause poor performance." >&5
11716 $as_echo "$as_me: WARNING:
11717 *** Not using spinlocks will cause poor performance." >&2;}
11720 if test "$enable_atomics" = yes; then
11722 $as_echo "#define HAVE_ATOMICS 1" >>confdefs.h
11725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
11726 *** Not using atomic operations will cause poor performance." >&5
11727 $as_echo "$as_me: WARNING:
11728 *** Not using atomic operations will cause poor performance." >&2;}
11731 if test "$with_gssapi" = yes ; then
11732 if test "$PORTNAME" != "win32"; then
11733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gss_init_sec_context" >&5
11734 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
11735 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11736 $as_echo_n "(cached) " >&6
11738 ac_func_search_save_LIBS=$LIBS
11739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11740 /* end confdefs.h. */
11742 /* Override any GCC internal prototype to avoid an error.
11743 Use char because int might match the return type of a GCC
11744 builtin and then its argument prototype would still apply. */
11748 char gss_init_sec_context ();
11752 return gss_init_sec_context ();
11757 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
11758 if test -z "$ac_lib"; then
11759 ac_res="none required"
11762 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11764 if ac_fn_c_try_link "$LINENO"; then :
11765 ac_cv_search_gss_init_sec_context=$ac_res
11767 rm -f core conftest.err conftest.$ac_objext \
11769 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11773 if ${ac_cv_search_gss_init_sec_context+:} false; then :
11776 ac_cv_search_gss_init_sec_context=no
11778 rm conftest.$ac_ext
11779 LIBS=$ac_func_search_save_LIBS
11781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gss_init_sec_context" >&5
11782 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
11783 ac_res=$ac_cv_search_gss_init_sec_context
11784 if test "$ac_res" != no; then :
11785 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11788 as_fn_error $? "could not find function 'gss_init_sec_context' required for GSSAPI" "$LINENO" 5
11792 LIBS="$LIBS -lgssapi32"
11796 if test "$with_openssl" = yes ; then
11797 if test "$PORTNAME" != "win32"; then
11798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CRYPTO_new_ex_data in -lcrypto" >&5
11799 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
11800 if ${ac_cv_lib_crypto_CRYPTO_new_ex_data+:} false; then :
11801 $as_echo_n "(cached) " >&6
11803 ac_check_lib_save_LIBS=$LIBS
11804 LIBS="-lcrypto $LIBS"
11805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11806 /* end confdefs.h. */
11808 /* Override any GCC internal prototype to avoid an error.
11809 Use char because int might match the return type of a GCC
11810 builtin and then its argument prototype would still apply. */
11814 char CRYPTO_new_ex_data ();
11818 return CRYPTO_new_ex_data ();
11823 if ac_fn_c_try_link "$LINENO"; then :
11824 ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
11826 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
11828 rm -f core conftest.err conftest.$ac_objext \
11829 conftest$ac_exeext conftest.$ac_ext
11830 LIBS=$ac_check_lib_save_LIBS
11832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
11833 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
11834 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = xyes; then :
11835 cat >>confdefs.h <<_ACEOF
11836 #define HAVE_LIBCRYPTO 1
11839 LIBS="-lcrypto $LIBS"
11842 as_fn_error $? "library 'crypto' is required for OpenSSL" "$LINENO" 5
11845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_new in -lssl" >&5
11846 $as_echo_n "checking for SSL_new in -lssl... " >&6; }
11847 if ${ac_cv_lib_ssl_SSL_new+:} false; then :
11848 $as_echo_n "(cached) " >&6
11850 ac_check_lib_save_LIBS=$LIBS
11852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11853 /* end confdefs.h. */
11855 /* Override any GCC internal prototype to avoid an error.
11856 Use char because int might match the return type of a GCC
11857 builtin and then its argument prototype would still apply. */
11870 if ac_fn_c_try_link "$LINENO"; then :
11871 ac_cv_lib_ssl_SSL_new=yes
11873 ac_cv_lib_ssl_SSL_new=no
11875 rm -f core conftest.err conftest.$ac_objext \
11876 conftest$ac_exeext conftest.$ac_ext
11877 LIBS=$ac_check_lib_save_LIBS
11879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_new" >&5
11880 $as_echo "$ac_cv_lib_ssl_SSL_new" >&6; }
11881 if test "x$ac_cv_lib_ssl_SSL_new" = xyes; then :
11882 cat >>confdefs.h <<_ACEOF
11883 #define HAVE_LIBSSL 1
11889 as_fn_error $? "library 'ssl' is required for OpenSSL" "$LINENO" 5
11893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing CRYPTO_new_ex_data" >&5
11894 $as_echo_n "checking for library containing CRYPTO_new_ex_data... " >&6; }
11895 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11896 $as_echo_n "(cached) " >&6
11898 ac_func_search_save_LIBS=$LIBS
11899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11900 /* end confdefs.h. */
11902 /* Override any GCC internal prototype to avoid an error.
11903 Use char because int might match the return type of a GCC
11904 builtin and then its argument prototype would still apply. */
11908 char CRYPTO_new_ex_data ();
11912 return CRYPTO_new_ex_data ();
11917 for ac_lib in '' eay32 crypto; do
11918 if test -z "$ac_lib"; then
11919 ac_res="none required"
11922 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11924 if ac_fn_c_try_link "$LINENO"; then :
11925 ac_cv_search_CRYPTO_new_ex_data=$ac_res
11927 rm -f core conftest.err conftest.$ac_objext \
11929 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11933 if ${ac_cv_search_CRYPTO_new_ex_data+:} false; then :
11936 ac_cv_search_CRYPTO_new_ex_data=no
11938 rm conftest.$ac_ext
11939 LIBS=$ac_func_search_save_LIBS
11941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_CRYPTO_new_ex_data" >&5
11942 $as_echo "$ac_cv_search_CRYPTO_new_ex_data" >&6; }
11943 ac_res=$ac_cv_search_CRYPTO_new_ex_data
11944 if test "$ac_res" != no; then :
11945 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
11948 as_fn_error $? "library 'eay32' or 'crypto' is required for OpenSSL" "$LINENO" 5
11951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing SSL_new" >&5
11952 $as_echo_n "checking for library containing SSL_new... " >&6; }
11953 if ${ac_cv_search_SSL_new+:} false; then :
11954 $as_echo_n "(cached) " >&6
11956 ac_func_search_save_LIBS=$LIBS
11957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11958 /* end confdefs.h. */
11960 /* Override any GCC internal prototype to avoid an error.
11961 Use char because int might match the return type of a GCC
11962 builtin and then its argument prototype would still apply. */
11975 for ac_lib in '' ssleay32 ssl; do
11976 if test -z "$ac_lib"; then
11977 ac_res="none required"
11980 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
11982 if ac_fn_c_try_link "$LINENO"; then :
11983 ac_cv_search_SSL_new=$ac_res
11985 rm -f core conftest.err conftest.$ac_objext \
11987 if ${ac_cv_search_SSL_new+:} false; then :
11991 if ${ac_cv_search_SSL_new+:} false; then :
11994 ac_cv_search_SSL_new=no
11996 rm conftest.$ac_ext
11997 LIBS=$ac_func_search_save_LIBS
11999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_SSL_new" >&5
12000 $as_echo "$ac_cv_search_SSL_new" >&6; }
12001 ac_res=$ac_cv_search_SSL_new
12002 if test "$ac_res" != no; then :
12003 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12006 as_fn_error $? "library 'ssleay32' or 'ssl' is required for OpenSSL" "$LINENO" 5
12010 for ac_func in SSL_clear_options SSL_get_current_compression X509_get_signature_nid
12012 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12013 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12014 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12015 cat >>confdefs.h <<_ACEOF
12016 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12022 # Functions introduced in OpenSSL 1.1.0. We used to check for
12023 # OPENSSL_VERSION_NUMBER, but that didn't work with 1.1.0, because LibreSSL
12024 # defines OPENSSL_VERSION_NUMBER to claim version 2.0.0, even though it
12025 # doesn't have these OpenSSL 1.1.0 functions. So check for individual
12027 for ac_func in OPENSSL_init_ssl BIO_get_data BIO_meth_new ASN1_STRING_get0_data RAND_OpenSSL
12029 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12030 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
12031 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
12032 cat >>confdefs.h <<_ACEOF
12033 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12039 # OpenSSL versions before 1.1.0 required setting callback functions, for
12040 # thread-safety. In 1.1.0, it's no longer required, and CRYPTO_lock()
12041 # function was removed.
12042 for ac_func in CRYPTO_lock
12044 ac_fn_c_check_func "$LINENO" "CRYPTO_lock" "ac_cv_func_CRYPTO_lock"
12045 if test "x$ac_cv_func_CRYPTO_lock" = xyes; then :
12046 cat >>confdefs.h <<_ACEOF
12047 #define HAVE_CRYPTO_LOCK 1
12055 if test "$with_pam" = yes ; then
12056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pam_start in -lpam" >&5
12057 $as_echo_n "checking for pam_start in -lpam... " >&6; }
12058 if ${ac_cv_lib_pam_pam_start+:} false; then :
12059 $as_echo_n "(cached) " >&6
12061 ac_check_lib_save_LIBS=$LIBS
12063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12064 /* end confdefs.h. */
12066 /* Override any GCC internal prototype to avoid an error.
12067 Use char because int might match the return type of a GCC
12068 builtin and then its argument prototype would still apply. */
12076 return pam_start ();
12081 if ac_fn_c_try_link "$LINENO"; then :
12082 ac_cv_lib_pam_pam_start=yes
12084 ac_cv_lib_pam_pam_start=no
12086 rm -f core conftest.err conftest.$ac_objext \
12087 conftest$ac_exeext conftest.$ac_ext
12088 LIBS=$ac_check_lib_save_LIBS
12090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_start" >&5
12091 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
12092 if test "x$ac_cv_lib_pam_pam_start" = xyes; then :
12093 cat >>confdefs.h <<_ACEOF
12094 #define HAVE_LIBPAM 1
12100 as_fn_error $? "library 'pam' is required for PAM" "$LINENO" 5
12105 if test "$with_libxml" = yes ; then
12106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xmlSaveToBuffer in -lxml2" >&5
12107 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
12108 if ${ac_cv_lib_xml2_xmlSaveToBuffer+:} false; then :
12109 $as_echo_n "(cached) " >&6
12111 ac_check_lib_save_LIBS=$LIBS
12112 LIBS="-lxml2 $LIBS"
12113 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12114 /* end confdefs.h. */
12116 /* Override any GCC internal prototype to avoid an error.
12117 Use char because int might match the return type of a GCC
12118 builtin and then its argument prototype would still apply. */
12122 char xmlSaveToBuffer ();
12126 return xmlSaveToBuffer ();
12131 if ac_fn_c_try_link "$LINENO"; then :
12132 ac_cv_lib_xml2_xmlSaveToBuffer=yes
12134 ac_cv_lib_xml2_xmlSaveToBuffer=no
12136 rm -f core conftest.err conftest.$ac_objext \
12137 conftest$ac_exeext conftest.$ac_ext
12138 LIBS=$ac_check_lib_save_LIBS
12140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
12141 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
12142 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = xyes; then :
12143 cat >>confdefs.h <<_ACEOF
12144 #define HAVE_LIBXML2 1
12147 LIBS="-lxml2 $LIBS"
12150 as_fn_error $? "library 'xml2' (version >= 2.6.23) is required for XML support" "$LINENO" 5
12155 if test "$with_libxslt" = yes ; then
12156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xsltCleanupGlobals in -lxslt" >&5
12157 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
12158 if ${ac_cv_lib_xslt_xsltCleanupGlobals+:} false; then :
12159 $as_echo_n "(cached) " >&6
12161 ac_check_lib_save_LIBS=$LIBS
12162 LIBS="-lxslt $LIBS"
12163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12164 /* end confdefs.h. */
12166 /* Override any GCC internal prototype to avoid an error.
12167 Use char because int might match the return type of a GCC
12168 builtin and then its argument prototype would still apply. */
12172 char xsltCleanupGlobals ();
12176 return xsltCleanupGlobals ();
12181 if ac_fn_c_try_link "$LINENO"; then :
12182 ac_cv_lib_xslt_xsltCleanupGlobals=yes
12184 ac_cv_lib_xslt_xsltCleanupGlobals=no
12186 rm -f core conftest.err conftest.$ac_objext \
12187 conftest$ac_exeext conftest.$ac_ext
12188 LIBS=$ac_check_lib_save_LIBS
12190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
12191 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
12192 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = xyes; then :
12193 cat >>confdefs.h <<_ACEOF
12194 #define HAVE_LIBXSLT 1
12197 LIBS="-lxslt $LIBS"
12200 as_fn_error $? "library 'xslt' is required for XSLT support" "$LINENO" 5
12205 # Note: We can test for libldap_r only after we know PTHREAD_LIBS
12206 if test "$with_ldap" = yes ; then
12208 if test "$PORTNAME" != "win32"; then
12209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lldap" >&5
12210 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
12211 if ${ac_cv_lib_ldap_ldap_bind+:} false; then :
12212 $as_echo_n "(cached) " >&6
12214 ac_check_lib_save_LIBS=$LIBS
12215 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
12216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12217 /* end confdefs.h. */
12219 /* Override any GCC internal prototype to avoid an error.
12220 Use char because int might match the return type of a GCC
12221 builtin and then its argument prototype would still apply. */
12229 return ldap_bind ();
12234 if ac_fn_c_try_link "$LINENO"; then :
12235 ac_cv_lib_ldap_ldap_bind=yes
12237 ac_cv_lib_ldap_ldap_bind=no
12239 rm -f core conftest.err conftest.$ac_objext \
12240 conftest$ac_exeext conftest.$ac_ext
12241 LIBS=$ac_check_lib_save_LIBS
12243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_ldap_bind" >&5
12244 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
12245 if test "x$ac_cv_lib_ldap_ldap_bind" = xyes; then :
12246 cat >>confdefs.h <<_ACEOF
12247 #define HAVE_LIBLDAP 1
12250 LIBS="-lldap $LIBS"
12253 as_fn_error $? "library 'ldap' is required for LDAP" "$LINENO" 5
12256 LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
12257 if test "$enable_thread_safety" = yes; then
12258 # on some platforms ldap_r fails to link without PTHREAD_LIBS
12259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_simple_bind in -lldap_r" >&5
12260 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
12261 if ${ac_cv_lib_ldap_r_ldap_simple_bind+:} false; then :
12262 $as_echo_n "(cached) " >&6
12264 ac_check_lib_save_LIBS=$LIBS
12265 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
12266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12267 /* end confdefs.h. */
12269 /* Override any GCC internal prototype to avoid an error.
12270 Use char because int might match the return type of a GCC
12271 builtin and then its argument prototype would still apply. */
12275 char ldap_simple_bind ();
12279 return ldap_simple_bind ();
12284 if ac_fn_c_try_link "$LINENO"; then :
12285 ac_cv_lib_ldap_r_ldap_simple_bind=yes
12287 ac_cv_lib_ldap_r_ldap_simple_bind=no
12289 rm -f core conftest.err conftest.$ac_objext \
12290 conftest$ac_exeext conftest.$ac_ext
12291 LIBS=$ac_check_lib_save_LIBS
12293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
12294 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
12295 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = xyes; then :
12296 cat >>confdefs.h <<_ACEOF
12297 #define HAVE_LIBLDAP_R 1
12300 LIBS="-lldap_r $LIBS"
12303 as_fn_error $? "library 'ldap_r' is required for LDAP" "$LINENO" 5
12306 LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
12308 LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
12310 for ac_func in ldap_initialize
12312 ac_fn_c_check_func "$LINENO" "ldap_initialize" "ac_cv_func_ldap_initialize"
12313 if test "x$ac_cv_func_ldap_initialize" = xyes; then :
12314 cat >>confdefs.h <<_ACEOF
12315 #define HAVE_LDAP_INITIALIZE 1
12322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_bind in -lwldap32" >&5
12323 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
12324 if ${ac_cv_lib_wldap32_ldap_bind+:} false; then :
12325 $as_echo_n "(cached) " >&6
12327 ac_check_lib_save_LIBS=$LIBS
12328 LIBS="-lwldap32 $LIBS"
12329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12330 /* end confdefs.h. */
12332 /* Override any GCC internal prototype to avoid an error.
12333 Use char because int might match the return type of a GCC
12334 builtin and then its argument prototype would still apply. */
12342 return ldap_bind ();
12347 if ac_fn_c_try_link "$LINENO"; then :
12348 ac_cv_lib_wldap32_ldap_bind=yes
12350 ac_cv_lib_wldap32_ldap_bind=no
12352 rm -f core conftest.err conftest.$ac_objext \
12353 conftest$ac_exeext conftest.$ac_ext
12354 LIBS=$ac_check_lib_save_LIBS
12356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_wldap32_ldap_bind" >&5
12357 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
12358 if test "x$ac_cv_lib_wldap32_ldap_bind" = xyes; then :
12359 cat >>confdefs.h <<_ACEOF
12360 #define HAVE_LIBWLDAP32 1
12363 LIBS="-lwldap32 $LIBS"
12366 as_fn_error $? "library 'wldap32' is required for LDAP" "$LINENO" 5
12369 LDAP_LIBS_FE="-lwldap32"
12370 LDAP_LIBS_BE="-lwldap32"
12377 # for contrib/sepgsql
12378 if test "$with_selinux" = yes; then
12379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for security_compute_create_name in -lselinux" >&5
12380 $as_echo_n "checking for security_compute_create_name in -lselinux... " >&6; }
12381 if ${ac_cv_lib_selinux_security_compute_create_name+:} false; then :
12382 $as_echo_n "(cached) " >&6
12384 ac_check_lib_save_LIBS=$LIBS
12385 LIBS="-lselinux $LIBS"
12386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12387 /* end confdefs.h. */
12389 /* Override any GCC internal prototype to avoid an error.
12390 Use char because int might match the return type of a GCC
12391 builtin and then its argument prototype would still apply. */
12395 char security_compute_create_name ();
12399 return security_compute_create_name ();
12404 if ac_fn_c_try_link "$LINENO"; then :
12405 ac_cv_lib_selinux_security_compute_create_name=yes
12407 ac_cv_lib_selinux_security_compute_create_name=no
12409 rm -f core conftest.err conftest.$ac_objext \
12410 conftest$ac_exeext conftest.$ac_ext
12411 LIBS=$ac_check_lib_save_LIBS
12413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_security_compute_create_name" >&5
12414 $as_echo "$ac_cv_lib_selinux_security_compute_create_name" >&6; }
12415 if test "x$ac_cv_lib_selinux_security_compute_create_name" = xyes; then :
12416 cat >>confdefs.h <<_ACEOF
12417 #define HAVE_LIBSELINUX 1
12420 LIBS="-lselinux $LIBS"
12423 as_fn_error $? "library 'libselinux', version 2.1.10 or newer, is required for SELinux support" "$LINENO" 5
12428 # for contrib/uuid-ossp
12429 if test "$with_uuid" = bsd ; then
12430 # On BSD, the UUID functions are in libc
12431 ac_fn_c_check_func "$LINENO" "uuid_to_string" "ac_cv_func_uuid_to_string"
12432 if test "x$ac_cv_func_uuid_to_string" = xyes; then :
12435 as_fn_error $? "BSD UUID functions are not present" "$LINENO" 5
12438 elif test "$with_uuid" = e2fs ; then
12439 # On macOS, the UUID functions are in libc
12440 ac_fn_c_check_func "$LINENO" "uuid_generate" "ac_cv_func_uuid_generate"
12441 if test "x$ac_cv_func_uuid_generate" = xyes; then :
12444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
12445 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
12446 if ${ac_cv_lib_uuid_uuid_generate+:} false; then :
12447 $as_echo_n "(cached) " >&6
12449 ac_check_lib_save_LIBS=$LIBS
12450 LIBS="-luuid $LIBS"
12451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12452 /* end confdefs.h. */
12454 /* Override any GCC internal prototype to avoid an error.
12455 Use char because int might match the return type of a GCC
12456 builtin and then its argument prototype would still apply. */
12460 char uuid_generate ();
12464 return uuid_generate ();
12469 if ac_fn_c_try_link "$LINENO"; then :
12470 ac_cv_lib_uuid_uuid_generate=yes
12472 ac_cv_lib_uuid_uuid_generate=no
12474 rm -f core conftest.err conftest.$ac_objext \
12475 conftest$ac_exeext conftest.$ac_ext
12476 LIBS=$ac_check_lib_save_LIBS
12478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
12479 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
12480 if test "x$ac_cv_lib_uuid_uuid_generate" = xyes; then :
12483 as_fn_error $? "library 'uuid' is required for E2FS UUID" "$LINENO" 5
12488 elif test "$with_uuid" = ossp ; then
12489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -lossp-uuid" >&5
12490 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
12491 if ${ac_cv_lib_ossp_uuid_uuid_export+:} false; then :
12492 $as_echo_n "(cached) " >&6
12494 ac_check_lib_save_LIBS=$LIBS
12495 LIBS="-lossp-uuid $LIBS"
12496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12497 /* end confdefs.h. */
12499 /* Override any GCC internal prototype to avoid an error.
12500 Use char because int might match the return type of a GCC
12501 builtin and then its argument prototype would still apply. */
12505 char uuid_export ();
12509 return uuid_export ();
12514 if ac_fn_c_try_link "$LINENO"; then :
12515 ac_cv_lib_ossp_uuid_uuid_export=yes
12517 ac_cv_lib_ossp_uuid_uuid_export=no
12519 rm -f core conftest.err conftest.$ac_objext \
12520 conftest$ac_exeext conftest.$ac_ext
12521 LIBS=$ac_check_lib_save_LIBS
12523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
12524 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
12525 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = xyes; then :
12526 UUID_LIBS="-lossp-uuid"
12528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_export in -luuid" >&5
12529 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
12530 if ${ac_cv_lib_uuid_uuid_export+:} false; then :
12531 $as_echo_n "(cached) " >&6
12533 ac_check_lib_save_LIBS=$LIBS
12534 LIBS="-luuid $LIBS"
12535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12536 /* end confdefs.h. */
12538 /* Override any GCC internal prototype to avoid an error.
12539 Use char because int might match the return type of a GCC
12540 builtin and then its argument prototype would still apply. */
12544 char uuid_export ();
12548 return uuid_export ();
12553 if ac_fn_c_try_link "$LINENO"; then :
12554 ac_cv_lib_uuid_uuid_export=yes
12556 ac_cv_lib_uuid_uuid_export=no
12558 rm -f core conftest.err conftest.$ac_objext \
12559 conftest$ac_exeext conftest.$ac_ext
12560 LIBS=$ac_check_lib_save_LIBS
12562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_export" >&5
12563 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
12564 if test "x$ac_cv_lib_uuid_uuid_export" = xyes; then :
12567 as_fn_error $? "library 'ossp-uuid' or 'uuid' is required for OSSP UUID" "$LINENO" 5
12580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
12581 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
12582 if ${ac_cv_header_stdbool_h+:} false; then :
12583 $as_echo_n "(cached) " >&6
12585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12586 /* end confdefs.h. */
12588 #include <stdbool.h>
12590 "error: bool is not defined"
12593 "error: false is not defined"
12596 "error: false is not 0"
12599 "error: true is not defined"
12602 "error: true is not 1"
12604 #ifndef __bool_true_false_are_defined
12605 "error: __bool_true_false_are_defined is not defined"
12608 struct s { _Bool s: 1; _Bool t; } s;
12610 char a[true == 1 ? 1 : -1];
12611 char b[false == 0 ? 1 : -1];
12612 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
12613 char d[(bool) 0.5 == true ? 1 : -1];
12614 /* See body of main program for 'e'. */
12615 char f[(_Bool) 0.0 == false ? 1 : -1];
12617 char h[sizeof (_Bool)];
12618 char i[sizeof s.t];
12619 enum { j = false, k = true, l = false * true, m = true * 256 };
12620 /* The following fails for
12621 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
12623 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
12624 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
12625 /* Catch a bug in an HP-UX C compiler. See
12626 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
12627 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
12639 /* Refer to every declared value, to avoid compiler optimizations. */
12640 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
12641 + !m + !n + !o + !p + !q + !pq);
12647 if ac_fn_c_try_compile "$LINENO"; then :
12648 ac_cv_header_stdbool_h=yes
12650 ac_cv_header_stdbool_h=no
12652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
12655 $as_echo "$ac_cv_header_stdbool_h" >&6; }
12656 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
12657 if test "x$ac_cv_type__Bool" = xyes; then :
12659 cat >>confdefs.h <<_ACEOF
12660 #define HAVE__BOOL 1
12667 if test $ac_cv_header_stdbool_h = yes; then
12669 $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
12674 for ac_header in atomic.h crypt.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h mbarrier.h poll.h sys/epoll.h sys/ipc.h sys/prctl.h sys/procctl.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/sockio.h sys/tas.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h
12676 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12677 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12678 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
12679 cat >>confdefs.h <<_ACEOF
12680 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12688 # On BSD, test for net/if.h will fail unless sys/socket.h
12689 # is included first.
12690 for ac_header in net/if.h
12692 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
12693 #include <sys/socket.h>
12696 if test "x$ac_cv_header_net_if_h" = xyes; then :
12697 cat >>confdefs.h <<_ACEOF
12698 #define HAVE_NET_IF_H 1
12706 # On OpenBSD, test for sys/ucred.h will fail unless sys/param.h
12707 # is included first.
12708 for ac_header in sys/ucred.h
12710 ac_fn_c_check_header_compile "$LINENO" "sys/ucred.h" "ac_cv_header_sys_ucred_h" "$ac_includes_default
12711 #include <sys/param.h>
12714 if test "x$ac_cv_header_sys_ucred_h" = xyes; then :
12715 cat >>confdefs.h <<_ACEOF
12716 #define HAVE_SYS_UCRED_H 1
12724 # At least on IRIX, test for netinet/tcp.h will fail unless
12725 # netinet/in.h is included first.
12726 for ac_header in netinet/tcp.h
12728 ac_fn_c_check_header_compile "$LINENO" "netinet/tcp.h" "ac_cv_header_netinet_tcp_h" "$ac_includes_default
12729 #include <netinet/in.h>
12732 if test "x$ac_cv_header_netinet_tcp_h" = xyes; then :
12733 cat >>confdefs.h <<_ACEOF
12734 #define HAVE_NETINET_TCP_H 1
12742 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
12743 for ac_header in readline/readline.h
12745 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12746 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12747 cat >>confdefs.h <<_ACEOF
12748 #define HAVE_READLINE_READLINE_H 1
12752 for ac_header in readline.h
12754 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12755 if test "x$ac_cv_header_readline_h" = xyes; then :
12756 cat >>confdefs.h <<_ACEOF
12757 #define HAVE_READLINE_H 1
12761 as_fn_error $? "readline header not found
12762 If you have readline already installed, see config.log for details on the
12763 failure. It is possible the compiler isn't looking in the proper directory.
12764 Use --without-readline to disable readline support." "$LINENO" 5
12773 for ac_header in readline/history.h
12775 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
12776 if test "x$ac_cv_header_readline_history_h" = xyes; then :
12777 cat >>confdefs.h <<_ACEOF
12778 #define HAVE_READLINE_HISTORY_H 1
12782 for ac_header in history.h
12784 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12785 if test "x$ac_cv_header_history_h" = xyes; then :
12786 cat >>confdefs.h <<_ACEOF
12787 #define HAVE_HISTORY_H 1
12791 as_fn_error $? "history header not found
12792 If you have readline already installed, see config.log for details on the
12793 failure. It is possible the compiler isn't looking in the proper directory.
12794 Use --without-readline to disable readline support." "$LINENO" 5
12805 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
12806 # Some installations of libedit usurp /usr/include/readline/, which seems
12807 # bad practice, since in combined installations readline will have its headers
12808 # there. We might have to resort to AC_EGREP checks to make sure we found
12809 # the proper header...
12810 for ac_header in editline/readline.h
12812 ac_fn_c_check_header_mongrel "$LINENO" "editline/readline.h" "ac_cv_header_editline_readline_h" "$ac_includes_default"
12813 if test "x$ac_cv_header_editline_readline_h" = xyes; then :
12814 cat >>confdefs.h <<_ACEOF
12815 #define HAVE_EDITLINE_READLINE_H 1
12819 for ac_header in readline.h
12821 ac_fn_c_check_header_mongrel "$LINENO" "readline.h" "ac_cv_header_readline_h" "$ac_includes_default"
12822 if test "x$ac_cv_header_readline_h" = xyes; then :
12823 cat >>confdefs.h <<_ACEOF
12824 #define HAVE_READLINE_H 1
12828 for ac_header in readline/readline.h
12830 ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_readline_readline_h" "$ac_includes_default"
12831 if test "x$ac_cv_header_readline_readline_h" = xyes; then :
12832 cat >>confdefs.h <<_ACEOF
12833 #define HAVE_READLINE_READLINE_H 1
12837 as_fn_error $? "readline header not found
12838 If you have libedit already installed, see config.log for details on the
12839 failure. It is possible the compiler isn't looking in the proper directory.
12840 Use --without-readline to disable libedit support." "$LINENO" 5
12853 # Note: in a libedit installation, history.h is sometimes a dummy, and may
12854 # not be there at all. Hence, don't complain if not found. We must check
12855 # though, since in yet other versions it is an independent header.
12856 for ac_header in editline/history.h
12858 ac_fn_c_check_header_mongrel "$LINENO" "editline/history.h" "ac_cv_header_editline_history_h" "$ac_includes_default"
12859 if test "x$ac_cv_header_editline_history_h" = xyes; then :
12860 cat >>confdefs.h <<_ACEOF
12861 #define HAVE_EDITLINE_HISTORY_H 1
12865 for ac_header in history.h
12867 ac_fn_c_check_header_mongrel "$LINENO" "history.h" "ac_cv_header_history_h" "$ac_includes_default"
12868 if test "x$ac_cv_header_history_h" = xyes; then :
12869 cat >>confdefs.h <<_ACEOF
12870 #define HAVE_HISTORY_H 1
12874 for ac_header in readline/history.h
12876 ac_fn_c_check_header_mongrel "$LINENO" "readline/history.h" "ac_cv_header_readline_history_h" "$ac_includes_default"
12877 if test "x$ac_cv_header_readline_history_h" = xyes; then :
12878 cat >>confdefs.h <<_ACEOF
12879 #define HAVE_READLINE_HISTORY_H 1
12896 if test "$with_zlib" = yes; then
12897 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
12898 if test "x$ac_cv_header_zlib_h" = xyes; then :
12901 as_fn_error $? "zlib header not found
12902 If you have zlib already installed, see config.log for details on the
12903 failure. It is possible the compiler isn't looking in the proper directory.
12904 Use --without-zlib to disable zlib support." "$LINENO" 5
12910 if test "$with_gssapi" = yes ; then
12911 for ac_header in gssapi/gssapi.h
12913 ac_fn_c_check_header_mongrel "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default"
12914 if test "x$ac_cv_header_gssapi_gssapi_h" = xyes; then :
12915 cat >>confdefs.h <<_ACEOF
12916 #define HAVE_GSSAPI_GSSAPI_H 1
12920 for ac_header in gssapi.h
12922 ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
12923 if test "x$ac_cv_header_gssapi_h" = xyes; then :
12924 cat >>confdefs.h <<_ACEOF
12925 #define HAVE_GSSAPI_H 1
12929 as_fn_error $? "gssapi.h header file is required for GSSAPI" "$LINENO" 5
12940 if test "$with_openssl" = yes ; then
12941 ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
12942 if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
12945 as_fn_error $? "header file <openssl/ssl.h> is required for OpenSSL" "$LINENO" 5
12949 ac_fn_c_check_header_mongrel "$LINENO" "openssl/err.h" "ac_cv_header_openssl_err_h" "$ac_includes_default"
12950 if test "x$ac_cv_header_openssl_err_h" = xyes; then :
12953 as_fn_error $? "header file <openssl/err.h> is required for OpenSSL" "$LINENO" 5
12959 if test "$with_pam" = yes ; then
12960 for ac_header in security/pam_appl.h
12962 ac_fn_c_check_header_mongrel "$LINENO" "security/pam_appl.h" "ac_cv_header_security_pam_appl_h" "$ac_includes_default"
12963 if test "x$ac_cv_header_security_pam_appl_h" = xyes; then :
12964 cat >>confdefs.h <<_ACEOF
12965 #define HAVE_SECURITY_PAM_APPL_H 1
12969 for ac_header in pam/pam_appl.h
12971 ac_fn_c_check_header_mongrel "$LINENO" "pam/pam_appl.h" "ac_cv_header_pam_pam_appl_h" "$ac_includes_default"
12972 if test "x$ac_cv_header_pam_pam_appl_h" = xyes; then :
12973 cat >>confdefs.h <<_ACEOF
12974 #define HAVE_PAM_PAM_APPL_H 1
12978 as_fn_error $? "header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." "$LINENO" 5
12989 if test "$with_bsd_auth" = yes ; then
12990 ac_fn_c_check_header_mongrel "$LINENO" "bsd_auth.h" "ac_cv_header_bsd_auth_h" "$ac_includes_default"
12991 if test "x$ac_cv_header_bsd_auth_h" = xyes; then :
12994 as_fn_error $? "header file <bsd_auth.h> is required for BSD Authentication support" "$LINENO" 5
13000 if test "$with_systemd" = yes ; then
13001 ac_fn_c_check_header_mongrel "$LINENO" "systemd/sd-daemon.h" "ac_cv_header_systemd_sd_daemon_h" "$ac_includes_default"
13002 if test "x$ac_cv_header_systemd_sd_daemon_h" = xyes; then :
13005 as_fn_error $? "header file <systemd/sd-daemon.h> is required for systemd support" "$LINENO" 5
13011 if test "$with_libxml" = yes ; then
13012 ac_fn_c_check_header_mongrel "$LINENO" "libxml/parser.h" "ac_cv_header_libxml_parser_h" "$ac_includes_default"
13013 if test "x$ac_cv_header_libxml_parser_h" = xyes; then :
13016 as_fn_error $? "header file <libxml/parser.h> is required for XML support" "$LINENO" 5
13022 if test "$with_libxslt" = yes ; then
13023 ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xslt.h" "ac_cv_header_libxslt_xslt_h" "$ac_includes_default"
13024 if test "x$ac_cv_header_libxslt_xslt_h" = xyes; then :
13027 as_fn_error $? "header file <libxslt/xslt.h> is required for XSLT support" "$LINENO" 5
13033 if test "$with_ldap" = yes ; then
13034 if test "$PORTNAME" != "win32"; then
13035 for ac_header in ldap.h
13037 ac_fn_c_check_header_mongrel "$LINENO" "ldap.h" "ac_cv_header_ldap_h" "$ac_includes_default"
13038 if test "x$ac_cv_header_ldap_h" = xyes; then :
13039 cat >>confdefs.h <<_ACEOF
13040 #define HAVE_LDAP_H 1
13044 as_fn_error $? "header file <ldap.h> is required for LDAP" "$LINENO" 5
13049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compatible LDAP implementation" >&5
13050 $as_echo_n "checking for compatible LDAP implementation... " >&6; }
13051 if ${pgac_cv_ldap_safe+:} false; then :
13052 $as_echo_n "(cached) " >&6
13054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13055 /* end confdefs.h. */
13057 #if !defined(LDAP_VENDOR_VERSION) || \
13058 (defined(LDAP_API_FEATURE_X_OPENLDAP) && \
13059 LDAP_VENDOR_VERSION >= 20424 && LDAP_VENDOR_VERSION <= 20431)
13070 if ac_fn_c_try_compile "$LINENO"; then :
13071 pgac_cv_ldap_safe=yes
13073 pgac_cv_ldap_safe=no
13075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_ldap_safe" >&5
13078 $as_echo "$pgac_cv_ldap_safe" >&6; }
13080 if test "$pgac_cv_ldap_safe" != yes; then
13081 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
13082 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
13083 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
13084 *** also uses LDAP will crash on exit." >&5
13085 $as_echo "$as_me: WARNING:
13086 *** With OpenLDAP versions 2.4.24 through 2.4.31, inclusive, each backend
13087 *** process that loads libpq (via WAL receiver, dblink, or postgres_fdw) and
13088 *** also uses LDAP will crash on exit." >&2;}
13091 for ac_header in winldap.h
13093 ac_fn_c_check_header_compile "$LINENO" "winldap.h" "ac_cv_header_winldap_h" "$ac_includes_default
13094 #include <windows.h>
13097 if test "x$ac_cv_header_winldap_h" = xyes; then :
13098 cat >>confdefs.h <<_ACEOF
13099 #define HAVE_WINLDAP_H 1
13103 as_fn_error $? "header file <winldap.h> is required for LDAP" "$LINENO" 5
13111 if test "$with_bonjour" = yes ; then
13112 ac_fn_c_check_header_mongrel "$LINENO" "dns_sd.h" "ac_cv_header_dns_sd_h" "$ac_includes_default"
13113 if test "x$ac_cv_header_dns_sd_h" = xyes; then :
13116 as_fn_error $? "header file <dns_sd.h> is required for Bonjour" "$LINENO" 5
13122 # for contrib/uuid-ossp
13123 if test "$with_uuid" = bsd ; then
13124 for ac_header in uuid.h
13126 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13127 if test "x$ac_cv_header_uuid_h" = xyes; then :
13128 cat >>confdefs.h <<_ACEOF
13129 #define HAVE_UUID_H 1
13131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13132 /* end confdefs.h. */
13136 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13137 $EGREP "uuid_to_string" >/dev/null 2>&1; then :
13140 as_fn_error $? "header file <uuid.h> does not match BSD UUID library" "$LINENO" 5
13145 as_fn_error $? "header file <uuid.h> is required for BSD UUID" "$LINENO" 5
13150 elif test "$with_uuid" = e2fs ; then
13151 for ac_header in uuid/uuid.h
13153 ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
13154 if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
13155 cat >>confdefs.h <<_ACEOF
13156 #define HAVE_UUID_UUID_H 1
13158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13159 /* end confdefs.h. */
13160 #include <uuid/uuid.h>
13163 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13164 $EGREP "uuid_generate" >/dev/null 2>&1; then :
13167 as_fn_error $? "header file <uuid/uuid.h> does not match E2FS UUID library" "$LINENO" 5
13172 for ac_header in uuid.h
13174 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13175 if test "x$ac_cv_header_uuid_h" = xyes; then :
13176 cat >>confdefs.h <<_ACEOF
13177 #define HAVE_UUID_H 1
13179 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13180 /* end confdefs.h. */
13184 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13185 $EGREP "uuid_generate" >/dev/null 2>&1; then :
13188 as_fn_error $? "header file <uuid.h> does not match E2FS UUID library" "$LINENO" 5
13193 as_fn_error $? "header file <uuid/uuid.h> or <uuid.h> is required for E2FS UUID" "$LINENO" 5
13202 elif test "$with_uuid" = ossp ; then
13203 for ac_header in ossp/uuid.h
13205 ac_fn_c_check_header_mongrel "$LINENO" "ossp/uuid.h" "ac_cv_header_ossp_uuid_h" "$ac_includes_default"
13206 if test "x$ac_cv_header_ossp_uuid_h" = xyes; then :
13207 cat >>confdefs.h <<_ACEOF
13208 #define HAVE_OSSP_UUID_H 1
13210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13211 /* end confdefs.h. */
13212 #include <ossp/uuid.h>
13215 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13216 $EGREP "uuid_export" >/dev/null 2>&1; then :
13219 as_fn_error $? "header file <ossp/uuid.h> does not match OSSP UUID library" "$LINENO" 5
13224 for ac_header in uuid.h
13226 ac_fn_c_check_header_mongrel "$LINENO" "uuid.h" "ac_cv_header_uuid_h" "$ac_includes_default"
13227 if test "x$ac_cv_header_uuid_h" = xyes; then :
13228 cat >>confdefs.h <<_ACEOF
13229 #define HAVE_UUID_H 1
13231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13232 /* end confdefs.h. */
13236 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13237 $EGREP "uuid_export" >/dev/null 2>&1; then :
13240 as_fn_error $? "header file <uuid.h> does not match OSSP UUID library" "$LINENO" 5
13245 as_fn_error $? "header file <ossp/uuid.h> or <uuid.h> is required for OSSP UUID" "$LINENO" 5
13256 if test "$PORTNAME" = "win32" ; then
13257 for ac_header in crtdefs.h
13259 ac_fn_c_check_header_mongrel "$LINENO" "crtdefs.h" "ac_cv_header_crtdefs_h" "$ac_includes_default"
13260 if test "x$ac_cv_header_crtdefs_h" = xyes; then :
13261 cat >>confdefs.h <<_ACEOF
13262 #define HAVE_CRTDEFS_H 1
13272 ## Types, structures, compiler characteristics
13275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
13276 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13277 if ${ac_cv_c_bigendian+:} false; then :
13278 $as_echo_n "(cached) " >&6
13280 ac_cv_c_bigendian=unknown
13281 # See if we're dealing with a universal compiler.
13282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13283 /* end confdefs.h. */
13284 #ifndef __APPLE_CC__
13285 not a universal capable compiler
13290 if ac_fn_c_try_compile "$LINENO"; then :
13292 # Check for potential -arch flags. It is not universal unless
13293 # there are at least two -arch flags with different values.
13296 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13297 if test -n "$ac_prev"; then
13299 i?86 | x86_64 | ppc | ppc64)
13300 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
13303 ac_cv_c_bigendian=universal
13309 elif test "x$ac_word" = "x-arch"; then
13314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13315 if test $ac_cv_c_bigendian = unknown; then
13316 # See if sys/param.h defines the BYTE_ORDER macro.
13317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13318 /* end confdefs.h. */
13319 #include <sys/types.h>
13320 #include <sys/param.h>
13325 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13326 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13328 bogus endian macros
13335 if ac_fn_c_try_compile "$LINENO"; then :
13336 # It does; now see whether it defined to BIG_ENDIAN or not.
13337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13338 /* end confdefs.h. */
13339 #include <sys/types.h>
13340 #include <sys/param.h>
13345 #if BYTE_ORDER != BIG_ENDIAN
13353 if ac_fn_c_try_compile "$LINENO"; then :
13354 ac_cv_c_bigendian=yes
13356 ac_cv_c_bigendian=no
13358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13360 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13362 if test $ac_cv_c_bigendian = unknown; then
13363 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
13364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13365 /* end confdefs.h. */
13366 #include <limits.h>
13371 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
13372 bogus endian macros
13379 if ac_fn_c_try_compile "$LINENO"; then :
13380 # It does; now see whether it defined to _BIG_ENDIAN or not.
13381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13382 /* end confdefs.h. */
13383 #include <limits.h>
13388 #ifndef _BIG_ENDIAN
13396 if ac_fn_c_try_compile "$LINENO"; then :
13397 ac_cv_c_bigendian=yes
13399 ac_cv_c_bigendian=no
13401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13405 if test $ac_cv_c_bigendian = unknown; then
13406 # Compile a test program.
13407 if test "$cross_compiling" = yes; then :
13408 # Try to guess by grepping values from an object file.
13409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13410 /* end confdefs.h. */
13411 short int ascii_mm[] =
13412 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
13413 short int ascii_ii[] =
13414 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
13415 int use_ascii (int i) {
13416 return ascii_mm[i] + ascii_ii[i];
13418 short int ebcdic_ii[] =
13419 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
13420 short int ebcdic_mm[] =
13421 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
13422 int use_ebcdic (int i) {
13423 return ebcdic_mm[i] + ebcdic_ii[i];
13430 return use_ascii (foo) == use_ebcdic (foo);
13435 if ac_fn_c_try_compile "$LINENO"; then :
13436 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
13437 ac_cv_c_bigendian=yes
13439 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
13440 if test "$ac_cv_c_bigendian" = unknown; then
13441 ac_cv_c_bigendian=no
13443 # finding both strings is unlikely to happen, but who knows?
13444 ac_cv_c_bigendian=unknown
13448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13451 /* end confdefs.h. */
13452 $ac_includes_default
13457 /* Are we little or big endian? From Harbison&Steele. */
13461 char c[sizeof (long int)];
13464 return u.c[sizeof (long int) - 1] == 1;
13470 if ac_fn_c_try_run "$LINENO"; then :
13471 ac_cv_c_bigendian=no
13473 ac_cv_c_bigendian=yes
13475 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13476 conftest.$ac_objext conftest.beam conftest.$ac_ext
13481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
13482 $as_echo "$ac_cv_c_bigendian" >&6; }
13483 case $ac_cv_c_bigendian in #(
13485 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
13491 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
13495 as_fn_error $? "unknown endianness
13496 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
13499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
13500 $as_echo_n "checking for inline... " >&6; }
13501 if ${ac_cv_c_inline+:} false; then :
13502 $as_echo_n "(cached) " >&6
13505 for ac_kw in inline __inline__ __inline; do
13506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13507 /* end confdefs.h. */
13508 #ifndef __cplusplus
13510 static $ac_kw foo_t static_foo () {return 0; }
13511 $ac_kw foo_t foo () {return 0; }
13515 if ac_fn_c_try_compile "$LINENO"; then :
13516 ac_cv_c_inline=$ac_kw
13518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13519 test "$ac_cv_c_inline" != no && break
13523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
13524 $as_echo "$ac_cv_c_inline" >&6; }
13526 case $ac_cv_c_inline in
13529 case $ac_cv_c_inline in
13531 *) ac_val=$ac_cv_c_inline;;
13533 cat >>confdefs.h <<_ACEOF
13534 #ifndef __cplusplus
13535 #define inline $ac_val
13541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf format archetype" >&5
13542 $as_echo_n "checking for printf format archetype... " >&6; }
13543 if ${pgac_cv_printf_archetype+:} false; then :
13544 $as_echo_n "(cached) " >&6
13546 ac_save_c_werror_flag=$ac_c_werror_flag
13547 ac_c_werror_flag=yes
13548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13549 /* end confdefs.h. */
13551 pgac_write(int ignore, const char *fmt,...)
13552 __attribute__((format(gnu_printf, 2, 3)));
13561 if ac_fn_c_try_compile "$LINENO"; then :
13562 pgac_cv_printf_archetype=gnu_printf
13564 pgac_cv_printf_archetype=printf
13566 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13567 ac_c_werror_flag=$ac_save_c_werror_flag
13569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_printf_archetype" >&5
13570 $as_echo "$pgac_cv_printf_archetype" >&6; }
13572 cat >>confdefs.h <<_ACEOF
13573 #define PG_PRINTF_ATTRIBUTE $pgac_cv_printf_archetype
13578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for flexible array members" >&5
13579 $as_echo_n "checking for flexible array members... " >&6; }
13580 if ${ac_cv_c_flexmember+:} false; then :
13581 $as_echo_n "(cached) " >&6
13583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13584 /* end confdefs.h. */
13585 #include <stdlib.h>
13587 #include <stddef.h>
13588 struct s { int n; double d[]; };
13592 int m = getchar ();
13593 struct s *p = malloc (offsetof (struct s, d)
13594 + m * sizeof (double));
13596 return p->d != (double *) NULL;
13601 if ac_fn_c_try_compile "$LINENO"; then :
13602 ac_cv_c_flexmember=yes
13604 ac_cv_c_flexmember=no
13606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
13609 $as_echo "$ac_cv_c_flexmember" >&6; }
13610 if test $ac_cv_c_flexmember = yes; then
13612 $as_echo "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
13615 $as_echo "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
13619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signed types" >&5
13620 $as_echo_n "checking for signed types... " >&6; }
13621 if ${pgac_cv_c_signed+:} false; then :
13622 $as_echo_n "(cached) " >&6
13624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13625 /* end confdefs.h. */
13630 signed char c; signed short s; signed int i;
13635 if ac_fn_c_try_compile "$LINENO"; then :
13636 pgac_cv_c_signed=yes
13638 pgac_cv_c_signed=no
13640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_signed" >&5
13643 $as_echo "$pgac_cv_c_signed" >&6; }
13644 if test x"$pgac_cv_c_signed" = xno ; then
13646 $as_echo "#define signed /**/" >>confdefs.h
13649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __func__" >&5
13650 $as_echo_n "checking for __func__... " >&6; }
13651 if ${pgac_cv_funcname_func_support+:} false; then :
13652 $as_echo_n "(cached) " >&6
13654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13655 /* end confdefs.h. */
13660 printf("%s\n", __func__);
13665 if ac_fn_c_try_compile "$LINENO"; then :
13666 pgac_cv_funcname_func_support=yes
13668 pgac_cv_funcname_func_support=no
13670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_func_support" >&5
13673 $as_echo "$pgac_cv_funcname_func_support" >&6; }
13674 if test x"$pgac_cv_funcname_func_support" = xyes ; then
13676 $as_echo "#define HAVE_FUNCNAME__FUNC 1" >>confdefs.h
13679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __FUNCTION__" >&5
13680 $as_echo_n "checking for __FUNCTION__... " >&6; }
13681 if ${pgac_cv_funcname_function_support+:} false; then :
13682 $as_echo_n "(cached) " >&6
13684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13685 /* end confdefs.h. */
13690 printf("%s\n", __FUNCTION__);
13695 if ac_fn_c_try_compile "$LINENO"; then :
13696 pgac_cv_funcname_function_support=yes
13698 pgac_cv_funcname_function_support=no
13700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_funcname_function_support" >&5
13703 $as_echo "$pgac_cv_funcname_function_support" >&6; }
13704 if test x"$pgac_cv_funcname_function_support" = xyes ; then
13706 $as_echo "#define HAVE_FUNCNAME__FUNCTION 1" >>confdefs.h
13710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Static_assert" >&5
13711 $as_echo_n "checking for _Static_assert... " >&6; }
13712 if ${pgac_cv__static_assert+:} false; then :
13713 $as_echo_n "(cached) " >&6
13715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13716 /* end confdefs.h. */
13721 ({ _Static_assert(1, "foo"); })
13726 if ac_fn_c_try_link "$LINENO"; then :
13727 pgac_cv__static_assert=yes
13729 pgac_cv__static_assert=no
13731 rm -f core conftest.err conftest.$ac_objext \
13732 conftest$ac_exeext conftest.$ac_ext
13734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__static_assert" >&5
13735 $as_echo "$pgac_cv__static_assert" >&6; }
13736 if test x"$pgac_cv__static_assert" = xyes ; then
13738 $as_echo "#define HAVE__STATIC_ASSERT 1" >>confdefs.h
13741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for typeof" >&5
13742 $as_echo_n "checking for typeof... " >&6; }
13743 if ${pgac_cv_c_typeof+:} false; then :
13744 $as_echo_n "(cached) " >&6
13746 pgac_cv_c_typeof=no
13747 for pgac_kw in typeof __typeof__ decltype; do
13748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13749 /* end confdefs.h. */
13762 if ac_fn_c_try_compile "$LINENO"; then :
13763 pgac_cv_c_typeof=$pgac_kw
13765 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13766 test "$pgac_cv_c_typeof" != no && break
13769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_c_typeof" >&5
13770 $as_echo "$pgac_cv_c_typeof" >&6; }
13771 if test "$pgac_cv_c_typeof" != no; then
13773 $as_echo "#define HAVE_TYPEOF 1" >>confdefs.h
13775 if test "$pgac_cv_c_typeof" != typeof; then
13777 cat >>confdefs.h <<_ACEOF
13778 #define typeof $pgac_cv_c_typeof
13783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_types_compatible_p" >&5
13784 $as_echo_n "checking for __builtin_types_compatible_p... " >&6; }
13785 if ${pgac_cv__types_compatible+:} false; then :
13786 $as_echo_n "(cached) " >&6
13788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13789 /* end confdefs.h. */
13794 int x; static int y[__builtin_types_compatible_p(__typeof__(x), int)];
13799 if ac_fn_c_try_compile "$LINENO"; then :
13800 pgac_cv__types_compatible=yes
13802 pgac_cv__types_compatible=no
13804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__types_compatible" >&5
13807 $as_echo "$pgac_cv__types_compatible" >&6; }
13808 if test x"$pgac_cv__types_compatible" = xyes ; then
13810 $as_echo "#define HAVE__BUILTIN_TYPES_COMPATIBLE_P 1" >>confdefs.h
13813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap16" >&5
13814 $as_echo_n "checking for __builtin_bswap16... " >&6; }
13815 if ${pgac_cv__builtin_bswap16+:} false; then :
13816 $as_echo_n "(cached) " >&6
13818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13819 /* end confdefs.h. */
13820 static unsigned long int x = __builtin_bswap16(0xaabb);
13823 if ac_fn_c_try_compile "$LINENO"; then :
13824 pgac_cv__builtin_bswap16=yes
13826 pgac_cv__builtin_bswap16=no
13828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap16" >&5
13831 $as_echo "$pgac_cv__builtin_bswap16" >&6; }
13832 if test x"$pgac_cv__builtin_bswap16" = xyes ; then
13834 $as_echo "#define HAVE__BUILTIN_BSWAP16 1" >>confdefs.h
13837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap32" >&5
13838 $as_echo_n "checking for __builtin_bswap32... " >&6; }
13839 if ${pgac_cv__builtin_bswap32+:} false; then :
13840 $as_echo_n "(cached) " >&6
13842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13843 /* end confdefs.h. */
13844 static unsigned long int x = __builtin_bswap32(0xaabbccdd);
13847 if ac_fn_c_try_compile "$LINENO"; then :
13848 pgac_cv__builtin_bswap32=yes
13850 pgac_cv__builtin_bswap32=no
13852 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap32" >&5
13855 $as_echo "$pgac_cv__builtin_bswap32" >&6; }
13856 if test x"$pgac_cv__builtin_bswap32" = xyes ; then
13858 $as_echo "#define HAVE__BUILTIN_BSWAP32 1" >>confdefs.h
13861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_bswap64" >&5
13862 $as_echo_n "checking for __builtin_bswap64... " >&6; }
13863 if ${pgac_cv__builtin_bswap64+:} false; then :
13864 $as_echo_n "(cached) " >&6
13866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13867 /* end confdefs.h. */
13868 static unsigned long int x = __builtin_bswap64(0xaabbccddeeff0011);
13871 if ac_fn_c_try_compile "$LINENO"; then :
13872 pgac_cv__builtin_bswap64=yes
13874 pgac_cv__builtin_bswap64=no
13876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_bswap64" >&5
13879 $as_echo "$pgac_cv__builtin_bswap64" >&6; }
13880 if test x"$pgac_cv__builtin_bswap64" = xyes ; then
13882 $as_echo "#define HAVE__BUILTIN_BSWAP64 1" >>confdefs.h
13885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_constant_p" >&5
13886 $as_echo_n "checking for __builtin_constant_p... " >&6; }
13887 if ${pgac_cv__builtin_constant_p+:} false; then :
13888 $as_echo_n "(cached) " >&6
13890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13891 /* end confdefs.h. */
13893 static int y[__builtin_constant_p(x) ? x : 1];
13894 static int z[__builtin_constant_p("string literal") ? 1 : x];
13898 if ac_fn_c_try_compile "$LINENO"; then :
13899 pgac_cv__builtin_constant_p=yes
13901 pgac_cv__builtin_constant_p=no
13903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_constant_p" >&5
13906 $as_echo "$pgac_cv__builtin_constant_p" >&6; }
13907 if test x"$pgac_cv__builtin_constant_p" = xyes ; then
13909 $as_echo "#define HAVE__BUILTIN_CONSTANT_P 1" >>confdefs.h
13912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unreachable" >&5
13913 $as_echo_n "checking for __builtin_unreachable... " >&6; }
13914 if ${pgac_cv__builtin_unreachable+:} false; then :
13915 $as_echo_n "(cached) " >&6
13917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13918 /* end confdefs.h. */
13923 __builtin_unreachable();
13928 if ac_fn_c_try_link "$LINENO"; then :
13929 pgac_cv__builtin_unreachable=yes
13931 pgac_cv__builtin_unreachable=no
13933 rm -f core conftest.err conftest.$ac_objext \
13934 conftest$ac_exeext conftest.$ac_ext
13936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_unreachable" >&5
13937 $as_echo "$pgac_cv__builtin_unreachable" >&6; }
13938 if test x"$pgac_cv__builtin_unreachable" = xyes ; then
13940 $as_echo "#define HAVE__BUILTIN_UNREACHABLE 1" >>confdefs.h
13943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for computed goto support" >&5
13944 $as_echo_n "checking for computed goto support... " >&6; }
13945 if ${pgac_cv_computed_goto+:} false; then :
13946 $as_echo_n "(cached) " >&6
13948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13949 /* end confdefs.h. */
13954 void *labeladdrs[] = {&&my_label};
13955 goto *labeladdrs[0];
13963 if ac_fn_c_try_compile "$LINENO"; then :
13964 pgac_cv_computed_goto=yes
13966 pgac_cv_computed_goto=no
13968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_computed_goto" >&5
13971 $as_echo "$pgac_cv_computed_goto" >&6; }
13972 if test x"$pgac_cv_computed_goto" = xyes ; then
13974 $as_echo "#define HAVE_COMPUTED_GOTO 1" >>confdefs.h
13977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __VA_ARGS__" >&5
13978 $as_echo_n "checking for __VA_ARGS__... " >&6; }
13979 if ${pgac_cv__va_args+:} false; then :
13980 $as_echo_n "(cached) " >&6
13982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13983 /* end confdefs.h. */
13988 #define debug(...) fprintf(stderr, __VA_ARGS__)
13989 debug("%s", "blarg");
13995 if ac_fn_c_try_compile "$LINENO"; then :
13996 pgac_cv__va_args=yes
13998 pgac_cv__va_args=no
14000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__va_args" >&5
14003 $as_echo "$pgac_cv__va_args" >&6; }
14004 if test x"$pgac_cv__va_args" = xyes ; then
14006 $as_echo "#define HAVE__VA_ARGS 1" >>confdefs.h
14009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
14010 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14011 if ${ac_cv_struct_tm+:} false; then :
14012 $as_echo_n "(cached) " >&6
14014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14015 /* end confdefs.h. */
14016 #include <sys/types.h>
14023 int *p = &tm.tm_sec;
14029 if ac_fn_c_try_compile "$LINENO"; then :
14030 ac_cv_struct_tm=time.h
14032 ac_cv_struct_tm=sys/time.h
14034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
14037 $as_echo "$ac_cv_struct_tm" >&6; }
14038 if test $ac_cv_struct_tm = sys/time.h; then
14040 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
14044 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
14045 #include <$ac_cv_struct_tm>
14048 if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
14050 cat >>confdefs.h <<_ACEOF
14051 #define HAVE_STRUCT_TM_TM_ZONE 1
14057 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
14059 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
14062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
14063 $as_echo_n "checking for tzname... " >&6; }
14064 if ${ac_cv_var_tzname+:} false; then :
14065 $as_echo_n "(cached) " >&6
14067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14068 /* end confdefs.h. */
14069 #include <stdlib.h>
14071 #ifndef tzname /* For SGI. */
14072 extern char *tzname[]; /* RS6000 and others reject char **tzname. */
14083 if ac_fn_c_try_link "$LINENO"; then :
14084 ac_cv_var_tzname=yes
14086 ac_cv_var_tzname=no
14088 rm -f core conftest.err conftest.$ac_objext \
14089 conftest$ac_exeext conftest.$ac_ext
14091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
14092 $as_echo "$ac_cv_var_tzname" >&6; }
14093 if test $ac_cv_var_tzname = yes; then
14095 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
14099 ac_fn_c_check_type "$LINENO" "union semun" "ac_cv_type_union_semun" "#include <sys/types.h>
14100 #ifdef HAVE_SYS_IPC_H
14101 #include <sys/ipc.h>
14103 #ifdef HAVE_SYS_SEM_H
14104 #include <sys/sem.h>
14107 if test "x$ac_cv_type_union_semun" = xyes; then :
14109 cat >>confdefs.h <<_ACEOF
14110 #define HAVE_UNION_SEMUN 1
14116 ac_fn_c_check_type "$LINENO" "struct sockaddr_un" "ac_cv_type_struct_sockaddr_un" "#include <sys/types.h>
14117 #ifdef HAVE_SYS_UN_H
14118 #include <sys/un.h>
14122 if test "x$ac_cv_type_struct_sockaddr_un" = xyes; then :
14124 $as_echo "#define HAVE_UNIX_SOCKETS 1" >>confdefs.h
14128 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "#include <sys/types.h>
14129 #include <sys/socket.h>
14132 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
14134 cat >>confdefs.h <<_ACEOF
14135 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
14141 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
14142 #include <sys/socket.h>
14145 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then :
14147 cat >>confdefs.h <<_ACEOF
14148 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
14153 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_family" "ac_cv_member_struct_sockaddr_storage___ss_family" "#include <sys/types.h>
14154 #include <sys/socket.h>
14157 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = xyes; then :
14159 cat >>confdefs.h <<_ACEOF
14160 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
14165 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_len" "ac_cv_member_struct_sockaddr_storage_ss_len" "#include <sys/types.h>
14166 #include <sys/socket.h>
14169 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = xyes; then :
14171 cat >>confdefs.h <<_ACEOF
14172 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
14177 ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "__ss_len" "ac_cv_member_struct_sockaddr_storage___ss_len" "#include <sys/types.h>
14178 #include <sys/socket.h>
14181 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = xyes; then :
14183 cat >>confdefs.h <<_ACEOF
14184 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
14189 ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "#include <sys/types.h>
14190 #include <sys/socket.h>
14193 if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes; then :
14195 cat >>confdefs.h <<_ACEOF
14196 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
14202 ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "#include <sys/types.h>
14203 #include <sys/socket.h>
14207 if test "x$ac_cv_type_struct_addrinfo" = xyes; then :
14209 cat >>confdefs.h <<_ACEOF
14210 #define HAVE_STRUCT_ADDRINFO 1
14217 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
14218 if test "x$ac_cv_type_intptr_t" = xyes; then :
14220 $as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h
14223 for ac_type in 'int' 'long int' 'long long int'; do
14224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14225 /* end confdefs.h. */
14226 $ac_includes_default
14230 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14231 test_array [0] = 0;
14232 return test_array [0];
14238 if ac_fn_c_try_compile "$LINENO"; then :
14240 cat >>confdefs.h <<_ACEOF
14241 #define intptr_t $ac_type
14246 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14247 test -z "$ac_type" && break
14253 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
14254 if test "x$ac_cv_type_uintptr_t" = xyes; then :
14256 $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
14259 for ac_type in 'unsigned int' 'unsigned long int' \
14260 'unsigned long long int'; do
14261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14262 /* end confdefs.h. */
14263 $ac_includes_default
14267 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
14268 test_array [0] = 0;
14269 return test_array [0];
14275 if ac_fn_c_try_compile "$LINENO"; then :
14277 cat >>confdefs.h <<_ACEOF
14278 #define uintptr_t $ac_type
14283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14284 test -z "$ac_type" && break
14290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
14291 $as_echo_n "checking for unsigned long long int... " >&6; }
14292 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
14293 $as_echo_n "(cached) " >&6
14295 ac_cv_type_unsigned_long_long_int=yes
14296 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14298 /* end confdefs.h. */
14300 /* For now, do not test the preprocessor; as of 2007 there are too many
14301 implementations with broken preprocessors. Perhaps this can
14302 be revisited in 2012. In the meantime, code should not expect
14303 #if to work with literals wider than 32 bits. */
14304 /* Test literals. */
14305 long long int ll = 9223372036854775807ll;
14306 long long int nll = -9223372036854775807LL;
14307 unsigned long long int ull = 18446744073709551615ULL;
14308 /* Test constant expressions. */
14309 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
14311 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
14317 /* Test availability of runtime routines for shift and division. */
14318 long long int llmax = 9223372036854775807ll;
14319 unsigned long long int ullmax = 18446744073709551615ull;
14320 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
14321 | (llmax / ll) | (llmax % ll)
14322 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
14323 | (ullmax / ull) | (ullmax % ull));
14329 if ac_fn_c_try_link "$LINENO"; then :
14332 ac_cv_type_unsigned_long_long_int=no
14334 rm -f core conftest.err conftest.$ac_objext \
14335 conftest$ac_exeext conftest.$ac_ext
14338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
14339 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
14340 if test $ac_cv_type_unsigned_long_long_int = yes; then
14342 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
14348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
14349 $as_echo_n "checking for long long int... " >&6; }
14350 if ${ac_cv_type_long_long_int+:} false; then :
14351 $as_echo_n "(cached) " >&6
14353 ac_cv_type_long_long_int=yes
14354 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14355 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
14356 if test $ac_cv_type_long_long_int = yes; then
14357 if test "$cross_compiling" = yes; then :
14360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14361 /* end confdefs.h. */
14362 #include <limits.h>
14365 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
14366 # define LLONG_MAX (HALF - 1 + HALF)
14371 long long int n = 1;
14375 long long int m = n << i;
14378 if (LLONG_MAX / 2 < m)
14386 if ac_fn_c_try_run "$LINENO"; then :
14389 ac_cv_type_long_long_int=no
14391 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14392 conftest.$ac_objext conftest.beam conftest.$ac_ext
14398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
14399 $as_echo "$ac_cv_type_long_long_int" >&6; }
14400 if test $ac_cv_type_long_long_int = yes; then
14402 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
14407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t" >&5
14408 $as_echo_n "checking for locale_t... " >&6; }
14409 if ${pgac_cv_type_locale_t+:} false; then :
14410 $as_echo_n "(cached) " >&6
14412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14413 /* end confdefs.h. */
14414 #include <locale.h>
14424 if ac_fn_c_try_compile "$LINENO"; then :
14425 pgac_cv_type_locale_t=yes
14427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14428 /* end confdefs.h. */
14429 #include <xlocale.h>
14439 if ac_fn_c_try_compile "$LINENO"; then :
14440 pgac_cv_type_locale_t='yes (in xlocale.h)'
14442 pgac_cv_type_locale_t=no
14444 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14446 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_locale_t" >&5
14449 $as_echo "$pgac_cv_type_locale_t" >&6; }
14450 if test "$pgac_cv_type_locale_t" != no; then
14452 $as_echo "#define HAVE_LOCALE_T 1" >>confdefs.h
14455 if test "$pgac_cv_type_locale_t" = 'yes (in xlocale.h)'; then
14457 $as_echo "#define LOCALE_T_IN_XLOCALE 1" >>confdefs.h
14461 # MSVC doesn't cope well with defining restrict to __restrict, the
14462 # spelling it understands, because it conflicts with
14463 # __declspec(restrict). Therefore we define pg_restrict to the
14464 # appropriate definition, which presumably won't conflict.
14466 # Allow platforms with buggy compilers to force restrict to not be
14467 # used by setting $FORCE_DISABLE_RESTRICT=yes in the relevant
14469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
14470 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
14471 if ${ac_cv_c_restrict+:} false; then :
14472 $as_echo_n "(cached) " >&6
14474 ac_cv_c_restrict=no
14475 # The order here caters to the fact that C++ does not require restrict.
14476 for ac_kw in __restrict __restrict__ _Restrict restrict; do
14477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14478 /* end confdefs.h. */
14479 typedef int * int_ptr;
14480 int foo (int_ptr $ac_kw ip) {
14487 int * $ac_kw t = s;
14494 if ac_fn_c_try_compile "$LINENO"; then :
14495 ac_cv_c_restrict=$ac_kw
14497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14498 test "$ac_cv_c_restrict" != no && break
14502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
14503 $as_echo "$ac_cv_c_restrict" >&6; }
14505 case $ac_cv_c_restrict in
14507 no) $as_echo "#define restrict /**/" >>confdefs.h
14509 *) cat >>confdefs.h <<_ACEOF
14510 #define restrict $ac_cv_c_restrict
14515 if test "$ac_cv_c_restrict" = "no" -o "x$FORCE_DISABLE_RESTRICT" = "xyes"; then
14518 pg_restrict="$ac_cv_c_restrict"
14521 cat >>confdefs.h <<_ACEOF
14522 #define pg_restrict $pg_restrict
14526 ac_fn_c_check_type "$LINENO" "struct cmsgcred" "ac_cv_type_struct_cmsgcred" "#include <sys/socket.h>
14527 #include <sys/param.h>
14528 #ifdef HAVE_SYS_UCRED_H
14529 #include <sys/ucred.h>
14532 if test "x$ac_cv_type_struct_cmsgcred" = xyes; then :
14534 cat >>confdefs.h <<_ACEOF
14535 #define HAVE_STRUCT_CMSGCRED 1
14542 ac_fn_c_check_type "$LINENO" "struct option" "ac_cv_type_struct_option" "#ifdef HAVE_GETOPT_H
14543 #include <getopt.h>
14546 if test "x$ac_cv_type_struct_option" = xyes; then :
14548 cat >>confdefs.h <<_ACEOF
14549 #define HAVE_STRUCT_OPTION 1
14556 if test "$with_zlib" = yes; then
14557 # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
14558 # did not). While we could work around the lack of z_streamp, it
14559 # seems unwise to encourage people to use such old zlib versions...
14560 ac_fn_c_check_type "$LINENO" "z_streamp" "ac_cv_type_z_streamp" "#include <zlib.h>
14562 if test "x$ac_cv_type_z_streamp" = xyes; then :
14565 as_fn_error $? "zlib version is too old
14566 Use --without-zlib to disable zlib support." "$LINENO" 5
14571 # On PPC, check if assembler supports LWARX instruction's mutex hint bit
14574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether assembler supports lwarx hint bit" >&5
14575 $as_echo_n "checking whether assembler supports lwarx hint bit... " >&6; }
14576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14577 /* end confdefs.h. */
14582 int a = 0; int *p = &a; int r;
14583 __asm__ __volatile__ (" lwarx %0,0,%1,1\n" : "=&r"(r) : "r"(p));
14588 if ac_fn_c_try_compile "$LINENO"; then :
14589 pgac_cv_have_ppc_mutex_hint=yes
14591 pgac_cv_have_ppc_mutex_hint=no
14593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_have_ppc_mutex_hint" >&5
14595 $as_echo "$pgac_cv_have_ppc_mutex_hint" >&6; }
14596 if test x"$pgac_cv_have_ppc_mutex_hint" = xyes ; then
14598 $as_echo "#define HAVE_PPC_LWARX_MUTEX_HINT 1" >>confdefs.h
14604 # Check largefile support. You might think this is a system service not a
14605 # compiler characteristic, but you'd be wrong. We must check this before
14606 # probing existence of related functions such as fseeko, since the largefile
14607 # defines can affect what is generated for that.
14608 if test "$PORTNAME" != "win32"; then
14609 # Check whether --enable-largefile was given.
14610 if test "${enable_largefile+set}" = set; then :
14611 enableval=$enable_largefile;
14614 if test "$enable_largefile" != no; then
14616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
14617 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
14618 if ${ac_cv_sys_largefile_CC+:} false; then :
14619 $as_echo_n "(cached) " >&6
14621 ac_cv_sys_largefile_CC=no
14622 if test "$GCC" != yes; then
14625 # IRIX 6.2 and later do not support large files by default,
14626 # so use the C compiler's -n32 option if that helps.
14627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14628 /* end confdefs.h. */
14629 #include <sys/types.h>
14630 /* Check that off_t can represent 2**63 - 1 correctly.
14631 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14632 since some C++ compilers masquerading as C compilers
14633 incorrectly reject 9223372036854775807. */
14634 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14635 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14636 && LARGE_OFF_T % 2147483647 == 1)
14646 if ac_fn_c_try_compile "$LINENO"; then :
14649 rm -f core conftest.err conftest.$ac_objext
14651 if ac_fn_c_try_compile "$LINENO"; then :
14652 ac_cv_sys_largefile_CC=' -n32'; break
14654 rm -f core conftest.err conftest.$ac_objext
14658 rm -f conftest.$ac_ext
14661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
14662 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
14663 if test "$ac_cv_sys_largefile_CC" != no; then
14664 CC=$CC$ac_cv_sys_largefile_CC
14667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
14668 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
14669 if ${ac_cv_sys_file_offset_bits+:} false; then :
14670 $as_echo_n "(cached) " >&6
14673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14674 /* end confdefs.h. */
14675 #include <sys/types.h>
14676 /* Check that off_t can represent 2**63 - 1 correctly.
14677 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14678 since some C++ compilers masquerading as C compilers
14679 incorrectly reject 9223372036854775807. */
14680 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14681 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14682 && LARGE_OFF_T % 2147483647 == 1)
14692 if ac_fn_c_try_compile "$LINENO"; then :
14693 ac_cv_sys_file_offset_bits=no; break
14695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14697 /* end confdefs.h. */
14698 #define _FILE_OFFSET_BITS 64
14699 #include <sys/types.h>
14700 /* Check that off_t can represent 2**63 - 1 correctly.
14701 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14702 since some C++ compilers masquerading as C compilers
14703 incorrectly reject 9223372036854775807. */
14704 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14705 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14706 && LARGE_OFF_T % 2147483647 == 1)
14716 if ac_fn_c_try_compile "$LINENO"; then :
14717 ac_cv_sys_file_offset_bits=64; break
14719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14720 ac_cv_sys_file_offset_bits=unknown
14724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
14725 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
14726 case $ac_cv_sys_file_offset_bits in #(
14729 cat >>confdefs.h <<_ACEOF
14730 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
14735 if test $ac_cv_sys_file_offset_bits = unknown; then
14736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
14737 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
14738 if ${ac_cv_sys_large_files+:} false; then :
14739 $as_echo_n "(cached) " >&6
14742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14743 /* end confdefs.h. */
14744 #include <sys/types.h>
14745 /* Check that off_t can represent 2**63 - 1 correctly.
14746 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14747 since some C++ compilers masquerading as C compilers
14748 incorrectly reject 9223372036854775807. */
14749 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14750 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14751 && LARGE_OFF_T % 2147483647 == 1)
14761 if ac_fn_c_try_compile "$LINENO"; then :
14762 ac_cv_sys_large_files=no; break
14764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14766 /* end confdefs.h. */
14767 #define _LARGE_FILES 1
14768 #include <sys/types.h>
14769 /* Check that off_t can represent 2**63 - 1 correctly.
14770 We can't simply define LARGE_OFF_T to be 9223372036854775807,
14771 since some C++ compilers masquerading as C compilers
14772 incorrectly reject 9223372036854775807. */
14773 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
14774 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
14775 && LARGE_OFF_T % 2147483647 == 1)
14785 if ac_fn_c_try_compile "$LINENO"; then :
14786 ac_cv_sys_large_files=1; break
14788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14789 ac_cv_sys_large_files=unknown
14793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
14794 $as_echo "$ac_cv_sys_large_files" >&6; }
14795 case $ac_cv_sys_large_files in #(
14798 cat >>confdefs.h <<_ACEOF
14799 #define _LARGE_FILES $ac_cv_sys_large_files
14812 # Check for largefile support (must be after AC_SYS_LARGEFILE)
14813 # The cast to long int works around a bug in the HP C Compiler
14814 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14815 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14816 # This bug is HP SR number 8606223364.
14817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
14818 $as_echo_n "checking size of off_t... " >&6; }
14819 if ${ac_cv_sizeof_off_t+:} false; then :
14820 $as_echo_n "(cached) " >&6
14822 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then :
14825 if test "$ac_cv_type_off_t" = yes; then
14826 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14827 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14828 as_fn_error 77 "cannot compute sizeof (off_t)
14829 See \`config.log' for more details" "$LINENO" 5; }
14831 ac_cv_sizeof_off_t=0
14836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
14837 $as_echo "$ac_cv_sizeof_off_t" >&6; }
14841 cat >>confdefs.h <<_ACEOF
14842 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
14847 # If we don't have largefile support, can't handle segsize >= 2GB.
14848 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
14849 as_fn_error $? "Large file support is not enabled. Segment size cannot be larger than 1GB." "$LINENO" 5
14852 # The cast to long int works around a bug in the HP C Compiler
14853 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14854 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14855 # This bug is HP SR number 8606223364.
14856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of bool" >&5
14857 $as_echo_n "checking size of bool... " >&6; }
14858 if ${ac_cv_sizeof_bool+:} false; then :
14859 $as_echo_n "(cached) " >&6
14861 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (bool))" "ac_cv_sizeof_bool" "#ifdef HAVE_STDBOOL_H
14862 #include <stdbool.h>
14867 if test "$ac_cv_type_bool" = yes; then
14868 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14869 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14870 as_fn_error 77 "cannot compute sizeof (bool)
14871 See \`config.log' for more details" "$LINENO" 5; }
14873 ac_cv_sizeof_bool=0
14878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_bool" >&5
14879 $as_echo "$ac_cv_sizeof_bool" >&6; }
14883 cat >>confdefs.h <<_ACEOF
14884 #define SIZEOF_BOOL $ac_cv_sizeof_bool
14891 ## Functions, global variables
14894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int timezone" >&5
14895 $as_echo_n "checking for int timezone... " >&6; }
14896 if ${pgac_cv_var_int_timezone+:} false; then :
14897 $as_echo_n "(cached) " >&6
14899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14900 /* end confdefs.h. */
14907 res = timezone / 60;
14909 res = _timezone / 60;
14915 if ac_fn_c_try_link "$LINENO"; then :
14916 pgac_cv_var_int_timezone=yes
14918 pgac_cv_var_int_timezone=no
14920 rm -f core conftest.err conftest.$ac_objext \
14921 conftest$ac_exeext conftest.$ac_ext
14923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_timezone" >&5
14924 $as_echo "$pgac_cv_var_int_timezone" >&6; }
14925 if test x"$pgac_cv_var_int_timezone" = xyes ; then
14927 $as_echo "#define HAVE_INT_TIMEZONE 1" >>confdefs.h
14930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for accept()" >&5
14931 $as_echo_n "checking types of arguments for accept()... " >&6; }
14932 if ${ac_cv_func_accept_return+:} false; then :
14933 $as_echo_n "(cached) " >&6
14935 if ${ac_cv_func_accept_arg1+:} false; then :
14936 $as_echo_n "(cached) " >&6
14938 if ${ac_cv_func_accept_arg2+:} false; then :
14939 $as_echo_n "(cached) " >&6
14941 if ${ac_cv_func_accept_arg3+:} false; then :
14942 $as_echo_n "(cached) " >&6
14944 for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL' 'SOCKET WSAAPI'; do
14945 for ac_cv_func_accept_arg1 in 'int' 'unsigned int' 'SOCKET'; do
14946 for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
14947 for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
14948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14949 /* end confdefs.h. */
14950 #include <sys/types.h>
14951 #include <sys/socket.h>
14952 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
14954 if ac_fn_c_try_compile "$LINENO"; then :
14955 ac_not_found=no; break 4
14959 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14964 if test "$ac_not_found" = yes; then
14965 as_fn_error $? "could not determine argument types" "$LINENO" 5
14967 if test "$ac_cv_func_accept_arg3" = "void"; then
14968 ac_cv_func_accept_arg3=int
14978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&5
14979 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
14981 cat >>confdefs.h <<_ACEOF
14982 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
14986 cat >>confdefs.h <<_ACEOF
14987 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
14991 cat >>confdefs.h <<_ACEOF
14992 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
14996 cat >>confdefs.h <<_ACEOF
14997 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
15001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday takes only one argument" >&5
15002 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
15003 if ${pgac_cv_func_gettimeofday_1arg+:} false; then :
15004 $as_echo_n "(cached) " >&6
15006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15007 /* end confdefs.h. */
15008 #include <sys/time.h>
15012 struct timeval *tp;
15013 struct timezone *tzp;
15014 gettimeofday(tp,tzp);
15019 if ac_fn_c_try_compile "$LINENO"; then :
15020 pgac_cv_func_gettimeofday_1arg=no
15022 pgac_cv_func_gettimeofday_1arg=yes
15024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_gettimeofday_1arg" >&5
15027 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
15028 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
15030 $as_echo "#define GETTIMEOFDAY_1ARG 1" >>confdefs.h
15034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcstombs_l declaration" >&5
15035 $as_echo_n "checking for wcstombs_l declaration... " >&6; }
15036 if ${pgac_cv_func_wcstombs_l+:} false; then :
15037 $as_echo_n "(cached) " >&6
15039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15040 /* end confdefs.h. */
15041 #include <stdlib.h>
15042 #include <locale.h>
15053 if ac_fn_c_try_compile "$LINENO"; then :
15054 pgac_cv_func_wcstombs_l='yes'
15056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15057 /* end confdefs.h. */
15058 #include <stdlib.h>
15059 #include <locale.h>
15060 #include <xlocale.h>
15071 if ac_fn_c_try_compile "$LINENO"; then :
15072 pgac_cv_func_wcstombs_l='yes (in xlocale.h)'
15074 pgac_cv_func_wcstombs_l='no'
15076 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15078 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_func_wcstombs_l" >&5
15081 $as_echo "$pgac_cv_func_wcstombs_l" >&6; }
15082 if test "$pgac_cv_func_wcstombs_l" = 'yes (in xlocale.h)'; then
15084 $as_echo "#define WCSTOMBS_L_IN_XLOCALE 1" >>confdefs.h
15088 # Some versions of libedit contain strlcpy(), setproctitle(), and other
15089 # symbols that that library has no business exposing to the world. Pending
15090 # acquisition of a clue by those developers, ignore libedit (including its
15091 # possible alias of libreadline) while checking for everything else.
15092 LIBS_including_readline="$LIBS"
15093 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
15095 for ac_func in cbrt clock_gettime dlopen fdatasync getifaddrs getpeerucred getrlimit mbstowcs_l memmove poll posix_fallocate pstat pthread_is_threaded_np readlink setproctitle setproctitle_fast setsid shm_open symlink sync_file_range utime utimes wcstombs_l
15097 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15098 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15099 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15100 cat >>confdefs.h <<_ACEOF
15101 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15108 ac_fn_c_check_func "$LINENO" "fseeko" "ac_cv_func_fseeko"
15109 if test "x$ac_cv_func_fseeko" = xyes; then :
15110 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15113 case " $LIBOBJS " in
15114 *" fseeko.$ac_objext "* ) ;;
15115 *) LIBOBJS="$LIBOBJS fseeko.$ac_objext"
15123 # NetBSD uses a custom fseeko/ftello built on fsetpos/fgetpos
15124 # Mingw uses macros to access Win32 API calls
15127 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15129 ac_cv_func_fseeko=yes;;
15131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15132 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15133 if ${ac_cv_sys_largefile_source+:} false; then :
15134 $as_echo_n "(cached) " >&6
15137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15138 /* end confdefs.h. */
15139 #include <sys/types.h> /* for off_t */
15144 int (*fp) (FILE *, off_t, int) = fseeko;
15145 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15150 if ac_fn_c_try_link "$LINENO"; then :
15151 ac_cv_sys_largefile_source=no; break
15153 rm -f core conftest.err conftest.$ac_objext \
15154 conftest$ac_exeext conftest.$ac_ext
15155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15156 /* end confdefs.h. */
15157 #define _LARGEFILE_SOURCE 1
15158 #include <sys/types.h> /* for off_t */
15163 int (*fp) (FILE *, off_t, int) = fseeko;
15164 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15169 if ac_fn_c_try_link "$LINENO"; then :
15170 ac_cv_sys_largefile_source=1; break
15172 rm -f core conftest.err conftest.$ac_objext \
15173 conftest$ac_exeext conftest.$ac_ext
15174 ac_cv_sys_largefile_source=unknown
15178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15179 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15180 case $ac_cv_sys_largefile_source in #(
15183 cat >>confdefs.h <<_ACEOF
15184 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15190 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15191 # in glibc 2.1.3, but that breaks too many other things.
15192 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15193 if test $ac_cv_sys_largefile_source != unknown; then
15195 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15201 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
15202 # by calling it, 2009-04-02
15203 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
15204 if test "$PORTNAME" != "solaris"; then
15205 for ac_func in posix_fadvise
15207 ac_fn_c_check_func "$LINENO" "posix_fadvise" "ac_cv_func_posix_fadvise"
15208 if test "x$ac_cv_func_posix_fadvise" = xyes; then :
15209 cat >>confdefs.h <<_ACEOF
15210 #define HAVE_POSIX_FADVISE 1
15216 ac_fn_c_check_decl "$LINENO" "posix_fadvise" "ac_cv_have_decl_posix_fadvise" "#include <fcntl.h>
15218 if test "x$ac_cv_have_decl_posix_fadvise" = xyes; then :
15224 cat >>confdefs.h <<_ACEOF
15225 #define HAVE_DECL_POSIX_FADVISE $ac_have_decl
15230 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "#include <unistd.h>
15232 if test "x$ac_cv_have_decl_fdatasync" = xyes; then :
15238 cat >>confdefs.h <<_ACEOF
15239 #define HAVE_DECL_FDATASYNC $ac_have_decl
15242 ac_fn_c_check_decl "$LINENO" "strlcat" "ac_cv_have_decl_strlcat" "$ac_includes_default"
15243 if test "x$ac_cv_have_decl_strlcat" = xyes; then :
15249 cat >>confdefs.h <<_ACEOF
15250 #define HAVE_DECL_STRLCAT $ac_have_decl
15252 ac_fn_c_check_decl "$LINENO" "strlcpy" "ac_cv_have_decl_strlcpy" "$ac_includes_default"
15253 if test "x$ac_cv_have_decl_strlcpy" = xyes; then :
15259 cat >>confdefs.h <<_ACEOF
15260 #define HAVE_DECL_STRLCPY $ac_have_decl
15262 ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
15263 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
15269 cat >>confdefs.h <<_ACEOF
15270 #define HAVE_DECL_STRNLEN $ac_have_decl
15273 # This is probably only present on macOS, but may as well check always
15274 ac_fn_c_check_decl "$LINENO" "F_FULLFSYNC" "ac_cv_have_decl_F_FULLFSYNC" "#include <fcntl.h>
15276 if test "x$ac_cv_have_decl_F_FULLFSYNC" = xyes; then :
15282 cat >>confdefs.h <<_ACEOF
15283 #define HAVE_DECL_F_FULLFSYNC $ac_have_decl
15288 ac_fn_c_check_type "$LINENO" "struct sockaddr_in6" "ac_cv_type_struct_sockaddr_in6" "$ac_includes_default
15289 #include <netinet/in.h>
15291 if test "x$ac_cv_type_struct_sockaddr_in6" = xyes; then :
15293 $as_echo "#define HAVE_IPV6 1" >>confdefs.h
15300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PS_STRINGS" >&5
15301 $as_echo_n "checking for PS_STRINGS... " >&6; }
15302 if ${pgac_cv_var_PS_STRINGS+:} false; then :
15303 $as_echo_n "(cached) " >&6
15305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15306 /* end confdefs.h. */
15307 #include <machine/vmparam.h>
15308 #include <sys/exec.h>
15313 PS_STRINGS->ps_nargvstr = 1;
15314 PS_STRINGS->ps_argvstr = "foo";
15319 if ac_fn_c_try_link "$LINENO"; then :
15320 pgac_cv_var_PS_STRINGS=yes
15322 pgac_cv_var_PS_STRINGS=no
15324 rm -f core conftest.err conftest.$ac_objext \
15325 conftest$ac_exeext conftest.$ac_ext
15327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_PS_STRINGS" >&5
15328 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
15329 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
15331 $as_echo "#define HAVE_PS_STRINGS 1" >>confdefs.h
15336 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
15337 # is missing. Yes, there are machines that have only one. We may
15338 # also decide to use snprintf.c if snprintf() is present but does not
15339 # have all the features we need --- see below.
15341 if test "$PORTNAME" = "win32"; then
15342 # Win32 gets snprintf.c built unconditionally.
15344 # To properly translate all NLS languages strings, we must support the
15345 # *printf() %$ format, which allows *printf() arguments to be selected
15346 # by position in the translated string.
15348 # libintl versions < 0.13 use the native *printf() functions, and Win32
15349 # *printf() doesn't understand %$, so we must use our /port versions,
15350 # which do understand %$. libintl versions >= 0.13 include their own
15351 # *printf versions on Win32. The libintl 0.13 release note text is:
15353 # C format strings with positions, as they arise when a translator
15354 # needs to reorder a sentence, are now supported on all platforms.
15355 # On those few platforms (NetBSD and Woe32) for which the native
15356 # printf()/fprintf()/... functions don't support such format
15357 # strings, replacements are provided through <libintl.h>.
15359 # We could use libintl >= 0.13's *printf() if we were sure that we had
15360 # a libintl >= 0.13 at runtime, but seeing that there is no clean way
15361 # to guarantee that, it is best to just use our own, so we are sure to
15362 # get %$ support. In include/port.h we disable the *printf() macros
15363 # that might have been defined by libintl.
15365 # We do this unconditionally whether NLS is used or not so we are sure
15366 # that all Win32 libraries and binaries behave the same.
15367 pgac_need_repl_snprintf=yes
15369 pgac_need_repl_snprintf=no
15370 for ac_func in snprintf
15372 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
15373 if test "x$ac_cv_func_snprintf" = xyes; then :
15374 cat >>confdefs.h <<_ACEOF
15375 #define HAVE_SNPRINTF 1
15379 pgac_need_repl_snprintf=yes
15383 for ac_func in vsnprintf
15385 ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
15386 if test "x$ac_cv_func_vsnprintf" = xyes; then :
15387 cat >>confdefs.h <<_ACEOF
15388 #define HAVE_VSNPRINTF 1
15392 pgac_need_repl_snprintf=yes
15399 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
15400 # include/c.h will provide declarations. Note this is a separate test
15401 # from whether the functions exist in the C library --- there are
15402 # systems that have the functions but don't bother to declare them :-(
15404 ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
15405 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
15411 cat >>confdefs.h <<_ACEOF
15412 #define HAVE_DECL_SNPRINTF $ac_have_decl
15414 ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
15415 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
15421 cat >>confdefs.h <<_ACEOF
15422 #define HAVE_DECL_VSNPRINTF $ac_have_decl
15427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isinf" >&5
15428 $as_echo_n "checking for isinf... " >&6; }
15429 if ${ac_cv_func_isinf+:} false; then :
15430 $as_echo_n "(cached) " >&6
15432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15433 /* end confdefs.h. */
15436 double glob_double;
15441 return isinf(glob_double) ? 0 : 1;
15446 if ac_fn_c_try_link "$LINENO"; then :
15447 ac_cv_func_isinf=yes
15449 ac_cv_func_isinf=no
15451 rm -f core conftest.err conftest.$ac_objext \
15452 conftest$ac_exeext conftest.$ac_ext
15454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_isinf" >&5
15455 $as_echo "$ac_cv_func_isinf" >&6; }
15457 if test $ac_cv_func_isinf = yes ; then
15459 $as_echo "#define HAVE_ISINF 1" >>confdefs.h
15462 case " $LIBOBJS " in
15463 *" isinf.$ac_objext "* ) ;;
15464 *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
15468 # Look for a way to implement a substitute for isinf()
15469 for ac_func in fpclass fp_class fp_class_d class
15471 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15472 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15473 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15474 cat >>confdefs.h <<_ACEOF
15475 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15483 ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
15484 if test "x$ac_cv_func_crypt" = xyes; then :
15485 $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
15488 case " $LIBOBJS " in
15489 *" crypt.$ac_objext "* ) ;;
15490 *) LIBOBJS="$LIBOBJS crypt.$ac_objext"
15496 ac_fn_c_check_func "$LINENO" "fls" "ac_cv_func_fls"
15497 if test "x$ac_cv_func_fls" = xyes; then :
15498 $as_echo "#define HAVE_FLS 1" >>confdefs.h
15501 case " $LIBOBJS " in
15502 *" fls.$ac_objext "* ) ;;
15503 *) LIBOBJS="$LIBOBJS fls.$ac_objext"
15509 ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt"
15510 if test "x$ac_cv_func_getopt" = xyes; then :
15511 $as_echo "#define HAVE_GETOPT 1" >>confdefs.h
15514 case " $LIBOBJS " in
15515 *" getopt.$ac_objext "* ) ;;
15516 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15522 ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
15523 if test "x$ac_cv_func_getrusage" = xyes; then :
15524 $as_echo "#define HAVE_GETRUSAGE 1" >>confdefs.h
15527 case " $LIBOBJS " in
15528 *" getrusage.$ac_objext "* ) ;;
15529 *) LIBOBJS="$LIBOBJS getrusage.$ac_objext"
15535 ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
15536 if test "x$ac_cv_func_inet_aton" = xyes; then :
15537 $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h
15540 case " $LIBOBJS " in
15541 *" inet_aton.$ac_objext "* ) ;;
15542 *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
15548 ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
15549 if test "x$ac_cv_func_mkdtemp" = xyes; then :
15550 $as_echo "#define HAVE_MKDTEMP 1" >>confdefs.h
15553 case " $LIBOBJS " in
15554 *" mkdtemp.$ac_objext "* ) ;;
15555 *) LIBOBJS="$LIBOBJS mkdtemp.$ac_objext"
15561 ac_fn_c_check_func "$LINENO" "random" "ac_cv_func_random"
15562 if test "x$ac_cv_func_random" = xyes; then :
15563 $as_echo "#define HAVE_RANDOM 1" >>confdefs.h
15566 case " $LIBOBJS " in
15567 *" random.$ac_objext "* ) ;;
15568 *) LIBOBJS="$LIBOBJS random.$ac_objext"
15574 ac_fn_c_check_func "$LINENO" "rint" "ac_cv_func_rint"
15575 if test "x$ac_cv_func_rint" = xyes; then :
15576 $as_echo "#define HAVE_RINT 1" >>confdefs.h
15579 case " $LIBOBJS " in
15580 *" rint.$ac_objext "* ) ;;
15581 *) LIBOBJS="$LIBOBJS rint.$ac_objext"
15587 ac_fn_c_check_func "$LINENO" "srandom" "ac_cv_func_srandom"
15588 if test "x$ac_cv_func_srandom" = xyes; then :
15589 $as_echo "#define HAVE_SRANDOM 1" >>confdefs.h
15592 case " $LIBOBJS " in
15593 *" srandom.$ac_objext "* ) ;;
15594 *) LIBOBJS="$LIBOBJS srandom.$ac_objext"
15600 ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror"
15601 if test "x$ac_cv_func_strerror" = xyes; then :
15602 $as_echo "#define HAVE_STRERROR 1" >>confdefs.h
15605 case " $LIBOBJS " in
15606 *" strerror.$ac_objext "* ) ;;
15607 *) LIBOBJS="$LIBOBJS strerror.$ac_objext"
15613 ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
15614 if test "x$ac_cv_func_strlcat" = xyes; then :
15615 $as_echo "#define HAVE_STRLCAT 1" >>confdefs.h
15618 case " $LIBOBJS " in
15619 *" strlcat.$ac_objext "* ) ;;
15620 *) LIBOBJS="$LIBOBJS strlcat.$ac_objext"
15626 ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
15627 if test "x$ac_cv_func_strlcpy" = xyes; then :
15628 $as_echo "#define HAVE_STRLCPY 1" >>confdefs.h
15631 case " $LIBOBJS " in
15632 *" strlcpy.$ac_objext "* ) ;;
15633 *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
15639 ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
15640 if test "x$ac_cv_func_strnlen" = xyes; then :
15641 $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h
15644 case " $LIBOBJS " in
15645 *" strnlen.$ac_objext "* ) ;;
15646 *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
15656 # Windows uses a specialised env handler
15657 # and doesn't need a replacement getpeereid because it doesn't use
15661 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15664 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15666 ac_cv_func_unsetenv=yes
15667 ac_cv_func_getpeereid=yes;;
15669 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
15670 if test "x$ac_cv_func_unsetenv" = xyes; then :
15671 $as_echo "#define HAVE_UNSETENV 1" >>confdefs.h
15674 case " $LIBOBJS " in
15675 *" unsetenv.$ac_objext "* ) ;;
15676 *) LIBOBJS="$LIBOBJS unsetenv.$ac_objext"
15682 ac_fn_c_check_func "$LINENO" "getpeereid" "ac_cv_func_getpeereid"
15683 if test "x$ac_cv_func_getpeereid" = xyes; then :
15684 $as_echo "#define HAVE_GETPEEREID 1" >>confdefs.h
15687 case " $LIBOBJS " in
15688 *" getpeereid.$ac_objext "* ) ;;
15689 *) LIBOBJS="$LIBOBJS getpeereid.$ac_objext"
15699 # System's version of getaddrinfo(), if any, may be used only if we found
15700 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
15701 # We use only our own getaddrinfo.c on Windows, but it's time to revisit that.
15702 if test x"$ac_cv_type_struct_addrinfo" = xyes && \
15703 test "$PORTNAME" != "win32"; then
15704 ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo"
15705 if test "x$ac_cv_func_getaddrinfo" = xyes; then :
15706 $as_echo "#define HAVE_GETADDRINFO 1" >>confdefs.h
15709 case " $LIBOBJS " in
15710 *" getaddrinfo.$ac_objext "* ) ;;
15711 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15719 case " $LIBOBJS " in
15720 *" getaddrinfo.$ac_objext "* ) ;;
15721 *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
15727 # Similarly, use system's getopt_long() only if system provides struct option.
15728 if test x"$ac_cv_type_struct_option" = xyes ; then
15729 ac_fn_c_check_func "$LINENO" "getopt_long" "ac_cv_func_getopt_long"
15730 if test "x$ac_cv_func_getopt_long" = xyes; then :
15731 $as_echo "#define HAVE_GETOPT_LONG 1" >>confdefs.h
15734 case " $LIBOBJS " in
15735 *" getopt_long.$ac_objext "* ) ;;
15736 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15744 case " $LIBOBJS " in
15745 *" getopt_long.$ac_objext "* ) ;;
15746 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15752 # Solaris' getopt() doesn't do what we want for long options, so always use
15753 # our version on that platform.
15754 if test "$PORTNAME" = "solaris"; then
15755 case " $LIBOBJS " in
15756 *" getopt.$ac_objext "* ) ;;
15757 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15763 # mingw has adopted a GNU-centric interpretation of optind/optreset,
15764 # so always use our version on Windows.
15765 if test "$PORTNAME" = "win32"; then
15766 case " $LIBOBJS " in
15767 *" getopt.$ac_objext "* ) ;;
15768 *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
15772 case " $LIBOBJS " in
15773 *" getopt_long.$ac_objext "* ) ;;
15774 *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
15780 # Win32 (really MinGW) support
15781 if test "$PORTNAME" = "win32"; then
15782 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
15783 if test "x$ac_cv_func_gettimeofday" = xyes; then :
15784 $as_echo "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h
15787 case " $LIBOBJS " in
15788 *" gettimeofday.$ac_objext "* ) ;;
15789 *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
15796 case " $LIBOBJS " in
15797 *" dirmod.$ac_objext "* ) ;;
15798 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
15802 case " $LIBOBJS " in
15803 *" kill.$ac_objext "* ) ;;
15804 *) LIBOBJS="$LIBOBJS kill.$ac_objext"
15808 case " $LIBOBJS " in
15809 *" open.$ac_objext "* ) ;;
15810 *) LIBOBJS="$LIBOBJS open.$ac_objext"
15814 case " $LIBOBJS " in
15815 *" system.$ac_objext "* ) ;;
15816 *) LIBOBJS="$LIBOBJS system.$ac_objext"
15820 case " $LIBOBJS " in
15821 *" win32env.$ac_objext "* ) ;;
15822 *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
15826 case " $LIBOBJS " in
15827 *" win32error.$ac_objext "* ) ;;
15828 *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
15832 case " $LIBOBJS " in
15833 *" win32security.$ac_objext "* ) ;;
15834 *) LIBOBJS="$LIBOBJS win32security.$ac_objext"
15838 case " $LIBOBJS " in
15839 *" win32setlocale.$ac_objext "* ) ;;
15840 *) LIBOBJS="$LIBOBJS win32setlocale.$ac_objext"
15845 $as_echo "#define HAVE_SYMLINK 1" >>confdefs.h
15847 ac_fn_c_check_type "$LINENO" "MINIDUMP_TYPE" "ac_cv_type_MINIDUMP_TYPE" "
15848 #define WIN32_LEAN_AND_MEAN
15849 #include <windows.h>
15850 #include <string.h>
15851 #include <dbghelp.h>
15853 if test "x$ac_cv_type_MINIDUMP_TYPE" = xyes; then :
15855 cat >>confdefs.h <<_ACEOF
15856 #define HAVE_MINIDUMP_TYPE 1
15859 pgac_minidump_type=yes
15861 pgac_minidump_type=no
15865 if test x"$pgac_minidump_type" = x"yes" ; then
15866 have_win32_dbghelp=yes
15869 have_win32_dbghelp=no
15873 # Cygwin needs only a bit of that
15874 if test "$PORTNAME" = "cygwin"; then
15875 case " $LIBOBJS " in
15876 *" dirmod.$ac_objext "* ) ;;
15877 *) LIBOBJS="$LIBOBJS dirmod.$ac_objext"
15883 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
15884 /* NetBSD declares sys_siglist in unistd.h. */
15885 #ifdef HAVE_UNISTD_H
15886 # include <unistd.h>
15890 if test "x$ac_cv_have_decl_sys_siglist" = xyes; then :
15896 cat >>confdefs.h <<_ACEOF
15897 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
15901 ac_fn_c_check_func "$LINENO" "syslog" "ac_cv_func_syslog"
15902 if test "x$ac_cv_func_syslog" = xyes; then :
15903 ac_fn_c_check_header_mongrel "$LINENO" "syslog.h" "ac_cv_header_syslog_h" "$ac_includes_default"
15904 if test "x$ac_cv_header_syslog_h" = xyes; then :
15906 $as_echo "#define HAVE_SYSLOG 1" >>confdefs.h
15914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for opterr" >&5
15915 $as_echo_n "checking for opterr... " >&6; }
15916 if ${pgac_cv_var_int_opterr+:} false; then :
15917 $as_echo_n "(cached) " >&6
15919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15920 /* end confdefs.h. */
15921 #include <unistd.h>
15925 extern int opterr; opterr = 1;
15930 if ac_fn_c_try_link "$LINENO"; then :
15931 pgac_cv_var_int_opterr=yes
15933 pgac_cv_var_int_opterr=no
15935 rm -f core conftest.err conftest.$ac_objext \
15936 conftest$ac_exeext conftest.$ac_ext
15938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_opterr" >&5
15939 $as_echo "$pgac_cv_var_int_opterr" >&6; }
15940 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
15942 $as_echo "#define HAVE_INT_OPTERR 1" >>confdefs.h
15946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for optreset" >&5
15947 $as_echo_n "checking for optreset... " >&6; }
15948 if ${pgac_cv_var_int_optreset+:} false; then :
15949 $as_echo_n "(cached) " >&6
15951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15952 /* end confdefs.h. */
15953 #include <unistd.h>
15957 extern int optreset; optreset = 1;
15962 if ac_fn_c_try_link "$LINENO"; then :
15963 pgac_cv_var_int_optreset=yes
15965 pgac_cv_var_int_optreset=no
15967 rm -f core conftest.err conftest.$ac_objext \
15968 conftest$ac_exeext conftest.$ac_ext
15970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_int_optreset" >&5
15971 $as_echo "$pgac_cv_var_int_optreset" >&6; }
15972 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15974 $as_echo "#define HAVE_INT_OPTRESET 1" >>confdefs.h
15978 for ac_func in strtoll __strtoll strtoq
15980 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15981 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15982 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15983 cat >>confdefs.h <<_ACEOF
15984 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15990 for ac_func in strtoull __strtoull strtouq
15992 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15993 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15994 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15995 cat >>confdefs.h <<_ACEOF
15996 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16002 # strto[u]ll may exist but not be declared
16003 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
16004 if test "x$ac_cv_have_decl_strtoll" = xyes; then :
16010 cat >>confdefs.h <<_ACEOF
16011 #define HAVE_DECL_STRTOLL $ac_have_decl
16013 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
16014 if test "x$ac_cv_have_decl_strtoull" = xyes; then :
16020 cat >>confdefs.h <<_ACEOF
16021 #define HAVE_DECL_STRTOULL $ac_have_decl
16025 if test "$with_icu" = yes; then
16026 ac_save_CPPFLAGS=$CPPFLAGS
16027 CPPFLAGS="$ICU_CFLAGS $CPPFLAGS"
16029 # Verify we have ICU's header files
16030 ac_fn_c_check_header_mongrel "$LINENO" "unicode/ucol.h" "ac_cv_header_unicode_ucol_h" "$ac_includes_default"
16031 if test "x$ac_cv_header_unicode_ucol_h" = xyes; then :
16034 as_fn_error $? "header file <unicode/ucol.h> is required for ICU" "$LINENO" 5
16039 CPPFLAGS=$ac_save_CPPFLAGS
16042 # Lastly, restore full LIBS list and check for readline/libedit symbols
16043 LIBS="$LIBS_including_readline"
16045 if test "$with_readline" = yes; then
16046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_completion_append_character" >&5
16047 $as_echo_n "checking for rl_completion_append_character... " >&6; }
16048 if ${pgac_cv_var_rl_completion_append_character+:} false; then :
16049 $as_echo_n "(cached) " >&6
16051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16052 /* end confdefs.h. */
16054 #ifdef HAVE_READLINE_READLINE_H
16055 # include <readline/readline.h>
16056 #elif defined(HAVE_READLINE_H)
16057 # include <readline.h>
16063 rl_completion_append_character = 'x';
16068 if ac_fn_c_try_link "$LINENO"; then :
16069 pgac_cv_var_rl_completion_append_character=yes
16071 pgac_cv_var_rl_completion_append_character=no
16073 rm -f core conftest.err conftest.$ac_objext \
16074 conftest$ac_exeext conftest.$ac_ext
16076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_var_rl_completion_append_character" >&5
16077 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
16078 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
16080 $as_echo "#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1" >>confdefs.h
16083 for ac_func in rl_completion_matches rl_filename_completion_function rl_reset_screen_size
16085 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16086 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16087 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16088 cat >>confdefs.h <<_ACEOF
16089 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16095 for ac_func in append_history history_truncate_file
16097 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16098 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16099 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
16100 cat >>confdefs.h <<_ACEOF
16101 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16110 # This test makes sure that run tests work at all. Sometimes a shared
16111 # library is found by the linker, but the runtime linker can't find it.
16112 # This check should come after all modifications of compiler or linker
16113 # variables, and before any other run tests.
16114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking test program" >&5
16115 $as_echo_n "checking test program... " >&6; }
16116 if test "$cross_compiling" = yes; then :
16117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling" >&5
16118 $as_echo "cross-compiling" >&6; }
16120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16121 /* end confdefs.h. */
16122 int main() { return 0; }
16124 if ac_fn_c_try_run "$LINENO"; then :
16125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
16126 $as_echo "ok" >&6; }
16128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
16129 $as_echo "failed" >&6; }
16131 Could not execute a simple test program. This may be a problem
16132 related to locating shared libraries. Check the file 'config.log'
16133 for the exact reason." "$LINENO" 5
16135 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16136 conftest.$ac_objext conftest.beam conftest.$ac_ext
16140 # --------------------
16141 # Run tests below here
16142 # --------------------
16144 # For NLS, force use of our snprintf if system's doesn't do arg control.
16145 # See comment above at snprintf test for details.
16146 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
16147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf supports argument control" >&5
16148 $as_echo_n "checking whether snprintf supports argument control... " >&6; }
16149 if ${pgac_cv_snprintf_arg_control+:} false; then :
16150 $as_echo_n "(cached) " >&6
16152 if test "$cross_compiling" = yes; then :
16153 pgac_cv_snprintf_arg_control=cross
16155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16156 /* end confdefs.h. */
16158 #include <string.h>
16164 /* can it swap arguments? */
16165 snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
16166 if (strcmp(buf, "4 3") != 0)
16171 if ac_fn_c_try_run "$LINENO"; then :
16172 pgac_cv_snprintf_arg_control=yes
16174 pgac_cv_snprintf_arg_control=no
16176 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16177 conftest.$ac_objext conftest.beam conftest.$ac_ext
16182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_snprintf_arg_control" >&5
16183 $as_echo "$pgac_cv_snprintf_arg_control" >&6; }
16185 if test $pgac_cv_snprintf_arg_control != yes ; then
16186 pgac_need_repl_snprintf=yes
16192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long int is 64 bits" >&5
16193 $as_echo_n "checking whether long int is 64 bits... " >&6; }
16194 if ${pgac_cv_type_long_int_64+:} false; then :
16195 $as_echo_n "(cached) " >&6
16197 if test "$cross_compiling" = yes; then :
16198 # If cross-compiling, check the size reported by the compiler and
16199 # trust that the arithmetic works.
16200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16201 /* end confdefs.h. */
16206 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
16207 test_array [0] = 0;
16208 return test_array [0];
16214 if ac_fn_c_try_compile "$LINENO"; then :
16215 pgac_cv_type_long_int_64=yes
16217 pgac_cv_type_long_int_64=no
16219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16222 /* end confdefs.h. */
16223 typedef long int ac_int64;
16226 * These are globals to discourage the compiler from folding all the
16227 * arithmetic tests down to compile-time constants.
16229 ac_int64 a = 20000001;
16230 ac_int64 b = 40000005;
16232 int does_int64_work()
16236 if (sizeof(ac_int64) != 8)
16237 return 0; /* definitely not the right size */
16239 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16249 return (! does_int64_work());
16252 if ac_fn_c_try_run "$LINENO"; then :
16253 pgac_cv_type_long_int_64=yes
16255 pgac_cv_type_long_int_64=no
16257 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16258 conftest.$ac_objext conftest.beam conftest.$ac_ext
16262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_int_64" >&5
16263 $as_echo "$pgac_cv_type_long_int_64" >&6; }
16265 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
16266 if test x"$pgac_cv_type_long_int_64" = xyes ; then
16268 $as_echo "#define HAVE_LONG_INT_64 1" >>confdefs.h
16273 if test x"$HAVE_LONG_INT_64" = x"yes" ; then
16274 pg_int64_type="long int"
16276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long long int is 64 bits" >&5
16277 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
16278 if ${pgac_cv_type_long_long_int_64+:} false; then :
16279 $as_echo_n "(cached) " >&6
16281 if test "$cross_compiling" = yes; then :
16282 # If cross-compiling, check the size reported by the compiler and
16283 # trust that the arithmetic works.
16284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16285 /* end confdefs.h. */
16290 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
16291 test_array [0] = 0;
16292 return test_array [0];
16298 if ac_fn_c_try_compile "$LINENO"; then :
16299 pgac_cv_type_long_long_int_64=yes
16301 pgac_cv_type_long_long_int_64=no
16303 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16306 /* end confdefs.h. */
16307 typedef long long int ac_int64;
16310 * These are globals to discourage the compiler from folding all the
16311 * arithmetic tests down to compile-time constants.
16313 ac_int64 a = 20000001;
16314 ac_int64 b = 40000005;
16316 int does_int64_work()
16320 if (sizeof(ac_int64) != 8)
16321 return 0; /* definitely not the right size */
16323 /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16333 return (! does_int64_work());
16336 if ac_fn_c_try_run "$LINENO"; then :
16337 pgac_cv_type_long_long_int_64=yes
16339 pgac_cv_type_long_long_int_64=no
16341 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16342 conftest.$ac_objext conftest.beam conftest.$ac_ext
16346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_type_long_long_int_64" >&5
16347 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
16349 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
16350 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
16352 $as_echo "#define HAVE_LONG_LONG_INT_64 1" >>confdefs.h
16356 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16357 pg_int64_type="long long int"
16359 as_fn_error $? "Cannot find a working 64-bit integer type." "$LINENO" 5
16364 cat >>confdefs.h <<_ACEOF
16365 #define PG_INT64_TYPE $pg_int64_type
16369 # Select the printf length modifier that goes with that, too.
16370 # (This used to be bound up with replacement-snprintf selection, but now
16371 # we assume that the native *printf functions use standard length modifiers.)
16372 if test x"$pg_int64_type" = x"long long int" ; then
16373 INT64_MODIFIER='"ll"'
16375 INT64_MODIFIER='"l"'
16379 cat >>confdefs.h <<_ACEOF
16380 #define INT64_MODIFIER $INT64_MODIFIER
16384 # Force use of our snprintf if the system's doesn't support the %z flag.
16385 # (Note this test uses PG_INT64_TYPE and INT64_MODIFIER.)
16386 if test "$pgac_need_repl_snprintf" = no; then
16387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf supports the %z modifier" >&5
16388 $as_echo_n "checking whether snprintf supports the %z modifier... " >&6; }
16389 if ${pgac_cv_snprintf_size_t_support+:} false; then :
16390 $as_echo_n "(cached) " >&6
16392 if test "$cross_compiling" = yes; then :
16393 pgac_cv_snprintf_size_t_support=cross
16395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16396 /* end confdefs.h. */
16398 #include <string.h>
16406 * Print the largest unsigned number fitting in a size_t using both %zu
16407 * and the previously-determined format for 64-bit integers. Note that
16408 * we don't run this code unless we know snprintf handles 64-bit ints.
16410 bufz[0] = '\0'; /* in case snprintf fails to emit anything */
16411 snprintf(bufz, sizeof(bufz), "%zu", ~((size_t) 0));
16412 snprintf(buf64, sizeof(buf64), "%" INT64_MODIFIER "u",
16413 (unsigned PG_INT64_TYPE) ~((size_t) 0));
16414 if (strcmp(bufz, buf64) != 0)
16419 if ac_fn_c_try_run "$LINENO"; then :
16420 pgac_cv_snprintf_size_t_support=yes
16422 pgac_cv_snprintf_size_t_support=no
16424 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16425 conftest.$ac_objext conftest.beam conftest.$ac_ext
16430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_snprintf_size_t_support" >&5
16431 $as_echo "$pgac_cv_snprintf_size_t_support" >&6; }
16433 if test "$pgac_cv_snprintf_size_t_support" != yes; then
16434 pgac_need_repl_snprintf=yes
16438 # Force use of our snprintf if the system's doesn't handle buffer overrun
16439 # as specified by C99.
16440 if test "$pgac_need_repl_snprintf" = no; then
16441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf handles buffer overrun per C99" >&5
16442 $as_echo_n "checking whether snprintf handles buffer overrun per C99... " >&6; }
16443 if ${pgac_cv_snprintf_c99_result+:} false; then :
16444 $as_echo_n "(cached) " >&6
16446 if test "$cross_compiling" = yes; then :
16447 pgac_cv_snprintf_c99_result=cross
16449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16450 /* end confdefs.h. */
16452 #include <string.h>
16458 strcpy(buf, "abcdefghi");
16459 if (snprintf(buf, 4, "%d", 123456) != 6)
16461 if (strcmp(buf, "123") != 0 || buf[4] != 'e')
16466 if ac_fn_c_try_run "$LINENO"; then :
16467 pgac_cv_snprintf_c99_result=yes
16469 pgac_cv_snprintf_c99_result=no
16471 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16472 conftest.$ac_objext conftest.beam conftest.$ac_ext
16477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_snprintf_c99_result" >&5
16478 $as_echo "$pgac_cv_snprintf_c99_result" >&6; }
16480 if test "$pgac_cv_snprintf_c99_result" != yes; then
16481 pgac_need_repl_snprintf=yes
16485 # Now we have checked all the reasons to replace snprintf
16486 if test $pgac_need_repl_snprintf = yes; then
16488 $as_echo "#define USE_REPL_SNPRINTF 1" >>confdefs.h
16490 case " $LIBOBJS " in
16491 *" snprintf.$ac_objext "* ) ;;
16492 *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
16498 # has to be down here, rather than with the other builtins, because
16499 # the test uses PG_INT64_TYPE.
16500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_mul_overflow" >&5
16501 $as_echo_n "checking for __builtin_mul_overflow... " >&6; }
16502 if ${pgac_cv__builtin_op_overflow+:} false; then :
16503 $as_echo_n "(cached) " >&6
16505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16506 /* end confdefs.h. */
16508 PG_INT64_TYPE a = 1;
16509 PG_INT64_TYPE b = 1;
16510 PG_INT64_TYPE result;
16516 oflo = __builtin_mul_overflow(a, b, &result);
16521 if ac_fn_c_try_link "$LINENO"; then :
16522 pgac_cv__builtin_op_overflow=yes
16524 pgac_cv__builtin_op_overflow=no
16526 rm -f core conftest.err conftest.$ac_objext \
16527 conftest$ac_exeext conftest.$ac_ext
16529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__builtin_op_overflow" >&5
16530 $as_echo "$pgac_cv__builtin_op_overflow" >&6; }
16531 if test x"$pgac_cv__builtin_op_overflow" = xyes ; then
16533 $as_echo "#define HAVE__BUILTIN_OP_OVERFLOW 1" >>confdefs.h
16537 # Check size of void *, size_t (enables tweaks for > 32bit address space)
16538 # The cast to long int works around a bug in the HP C Compiler
16539 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16540 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16541 # This bug is HP SR number 8606223364.
16542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
16543 $as_echo_n "checking size of void *... " >&6; }
16544 if ${ac_cv_sizeof_void_p+:} false; then :
16545 $as_echo_n "(cached) " >&6
16547 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
16550 if test "$ac_cv_type_void_p" = yes; then
16551 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16552 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16553 as_fn_error 77 "cannot compute sizeof (void *)
16554 See \`config.log' for more details" "$LINENO" 5; }
16556 ac_cv_sizeof_void_p=0
16561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
16562 $as_echo "$ac_cv_sizeof_void_p" >&6; }
16566 cat >>confdefs.h <<_ACEOF
16567 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
16571 # The cast to long int works around a bug in the HP C Compiler
16572 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16573 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16574 # This bug is HP SR number 8606223364.
16575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
16576 $as_echo_n "checking size of size_t... " >&6; }
16577 if ${ac_cv_sizeof_size_t+:} false; then :
16578 $as_echo_n "(cached) " >&6
16580 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then :
16583 if test "$ac_cv_type_size_t" = yes; then
16584 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16585 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16586 as_fn_error 77 "cannot compute sizeof (size_t)
16587 See \`config.log' for more details" "$LINENO" 5; }
16589 ac_cv_sizeof_size_t=0
16594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
16595 $as_echo "$ac_cv_sizeof_size_t" >&6; }
16599 cat >>confdefs.h <<_ACEOF
16600 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
16604 # The cast to long int works around a bug in the HP C Compiler
16605 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
16606 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
16607 # This bug is HP SR number 8606223364.
16608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
16609 $as_echo_n "checking size of long... " >&6; }
16610 if ${ac_cv_sizeof_long+:} false; then :
16611 $as_echo_n "(cached) " >&6
16613 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
16616 if test "$ac_cv_type_long" = yes; then
16617 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16618 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16619 as_fn_error 77 "cannot compute sizeof (long)
16620 See \`config.log' for more details" "$LINENO" 5; }
16622 ac_cv_sizeof_long=0
16627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
16628 $as_echo "$ac_cv_sizeof_long" >&6; }
16632 cat >>confdefs.h <<_ACEOF
16633 #define SIZEOF_LONG $ac_cv_sizeof_long
16638 # Decide whether float4 is passed by value: user-selectable, enabled by default
16639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float4 passed by value" >&5
16640 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
16643 # Check whether --enable-float4-byval was given.
16644 if test "${enable_float4_byval+set}" = set; then :
16645 enableval=$enable_float4_byval;
16649 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16651 float4passbyval=true
16654 float4passbyval=false
16657 as_fn_error $? "no argument expected for --enable-float4-byval option" "$LINENO" 5
16662 enable_float4_byval=yes
16664 $as_echo "#define USE_FLOAT4_BYVAL 1" >>confdefs.h
16666 float4passbyval=true
16670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float4_byval" >&5
16671 $as_echo "$enable_float4_byval" >&6; }
16673 cat >>confdefs.h <<_ACEOF
16674 #define FLOAT4PASSBYVAL $float4passbyval
16678 # Decide whether float8 is passed by value.
16679 # Note: this setting also controls int8 and related types such as timestamp.
16680 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
16681 # If not, trying to select it is an error.
16682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with float8 passed by value" >&5
16683 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
16684 if test $ac_cv_sizeof_void_p -ge 8 ; then
16687 # Check whether --enable-float8-byval was given.
16688 if test "${enable_float8_byval+set}" = set; then :
16689 enableval=$enable_float8_byval;
16698 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16703 enable_float8_byval=yes
16711 # Check whether --enable-float8-byval was given.
16712 if test "${enable_float8_byval+set}" = set; then :
16713 enableval=$enable_float8_byval;
16722 as_fn_error $? "no argument expected for --enable-float8-byval option" "$LINENO" 5
16727 enable_float8_byval=no
16732 if test "$enable_float8_byval" = yes ; then
16733 as_fn_error $? "--enable-float8-byval is not supported on 32-bit platforms." "$LINENO" 5
16736 if test "$enable_float8_byval" = yes ; then
16738 $as_echo "#define USE_FLOAT8_BYVAL 1" >>confdefs.h
16740 float8passbyval=true
16742 float8passbyval=false
16744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_float8_byval" >&5
16745 $as_echo "$enable_float8_byval" >&6; }
16747 cat >>confdefs.h <<_ACEOF
16748 #define FLOAT8PASSBYVAL $float8passbyval
16752 # Determine memory alignment requirements for the basic C data types.
16754 # The cast to long int works around a bug in the HP C Compiler,
16755 # see AC_CHECK_SIZEOF for more information.
16756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of short" >&5
16757 $as_echo_n "checking alignment of short... " >&6; }
16758 if ${ac_cv_alignof_short+:} false; then :
16759 $as_echo_n "(cached) " >&6
16761 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_short" "$ac_includes_default
16763 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16765 typedef struct { char x; short y; } ac__type_alignof_;"; then :
16768 if test "$ac_cv_type_short" = yes; then
16769 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16770 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16771 as_fn_error 77 "cannot compute alignment of short
16772 See \`config.log' for more details" "$LINENO" 5; }
16774 ac_cv_alignof_short=0
16779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_short" >&5
16780 $as_echo "$ac_cv_alignof_short" >&6; }
16784 cat >>confdefs.h <<_ACEOF
16785 #define ALIGNOF_SHORT $ac_cv_alignof_short
16789 # The cast to long int works around a bug in the HP C Compiler,
16790 # see AC_CHECK_SIZEOF for more information.
16791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of int" >&5
16792 $as_echo_n "checking alignment of int... " >&6; }
16793 if ${ac_cv_alignof_int+:} false; then :
16794 $as_echo_n "(cached) " >&6
16796 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_int" "$ac_includes_default
16798 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16800 typedef struct { char x; int y; } ac__type_alignof_;"; then :
16803 if test "$ac_cv_type_int" = yes; then
16804 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16805 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16806 as_fn_error 77 "cannot compute alignment of int
16807 See \`config.log' for more details" "$LINENO" 5; }
16809 ac_cv_alignof_int=0
16814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_int" >&5
16815 $as_echo "$ac_cv_alignof_int" >&6; }
16819 cat >>confdefs.h <<_ACEOF
16820 #define ALIGNOF_INT $ac_cv_alignof_int
16824 # The cast to long int works around a bug in the HP C Compiler,
16825 # see AC_CHECK_SIZEOF for more information.
16826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long" >&5
16827 $as_echo_n "checking alignment of long... " >&6; }
16828 if ${ac_cv_alignof_long+:} false; then :
16829 $as_echo_n "(cached) " >&6
16831 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long" "$ac_includes_default
16833 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16835 typedef struct { char x; long y; } ac__type_alignof_;"; then :
16838 if test "$ac_cv_type_long" = yes; then
16839 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16840 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16841 as_fn_error 77 "cannot compute alignment of long
16842 See \`config.log' for more details" "$LINENO" 5; }
16844 ac_cv_alignof_long=0
16849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long" >&5
16850 $as_echo "$ac_cv_alignof_long" >&6; }
16854 cat >>confdefs.h <<_ACEOF
16855 #define ALIGNOF_LONG $ac_cv_alignof_long
16859 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16860 # The cast to long int works around a bug in the HP C Compiler,
16861 # see AC_CHECK_SIZEOF for more information.
16862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of long long int" >&5
16863 $as_echo_n "checking alignment of long long int... " >&6; }
16864 if ${ac_cv_alignof_long_long_int+:} false; then :
16865 $as_echo_n "(cached) " >&6
16867 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_long_long_int" "$ac_includes_default
16869 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16871 typedef struct { char x; long long int y; } ac__type_alignof_;"; then :
16874 if test "$ac_cv_type_long_long_int" = yes; then
16875 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16876 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16877 as_fn_error 77 "cannot compute alignment of long long int
16878 See \`config.log' for more details" "$LINENO" 5; }
16880 ac_cv_alignof_long_long_int=0
16885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_long_long_int" >&5
16886 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
16890 cat >>confdefs.h <<_ACEOF
16891 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
16896 # The cast to long int works around a bug in the HP C Compiler,
16897 # see AC_CHECK_SIZEOF for more information.
16898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of double" >&5
16899 $as_echo_n "checking alignment of double... " >&6; }
16900 if ${ac_cv_alignof_double+:} false; then :
16901 $as_echo_n "(cached) " >&6
16903 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_double" "$ac_includes_default
16905 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
16907 typedef struct { char x; double y; } ac__type_alignof_;"; then :
16910 if test "$ac_cv_type_double" = yes; then
16911 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
16912 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
16913 as_fn_error 77 "cannot compute alignment of double
16914 See \`config.log' for more details" "$LINENO" 5; }
16916 ac_cv_alignof_double=0
16921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_double" >&5
16922 $as_echo "$ac_cv_alignof_double" >&6; }
16926 cat >>confdefs.h <<_ACEOF
16927 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
16932 # Compute maximum alignment of any basic type.
16933 # We assume long's alignment is at least as strong as char, short, or int;
16934 # but we must check long long (if it is being used for int64) and double.
16935 # Note that we intentionally do not consider any types wider than 64 bits,
16936 # as allowing MAXIMUM_ALIGNOF to exceed 8 would be too much of a penalty
16937 # for disk and memory space.
16939 MAX_ALIGNOF=$ac_cv_alignof_long
16940 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
16941 MAX_ALIGNOF=$ac_cv_alignof_double
16943 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
16944 MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
16947 cat >>confdefs.h <<_ACEOF
16948 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
16953 # Some platforms predefine the types int8, int16, etc. Only check
16954 # a (hopefully) representative subset.
16955 ac_fn_c_check_type "$LINENO" "int8" "ac_cv_type_int8" "#include <stdio.h>
16957 if test "x$ac_cv_type_int8" = xyes; then :
16959 cat >>confdefs.h <<_ACEOF
16960 #define HAVE_INT8 1
16965 ac_fn_c_check_type "$LINENO" "uint8" "ac_cv_type_uint8" "#include <stdio.h>
16967 if test "x$ac_cv_type_uint8" = xyes; then :
16969 cat >>confdefs.h <<_ACEOF
16970 #define HAVE_UINT8 1
16975 ac_fn_c_check_type "$LINENO" "int64" "ac_cv_type_int64" "#include <stdio.h>
16977 if test "x$ac_cv_type_int64" = xyes; then :
16979 cat >>confdefs.h <<_ACEOF
16980 #define HAVE_INT64 1
16985 ac_fn_c_check_type "$LINENO" "uint64" "ac_cv_type_uint64" "#include <stdio.h>
16987 if test "x$ac_cv_type_uint64" = xyes; then :
16989 cat >>confdefs.h <<_ACEOF
16990 #define HAVE_UINT64 1
16997 # Some compilers offer a 128-bit integer scalar type.
16998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128" >&5
16999 $as_echo_n "checking for __int128... " >&6; }
17000 if ${pgac_cv__128bit_int+:} false; then :
17001 $as_echo_n "(cached) " >&6
17003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17004 /* end confdefs.h. */
17007 * We don't actually run this test, just link it to verify that any support
17008 * functions needed for __int128 are present.
17010 * These are globals to discourage the compiler from folding all the
17011 * arithmetic tests down to compile-time constants. We do not have
17012 * convenient support for 128bit literals at this point...
17014 __int128 a = 48828125;
17015 __int128 b = 97656250;
17022 a = (a << 12) + 1; /* 200000000001 */
17023 b = (b << 12) + 5; /* 400000000005 */
17024 /* try the most relevant arithmetic ops */
17027 /* must use the results, else compiler may optimize arithmetic away */
17035 if ac_fn_c_try_link "$LINENO"; then :
17036 pgac_cv__128bit_int=yes
17038 pgac_cv__128bit_int=no
17040 rm -f core conftest.err conftest.$ac_objext \
17041 conftest$ac_exeext conftest.$ac_ext
17043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int" >&5
17044 $as_echo "$pgac_cv__128bit_int" >&6; }
17045 if test x"$pgac_cv__128bit_int" = xyes ; then
17046 # Use of non-default alignment with __int128 tickles bugs in some compilers.
17047 # If not cross-compiling, we can test for bugs and disable use of __int128
17048 # with buggy compilers. If cross-compiling, hope for the best.
17049 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83925
17050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __int128 alignment bug" >&5
17051 $as_echo_n "checking for __int128 alignment bug... " >&6; }
17052 if ${pgac_cv__128bit_int_bug+:} false; then :
17053 $as_echo_n "(cached) " >&6
17055 if test "$cross_compiling" = yes; then :
17056 pgac_cv__128bit_int_bug="assuming ok"
17058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17059 /* end confdefs.h. */
17061 /* This must match the corresponding code in c.h: */
17062 #if defined(__GNUC__) || defined(__SUNPRO_C) || defined(__IBMC__)
17063 #define pg_attribute_aligned(a) __attribute__((aligned(a)))
17065 typedef __int128 int128a
17066 #if defined(pg_attribute_aligned)
17067 pg_attribute_aligned(8)
17071 void pass_by_val(void *buffer, int128a par) { holder = par; }
17077 long int i64 = 97656225L << 12;
17079 pass_by_val(main, (int128a) i64);
17088 if ac_fn_c_try_run "$LINENO"; then :
17089 pgac_cv__128bit_int_bug=ok
17091 pgac_cv__128bit_int_bug=broken
17093 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17094 conftest.$ac_objext conftest.beam conftest.$ac_ext
17098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__128bit_int_bug" >&5
17099 $as_echo "$pgac_cv__128bit_int_bug" >&6; }
17100 if test x"$pgac_cv__128bit_int_bug" != xbroken ; then
17102 $as_echo "#define PG_INT128_TYPE __int128" >>confdefs.h
17104 # The cast to long int works around a bug in the HP C Compiler,
17105 # see AC_CHECK_SIZEOF for more information.
17106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking alignment of PG_INT128_TYPE" >&5
17107 $as_echo_n "checking alignment of PG_INT128_TYPE... " >&6; }
17108 if ${ac_cv_alignof_PG_INT128_TYPE+:} false; then :
17109 $as_echo_n "(cached) " >&6
17111 if ac_fn_c_compute_int "$LINENO" "(long int) offsetof (ac__type_alignof_, y)" "ac_cv_alignof_PG_INT128_TYPE" "$ac_includes_default
17113 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
17115 typedef struct { char x; PG_INT128_TYPE y; } ac__type_alignof_;"; then :
17118 if test "$ac_cv_type_PG_INT128_TYPE" = yes; then
17119 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17120 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17121 as_fn_error 77 "cannot compute alignment of PG_INT128_TYPE
17122 See \`config.log' for more details" "$LINENO" 5; }
17124 ac_cv_alignof_PG_INT128_TYPE=0
17129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_alignof_PG_INT128_TYPE" >&5
17130 $as_echo "$ac_cv_alignof_PG_INT128_TYPE" >&6; }
17134 cat >>confdefs.h <<_ACEOF
17135 #define ALIGNOF_PG_INT128_TYPE $ac_cv_alignof_PG_INT128_TYPE
17142 # Check for various atomic operations now that we have checked how to declare
17144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync char locking functions" >&5
17145 $as_echo_n "checking for builtin __sync char locking functions... " >&6; }
17146 if ${pgac_cv_gcc_sync_char_tas+:} false; then :
17147 $as_echo_n "(cached) " >&6
17149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17150 /* end confdefs.h. */
17156 __sync_lock_test_and_set(&lock, 1);
17157 __sync_lock_release(&lock);
17162 if ac_fn_c_try_link "$LINENO"; then :
17163 pgac_cv_gcc_sync_char_tas="yes"
17165 pgac_cv_gcc_sync_char_tas="no"
17167 rm -f core conftest.err conftest.$ac_objext \
17168 conftest$ac_exeext conftest.$ac_ext
17170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_char_tas" >&5
17171 $as_echo "$pgac_cv_gcc_sync_char_tas" >&6; }
17172 if test x"$pgac_cv_gcc_sync_char_tas" = x"yes"; then
17174 $as_echo "#define HAVE_GCC__SYNC_CHAR_TAS 1" >>confdefs.h
17177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 locking functions" >&5
17178 $as_echo_n "checking for builtin __sync int32 locking functions... " >&6; }
17179 if ${pgac_cv_gcc_sync_int32_tas+:} false; then :
17180 $as_echo_n "(cached) " >&6
17182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17183 /* end confdefs.h. */
17189 __sync_lock_test_and_set(&lock, 1);
17190 __sync_lock_release(&lock);
17195 if ac_fn_c_try_link "$LINENO"; then :
17196 pgac_cv_gcc_sync_int32_tas="yes"
17198 pgac_cv_gcc_sync_int32_tas="no"
17200 rm -f core conftest.err conftest.$ac_objext \
17201 conftest$ac_exeext conftest.$ac_ext
17203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_tas" >&5
17204 $as_echo "$pgac_cv_gcc_sync_int32_tas" >&6; }
17205 if test x"$pgac_cv_gcc_sync_int32_tas" = x"yes"; then
17207 $as_echo "#define HAVE_GCC__SYNC_INT32_TAS 1" >>confdefs.h
17210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int32 atomic operations" >&5
17211 $as_echo_n "checking for builtin __sync int32 atomic operations... " >&6; }
17212 if ${pgac_cv_gcc_sync_int32_cas+:} false; then :
17213 $as_echo_n "(cached) " >&6
17215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17216 /* end confdefs.h. */
17222 __sync_val_compare_and_swap(&val, 0, 37);
17227 if ac_fn_c_try_link "$LINENO"; then :
17228 pgac_cv_gcc_sync_int32_cas="yes"
17230 pgac_cv_gcc_sync_int32_cas="no"
17232 rm -f core conftest.err conftest.$ac_objext \
17233 conftest$ac_exeext conftest.$ac_ext
17235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int32_cas" >&5
17236 $as_echo "$pgac_cv_gcc_sync_int32_cas" >&6; }
17237 if test x"$pgac_cv_gcc_sync_int32_cas" = x"yes"; then
17239 $as_echo "#define HAVE_GCC__SYNC_INT32_CAS 1" >>confdefs.h
17242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __sync int64 atomic operations" >&5
17243 $as_echo_n "checking for builtin __sync int64 atomic operations... " >&6; }
17244 if ${pgac_cv_gcc_sync_int64_cas+:} false; then :
17245 $as_echo_n "(cached) " >&6
17247 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17248 /* end confdefs.h. */
17253 PG_INT64_TYPE lock = 0;
17254 __sync_val_compare_and_swap(&lock, 0, (PG_INT64_TYPE) 37);
17259 if ac_fn_c_try_link "$LINENO"; then :
17260 pgac_cv_gcc_sync_int64_cas="yes"
17262 pgac_cv_gcc_sync_int64_cas="no"
17264 rm -f core conftest.err conftest.$ac_objext \
17265 conftest$ac_exeext conftest.$ac_ext
17267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_sync_int64_cas" >&5
17268 $as_echo "$pgac_cv_gcc_sync_int64_cas" >&6; }
17269 if test x"$pgac_cv_gcc_sync_int64_cas" = x"yes"; then
17271 $as_echo "#define HAVE_GCC__SYNC_INT64_CAS 1" >>confdefs.h
17274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int32 atomic operations" >&5
17275 $as_echo_n "checking for builtin __atomic int32 atomic operations... " >&6; }
17276 if ${pgac_cv_gcc_atomic_int32_cas+:} false; then :
17277 $as_echo_n "(cached) " >&6
17279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17280 /* end confdefs.h. */
17287 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17292 if ac_fn_c_try_link "$LINENO"; then :
17293 pgac_cv_gcc_atomic_int32_cas="yes"
17295 pgac_cv_gcc_atomic_int32_cas="no"
17297 rm -f core conftest.err conftest.$ac_objext \
17298 conftest$ac_exeext conftest.$ac_ext
17300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int32_cas" >&5
17301 $as_echo "$pgac_cv_gcc_atomic_int32_cas" >&6; }
17302 if test x"$pgac_cv_gcc_atomic_int32_cas" = x"yes"; then
17304 $as_echo "#define HAVE_GCC__ATOMIC_INT32_CAS 1" >>confdefs.h
17307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builtin __atomic int64 atomic operations" >&5
17308 $as_echo_n "checking for builtin __atomic int64 atomic operations... " >&6; }
17309 if ${pgac_cv_gcc_atomic_int64_cas+:} false; then :
17310 $as_echo_n "(cached) " >&6
17312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17313 /* end confdefs.h. */
17318 PG_INT64_TYPE val = 0;
17319 PG_INT64_TYPE expect = 0;
17320 __atomic_compare_exchange_n(&val, &expect, 37, 0, __ATOMIC_SEQ_CST, __ATOMIC_RELAXED);
17325 if ac_fn_c_try_link "$LINENO"; then :
17326 pgac_cv_gcc_atomic_int64_cas="yes"
17328 pgac_cv_gcc_atomic_int64_cas="no"
17330 rm -f core conftest.err conftest.$ac_objext \
17331 conftest$ac_exeext conftest.$ac_ext
17333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_gcc_atomic_int64_cas" >&5
17334 $as_echo "$pgac_cv_gcc_atomic_int64_cas" >&6; }
17335 if test x"$pgac_cv_gcc_atomic_int64_cas" = x"yes"; then
17337 $as_echo "#define HAVE_GCC__ATOMIC_INT64_CAS 1" >>confdefs.h
17342 # Check for x86 cpuid instruction
17343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __get_cpuid" >&5
17344 $as_echo_n "checking for __get_cpuid... " >&6; }
17345 if ${pgac_cv__get_cpuid+:} false; then :
17346 $as_echo_n "(cached) " >&6
17348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17349 /* end confdefs.h. */
17354 unsigned int exx[4] = {0, 0, 0, 0};
17355 __get_cpuid(1, &exx[0], &exx[1], &exx[2], &exx[3]);
17361 if ac_fn_c_try_link "$LINENO"; then :
17362 pgac_cv__get_cpuid="yes"
17364 pgac_cv__get_cpuid="no"
17366 rm -f core conftest.err conftest.$ac_objext \
17367 conftest$ac_exeext conftest.$ac_ext
17369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__get_cpuid" >&5
17370 $as_echo "$pgac_cv__get_cpuid" >&6; }
17371 if test x"$pgac_cv__get_cpuid" = x"yes"; then
17373 $as_echo "#define HAVE__GET_CPUID 1" >>confdefs.h
17377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __cpuid" >&5
17378 $as_echo_n "checking for __cpuid... " >&6; }
17379 if ${pgac_cv__cpuid+:} false; then :
17380 $as_echo_n "(cached) " >&6
17382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17383 /* end confdefs.h. */
17384 #include <intrin.h>
17388 unsigned int exx[4] = {0, 0, 0, 0};
17389 __get_cpuid(exx[0], 1);
17395 if ac_fn_c_try_link "$LINENO"; then :
17396 pgac_cv__cpuid="yes"
17398 pgac_cv__cpuid="no"
17400 rm -f core conftest.err conftest.$ac_objext \
17401 conftest$ac_exeext conftest.$ac_ext
17403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv__cpuid" >&5
17404 $as_echo "$pgac_cv__cpuid" >&6; }
17405 if test x"$pgac_cv__cpuid" = x"yes"; then
17407 $as_echo "#define HAVE__CPUID 1" >>confdefs.h
17411 # Check for Intel SSE 4.2 intrinsics to do CRC calculations.
17413 # First check if the _mm_crc32_u8 and _mm_crc32_u64 intrinsics can be used
17414 # with the default compiler flags. If not, check if adding the -msse4.2
17415 # flag helps. CFLAGS_SSE42 is set to -msse4.2 if that's required.
17416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=" >&5
17417 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=... " >&6; }
17418 if ${pgac_cv_sse42_crc32_intrinsics_+:} false; then :
17419 $as_echo_n "(cached) " >&6
17421 pgac_save_CFLAGS=$CFLAGS
17422 CFLAGS="$pgac_save_CFLAGS "
17423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17424 /* end confdefs.h. */
17425 #include <nmmintrin.h>
17429 unsigned int crc = 0;
17430 crc = _mm_crc32_u8(crc, 0);
17431 crc = _mm_crc32_u32(crc, 0);
17432 /* return computed value, to prevent the above being optimized away */
17438 if ac_fn_c_try_link "$LINENO"; then :
17439 pgac_cv_sse42_crc32_intrinsics_=yes
17441 pgac_cv_sse42_crc32_intrinsics_=no
17443 rm -f core conftest.err conftest.$ac_objext \
17444 conftest$ac_exeext conftest.$ac_ext
17445 CFLAGS="$pgac_save_CFLAGS"
17447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics_" >&5
17448 $as_echo "$pgac_cv_sse42_crc32_intrinsics_" >&6; }
17449 if test x"$pgac_cv_sse42_crc32_intrinsics_" = x"yes"; then
17451 pgac_sse42_crc32_intrinsics=yes
17454 if test x"$pgac_sse42_crc32_intrinsics" != x"yes"; then
17455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2" >&5
17456 $as_echo_n "checking for _mm_crc32_u8 and _mm_crc32_u32 with CFLAGS=-msse4.2... " >&6; }
17457 if ${pgac_cv_sse42_crc32_intrinsics__msse4_2+:} false; then :
17458 $as_echo_n "(cached) " >&6
17460 pgac_save_CFLAGS=$CFLAGS
17461 CFLAGS="$pgac_save_CFLAGS -msse4.2"
17462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17463 /* end confdefs.h. */
17464 #include <nmmintrin.h>
17468 unsigned int crc = 0;
17469 crc = _mm_crc32_u8(crc, 0);
17470 crc = _mm_crc32_u32(crc, 0);
17471 /* return computed value, to prevent the above being optimized away */
17477 if ac_fn_c_try_link "$LINENO"; then :
17478 pgac_cv_sse42_crc32_intrinsics__msse4_2=yes
17480 pgac_cv_sse42_crc32_intrinsics__msse4_2=no
17482 rm -f core conftest.err conftest.$ac_objext \
17483 conftest$ac_exeext conftest.$ac_ext
17484 CFLAGS="$pgac_save_CFLAGS"
17486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_sse42_crc32_intrinsics__msse4_2" >&5
17487 $as_echo "$pgac_cv_sse42_crc32_intrinsics__msse4_2" >&6; }
17488 if test x"$pgac_cv_sse42_crc32_intrinsics__msse4_2" = x"yes"; then
17489 CFLAGS_SSE42="-msse4.2"
17490 pgac_sse42_crc32_intrinsics=yes
17496 # Are we targeting a processor that supports SSE 4.2? gcc, clang and icc all
17497 # define __SSE4_2__ in that case.
17498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17499 /* end confdefs.h. */
17506 #error __SSE4_2__ not defined
17513 if ac_fn_c_try_compile "$LINENO"; then :
17516 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17518 # Check for ARMv8 CRC Extension intrinsics to do CRC calculations.
17520 # First check if __crc32c* intrinsics can be used with the default compiler
17521 # flags. If not, check if adding -march=armv8-a+crc flag helps.
17522 # CFLAGS_ARMV8_CRC32C is set if the extra flag is required.
17523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=" >&5
17524 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=... " >&6; }
17525 if ${pgac_cv_armv8_crc32c_intrinsics_+:} false; then :
17526 $as_echo_n "(cached) " >&6
17528 pgac_save_CFLAGS=$CFLAGS
17529 CFLAGS="$pgac_save_CFLAGS "
17530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17531 /* end confdefs.h. */
17532 #include <arm_acle.h>
17536 unsigned int crc = 0;
17537 crc = __crc32cb(crc, 0);
17538 crc = __crc32ch(crc, 0);
17539 crc = __crc32cw(crc, 0);
17540 crc = __crc32cd(crc, 0);
17541 /* return computed value, to prevent the above being optimized away */
17547 if ac_fn_c_try_link "$LINENO"; then :
17548 pgac_cv_armv8_crc32c_intrinsics_=yes
17550 pgac_cv_armv8_crc32c_intrinsics_=no
17552 rm -f core conftest.err conftest.$ac_objext \
17553 conftest$ac_exeext conftest.$ac_ext
17554 CFLAGS="$pgac_save_CFLAGS"
17556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics_" >&5
17557 $as_echo "$pgac_cv_armv8_crc32c_intrinsics_" >&6; }
17558 if test x"$pgac_cv_armv8_crc32c_intrinsics_" = x"yes"; then
17559 CFLAGS_ARMV8_CRC32C=""
17560 pgac_armv8_crc32c_intrinsics=yes
17563 if test x"$pgac_armv8_crc32c_intrinsics" != x"yes"; then
17564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc" >&5
17565 $as_echo_n "checking for __crc32cb, __crc32ch, __crc32cw, and __crc32cd with CFLAGS=-march=armv8-a+crc... " >&6; }
17566 if ${pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc+:} false; then :
17567 $as_echo_n "(cached) " >&6
17569 pgac_save_CFLAGS=$CFLAGS
17570 CFLAGS="$pgac_save_CFLAGS -march=armv8-a+crc"
17571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17572 /* end confdefs.h. */
17573 #include <arm_acle.h>
17577 unsigned int crc = 0;
17578 crc = __crc32cb(crc, 0);
17579 crc = __crc32ch(crc, 0);
17580 crc = __crc32cw(crc, 0);
17581 crc = __crc32cd(crc, 0);
17582 /* return computed value, to prevent the above being optimized away */
17588 if ac_fn_c_try_link "$LINENO"; then :
17589 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=yes
17591 pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc=no
17593 rm -f core conftest.err conftest.$ac_objext \
17594 conftest$ac_exeext conftest.$ac_ext
17595 CFLAGS="$pgac_save_CFLAGS"
17597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&5
17598 $as_echo "$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" >&6; }
17599 if test x"$pgac_cv_armv8_crc32c_intrinsics__march_armv8_apcrc" = x"yes"; then
17600 CFLAGS_ARMV8_CRC32C="-march=armv8-a+crc"
17601 pgac_armv8_crc32c_intrinsics=yes
17607 # Select CRC-32C implementation.
17609 # If we are targeting a processor that has Intel SSE 4.2 instructions, we can
17610 # use the special CRC instructions for calculating CRC-32C. If we're not
17611 # targeting such a processor, but we can nevertheless produce code that uses
17612 # the SSE intrinsics, perhaps with some extra CFLAGS, compile both
17613 # implementations and select which one to use at runtime, depending on whether
17614 # SSE 4.2 is supported by the processor we're running on.
17616 # Similarly, if we are targeting an ARM processor that has the CRC
17617 # instructions that are part of the ARMv8 CRC Extension, use them. And if
17618 # we're not targeting such a processor, but can nevertheless produce code that
17619 # uses the CRC instructions, compile both, and select at runtime.
17621 # You can override this logic by setting the appropriate USE_*_CRC32 flag to 1
17622 # in the template or configure command line.
17623 if test x"$USE_SLICING_BY_8_CRC32C" = x"" && test x"$USE_SSE42_CRC32C" = x"" && test x"$USE_SSE42_CRC32C_WITH_RUNTIME_CHECK" = x"" && test x"$USE_ARMV8_CRC32C" = x"" && test x"$USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK" = x""; then
17624 # Use Intel SSE 4.2 if available.
17625 if test x"$pgac_sse42_crc32_intrinsics" = x"yes" && test x"$SSE4_2_TARGETED" = x"1" ; then
17628 # Intel SSE 4.2, with runtime check? The CPUID instruction is needed for
17629 # the runtime check.
17630 if test x"$pgac_sse42_crc32_intrinsics" = x"yes" && (test x"$pgac_cv__get_cpuid" = x"yes" || test x"$pgac_cv__cpuid" = x"yes"); then
17631 USE_SSE42_CRC32C_WITH_RUNTIME_CHECK=1
17633 # Use ARM CRC Extension if available.
17634 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes" && test x"$CFLAGS_ARMV8_CRC32C" = x""; then
17637 # ARM CRC Extension, with runtime check?
17638 if test x"$pgac_armv8_crc32c_intrinsics" = x"yes"; then
17639 USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK=1
17641 # fall back to slicing-by-8 algorithm, which doesn't require any
17642 # special CPU support.
17643 USE_SLICING_BY_8_CRC32C=1
17650 # Set PG_CRC32C_OBJS appropriately depending on the selected implementation.
17651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which CRC-32C implementation to use" >&5
17652 $as_echo_n "checking which CRC-32C implementation to use... " >&6; }
17653 if test x"$USE_SSE42_CRC32C" = x"1"; then
17655 $as_echo "#define USE_SSE42_CRC32C 1" >>confdefs.h
17657 PG_CRC32C_OBJS="pg_crc32c_sse42.o"
17658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2" >&5
17659 $as_echo "SSE 4.2" >&6; }
17661 if test x"$USE_SSE42_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17663 $as_echo "#define USE_SSE42_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17665 PG_CRC32C_OBJS="pg_crc32c_sse42.o pg_crc32c_sb8.o pg_crc32c_sse42_choose.o"
17666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: SSE 4.2 with runtime check" >&5
17667 $as_echo "SSE 4.2 with runtime check" >&6; }
17669 if test x"$USE_ARMV8_CRC32C" = x"1"; then
17671 $as_echo "#define USE_ARMV8_CRC32C 1" >>confdefs.h
17673 PG_CRC32C_OBJS="pg_crc32c_armv8.o"
17674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions" >&5
17675 $as_echo "ARMv8 CRC instructions" >&6; }
17677 if test x"$USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK" = x"1"; then
17679 $as_echo "#define USE_ARMV8_CRC32C_WITH_RUNTIME_CHECK 1" >>confdefs.h
17681 PG_CRC32C_OBJS="pg_crc32c_armv8.o pg_crc32c_sb8.o pg_crc32c_armv8_choose.o"
17682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ARMv8 CRC instructions with runtime check" >&5
17683 $as_echo "ARMv8 CRC instructions with runtime check" >&6; }
17686 $as_echo "#define USE_SLICING_BY_8_CRC32C 1" >>confdefs.h
17688 PG_CRC32C_OBJS="pg_crc32c_sb8.o"
17689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: slicing-by-8" >&5
17690 $as_echo "slicing-by-8" >&6; }
17698 # Select semaphore implementation type.
17699 if test "$PORTNAME" != "win32"; then
17700 if test x"$PREFERRED_SEMAPHORES" = x"NAMED_POSIX" ; then
17701 # Need sem_open for this
17702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_open" >&5
17703 $as_echo_n "checking for library containing sem_open... " >&6; }
17704 if ${ac_cv_search_sem_open+:} false; then :
17705 $as_echo_n "(cached) " >&6
17707 ac_func_search_save_LIBS=$LIBS
17708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17709 /* end confdefs.h. */
17711 /* Override any GCC internal prototype to avoid an error.
17712 Use char because int might match the return type of a GCC
17713 builtin and then its argument prototype would still apply. */
17721 return sem_open ();
17726 for ac_lib in '' rt pthread; do
17727 if test -z "$ac_lib"; then
17728 ac_res="none required"
17731 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17733 if ac_fn_c_try_link "$LINENO"; then :
17734 ac_cv_search_sem_open=$ac_res
17736 rm -f core conftest.err conftest.$ac_objext \
17738 if ${ac_cv_search_sem_open+:} false; then :
17742 if ${ac_cv_search_sem_open+:} false; then :
17745 ac_cv_search_sem_open=no
17747 rm conftest.$ac_ext
17748 LIBS=$ac_func_search_save_LIBS
17750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_open" >&5
17751 $as_echo "$ac_cv_search_sem_open" >&6; }
17752 ac_res=$ac_cv_search_sem_open
17753 if test "$ac_res" != no; then :
17754 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17755 USE_NAMED_POSIX_SEMAPHORES=1
17759 if test x"$PREFERRED_SEMAPHORES" = x"UNNAMED_POSIX" ; then
17760 # Need sem_init for this
17761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing sem_init" >&5
17762 $as_echo_n "checking for library containing sem_init... " >&6; }
17763 if ${ac_cv_search_sem_init+:} false; then :
17764 $as_echo_n "(cached) " >&6
17766 ac_func_search_save_LIBS=$LIBS
17767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17768 /* end confdefs.h. */
17770 /* Override any GCC internal prototype to avoid an error.
17771 Use char because int might match the return type of a GCC
17772 builtin and then its argument prototype would still apply. */
17780 return sem_init ();
17785 for ac_lib in '' rt pthread; do
17786 if test -z "$ac_lib"; then
17787 ac_res="none required"
17790 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17792 if ac_fn_c_try_link "$LINENO"; then :
17793 ac_cv_search_sem_init=$ac_res
17795 rm -f core conftest.err conftest.$ac_objext \
17797 if ${ac_cv_search_sem_init+:} false; then :
17801 if ${ac_cv_search_sem_init+:} false; then :
17804 ac_cv_search_sem_init=no
17806 rm conftest.$ac_ext
17807 LIBS=$ac_func_search_save_LIBS
17809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_sem_init" >&5
17810 $as_echo "$ac_cv_search_sem_init" >&6; }
17811 ac_res=$ac_cv_search_sem_init
17812 if test "$ac_res" != no; then :
17813 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17814 USE_UNNAMED_POSIX_SEMAPHORES=1
17818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which semaphore API to use" >&5
17819 $as_echo_n "checking which semaphore API to use... " >&6; }
17820 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
17822 $as_echo "#define USE_NAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17824 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17825 sematype="named POSIX"
17827 if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
17829 $as_echo "#define USE_UNNAMED_POSIX_SEMAPHORES 1" >>confdefs.h
17831 SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
17832 sematype="unnamed POSIX"
17835 $as_echo "#define USE_SYSV_SEMAPHORES 1" >>confdefs.h
17837 SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
17838 sematype="System V"
17841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $sematype" >&5
17842 $as_echo "$sematype" >&6; }
17845 $as_echo "#define USE_WIN32_SEMAPHORES 1" >>confdefs.h
17847 SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
17851 # Select shared-memory implementation type.
17852 if test "$PORTNAME" != "win32"; then
17854 $as_echo "#define USE_SYSV_SHARED_MEMORY 1" >>confdefs.h
17856 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
17859 $as_echo "#define USE_WIN32_SHARED_MEMORY 1" >>confdefs.h
17861 SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
17864 # Select random number source
17866 # You can override this logic by setting the appropriate USE_*RANDOM flag to 1
17867 # in the template or configure command line.
17869 # If not selected manually, try to select a source automatically.
17870 if test "$enable_strong_random" = "yes" && test x"$USE_OPENSSL_RANDOM" = x"" && test x"$USE_WIN32_RANDOM" = x"" && test x"$USE_DEV_URANDOM" = x"" ; then
17871 if test x"$with_openssl" = x"yes" ; then
17872 USE_OPENSSL_RANDOM=1
17873 elif test "$PORTNAME" = "win32" ; then
17876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /dev/urandom" >&5
17877 $as_echo_n "checking for /dev/urandom... " >&6; }
17878 if ${ac_cv_file__dev_urandom+:} false; then :
17879 $as_echo_n "(cached) " >&6
17881 test "$cross_compiling" = yes &&
17882 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
17883 if test -r "/dev/urandom"; then
17884 ac_cv_file__dev_urandom=yes
17886 ac_cv_file__dev_urandom=no
17889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__dev_urandom" >&5
17890 $as_echo "$ac_cv_file__dev_urandom" >&6; }
17891 if test "x$ac_cv_file__dev_urandom" = xyes; then :
17896 if test x"$ac_cv_file__dev_urandom" = x"yes" ; then
17902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which random number source to use" >&5
17903 $as_echo_n "checking which random number source to use... " >&6; }
17904 if test "$enable_strong_random" = yes ; then
17905 if test x"$USE_OPENSSL_RANDOM" = x"1" ; then
17907 $as_echo "#define USE_OPENSSL_RANDOM 1" >>confdefs.h
17909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: OpenSSL" >&5
17910 $as_echo "OpenSSL" >&6; }
17911 elif test x"$USE_WIN32_RANDOM" = x"1" ; then
17913 $as_echo "#define USE_WIN32_RANDOM 1" >>confdefs.h
17915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows native" >&5
17916 $as_echo "Windows native" >&6; }
17917 elif test x"$USE_DEV_URANDOM" = x"1" ; then
17919 $as_echo "#define USE_DEV_URANDOM 1" >>confdefs.h
17921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: /dev/urandom" >&5
17922 $as_echo "/dev/urandom" >&6; }
17925 no source of strong random numbers was found
17926 PostgreSQL can use OpenSSL or /dev/urandom as a source of random numbers,
17927 for authentication protocols. You can use --disable-strong-random to use a
17928 built-in pseudo random number generator, but that may be insecure." "$LINENO" 5
17931 $as_echo "#define HAVE_STRONG_RANDOM 1" >>confdefs.h
17934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: weak builtin PRNG" >&5
17935 $as_echo "weak builtin PRNG" >&6; }
17936 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
17937 *** Not using a strong random number source may be insecure." >&5
17938 $as_echo "$as_me: WARNING:
17939 *** Not using a strong random number source may be insecure." >&2;}
17942 # If not set in template file, set bytes to use libc memset()
17943 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
17944 MEMSET_LOOP_LIMIT=1024
17947 cat >>confdefs.h <<_ACEOF
17948 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
17953 if test "$enable_nls" = yes ; then
17955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing bind_textdomain_codeset" >&5
17956 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
17957 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17958 $as_echo_n "(cached) " >&6
17960 ac_func_search_save_LIBS=$LIBS
17961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17962 /* end confdefs.h. */
17964 /* Override any GCC internal prototype to avoid an error.
17965 Use char because int might match the return type of a GCC
17966 builtin and then its argument prototype would still apply. */
17970 char bind_textdomain_codeset ();
17974 return bind_textdomain_codeset ();
17979 for ac_lib in '' intl; do
17980 if test -z "$ac_lib"; then
17981 ac_res="none required"
17984 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17986 if ac_fn_c_try_link "$LINENO"; then :
17987 ac_cv_search_bind_textdomain_codeset=$ac_res
17989 rm -f core conftest.err conftest.$ac_objext \
17991 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17995 if ${ac_cv_search_bind_textdomain_codeset+:} false; then :
17998 ac_cv_search_bind_textdomain_codeset=no
18000 rm conftest.$ac_ext
18001 LIBS=$ac_func_search_save_LIBS
18003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_bind_textdomain_codeset" >&5
18004 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
18005 ac_res=$ac_cv_search_bind_textdomain_codeset
18006 if test "$ac_res" != no; then :
18007 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
18010 as_fn_error $? "a gettext implementation is required for NLS" "$LINENO" 5
18013 ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
18014 if test "x$ac_cv_header_libintl_h" = xyes; then :
18017 as_fn_error $? "header file <libintl.h> is required for NLS" "$LINENO" 5
18021 if test -z "$MSGFMT"; then
18022 for ac_prog in msgfmt
18024 # Extract the first word of "$ac_prog", so it can be a program name with args.
18025 set dummy $ac_prog; ac_word=$2
18026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18027 $as_echo_n "checking for $ac_word... " >&6; }
18028 if ${ac_cv_path_MSGFMT+:} false; then :
18029 $as_echo_n "(cached) " >&6
18033 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
18036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18037 for as_dir in $PATH
18040 test -z "$as_dir" && as_dir=.
18041 for ac_exec_ext in '' $ac_executable_extensions; do
18042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18043 ac_cv_path_MSGFMT="$as_dir/$ac_word$ac_exec_ext"
18044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18054 MSGFMT=$ac_cv_path_MSGFMT
18055 if test -n "$MSGFMT"; then
18056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
18057 $as_echo "$MSGFMT" >&6; }
18059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18060 $as_echo "no" >&6; }
18064 test -n "$MSGFMT" && break
18068 # Report the value of MSGFMT in configure's output in all cases.
18069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGFMT" >&5
18070 $as_echo_n "checking for MSGFMT... " >&6; }
18071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
18072 $as_echo "$MSGFMT" >&6; }
18075 if test -z "$MSGFMT"; then
18076 as_fn_error $? "msgfmt is required for NLS" "$LINENO" 5
18078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msgfmt flags" >&5
18079 $as_echo_n "checking for msgfmt flags... " >&6; }
18080 if ${pgac_cv_msgfmt_flags+:} false; then :
18081 $as_echo_n "(cached) " >&6
18083 if test x"$MSGFMT" != x"" && "$MSGFMT" --version 2>&1 | grep "GNU" >/dev/null; then
18084 pgac_cv_msgfmt_flags=-c
18087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_msgfmt_flags" >&5
18088 $as_echo "$pgac_cv_msgfmt_flags" >&6; }
18089 MSGFMT_FLAGS=$pgac_cv_msgfmt_flags
18091 if test -z "$MSGMERGE"; then
18092 for ac_prog in msgmerge
18094 # Extract the first word of "$ac_prog", so it can be a program name with args.
18095 set dummy $ac_prog; ac_word=$2
18096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18097 $as_echo_n "checking for $ac_word... " >&6; }
18098 if ${ac_cv_path_MSGMERGE+:} false; then :
18099 $as_echo_n "(cached) " >&6
18103 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
18106 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18107 for as_dir in $PATH
18110 test -z "$as_dir" && as_dir=.
18111 for ac_exec_ext in '' $ac_executable_extensions; do
18112 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18113 ac_cv_path_MSGMERGE="$as_dir/$ac_word$ac_exec_ext"
18114 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18124 MSGMERGE=$ac_cv_path_MSGMERGE
18125 if test -n "$MSGMERGE"; then
18126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18127 $as_echo "$MSGMERGE" >&6; }
18129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18130 $as_echo "no" >&6; }
18134 test -n "$MSGMERGE" && break
18138 # Report the value of MSGMERGE in configure's output in all cases.
18139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSGMERGE" >&5
18140 $as_echo_n "checking for MSGMERGE... " >&6; }
18141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
18142 $as_echo "$MSGMERGE" >&6; }
18145 if test -z "$XGETTEXT"; then
18146 for ac_prog in xgettext
18148 # Extract the first word of "$ac_prog", so it can be a program name with args.
18149 set dummy $ac_prog; ac_word=$2
18150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18151 $as_echo_n "checking for $ac_word... " >&6; }
18152 if ${ac_cv_path_XGETTEXT+:} false; then :
18153 $as_echo_n "(cached) " >&6
18157 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
18160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18161 for as_dir in $PATH
18164 test -z "$as_dir" && as_dir=.
18165 for ac_exec_ext in '' $ac_executable_extensions; do
18166 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18167 ac_cv_path_XGETTEXT="$as_dir/$ac_word$ac_exec_ext"
18168 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18178 XGETTEXT=$ac_cv_path_XGETTEXT
18179 if test -n "$XGETTEXT"; then
18180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18181 $as_echo "$XGETTEXT" >&6; }
18183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18184 $as_echo "no" >&6; }
18188 test -n "$XGETTEXT" && break
18192 # Report the value of XGETTEXT in configure's output in all cases.
18193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XGETTEXT" >&5
18194 $as_echo_n "checking for XGETTEXT... " >&6; }
18195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
18196 $as_echo "$XGETTEXT" >&6; }
18202 # Check for Tcl configuration script tclConfig.sh
18203 if test "$with_tcl" = yes; then
18204 if test -z "$TCLSH"; then
18205 for ac_prog in tclsh tcl tclsh8.6 tclsh86 tclsh8.5 tclsh85 tclsh8.4 tclsh84
18207 # Extract the first word of "$ac_prog", so it can be a program name with args.
18208 set dummy $ac_prog; ac_word=$2
18209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18210 $as_echo_n "checking for $ac_word... " >&6; }
18211 if ${ac_cv_path_TCLSH+:} false; then :
18212 $as_echo_n "(cached) " >&6
18216 ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
18219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18220 for as_dir in $PATH
18223 test -z "$as_dir" && as_dir=.
18224 for ac_exec_ext in '' $ac_executable_extensions; do
18225 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18226 ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
18227 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18237 TCLSH=$ac_cv_path_TCLSH
18238 if test -n "$TCLSH"; then
18239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18240 $as_echo "$TCLSH" >&6; }
18242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18243 $as_echo "no" >&6; }
18247 test -n "$TCLSH" && break
18251 # Report the value of TCLSH in configure's output in all cases.
18252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TCLSH" >&5
18253 $as_echo_n "checking for TCLSH... " >&6; }
18254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCLSH" >&5
18255 $as_echo "$TCLSH" >&6; }
18258 if test x"$TCLSH" = x""; then
18259 as_fn_error $? "Tcl shell not found" "$LINENO" 5
18262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tclConfig.sh" >&5
18263 $as_echo_n "checking for tclConfig.sh... " >&6; }
18264 # Let user override test
18265 if test -z "$TCL_CONFIG_SH"; then
18266 pgac_test_dirs="$with_tclconfig"
18268 set X $pgac_test_dirs; shift
18269 if test $# -eq 0; then
18270 test -z "$TCLSH" && as_fn_error $? "unable to locate tclConfig.sh because no Tcl shell was found" "$LINENO" 5
18271 set X `echo 'puts $auto_path' | $TCLSH`; shift
18275 if test -r "$pgac_dir/tclConfig.sh"; then
18276 TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
18282 if test -z "$TCL_CONFIG_SH"; then
18283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18284 $as_echo "no" >&6; }
18285 as_fn_error $? "file 'tclConfig.sh' is required for Tcl" "$LINENO" 5
18287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TCL_CONFIG_SH" >&5
18288 $as_echo "$TCL_CONFIG_SH" >&6; }
18294 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
18295 eval TCL_LIBS=\"$TCL_LIBS\"
18296 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
18297 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
18299 if test "$TCL_SHARED_BUILD" != 1; then
18300 as_fn_error $? "cannot build PL/Tcl because Tcl is not a shared library
18301 Use --without-tcl to disable building PL/Tcl." "$LINENO" 5
18303 # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
18304 ac_save_CPPFLAGS=$CPPFLAGS
18305 CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
18306 ac_fn_c_check_header_mongrel "$LINENO" "tcl.h" "ac_cv_header_tcl_h" "$ac_includes_default"
18307 if test "x$ac_cv_header_tcl_h" = xyes; then :
18310 as_fn_error $? "header file <tcl.h> is required for Tcl" "$LINENO" 5
18314 CPPFLAGS=$ac_save_CPPFLAGS
18317 # check for <perl.h>
18318 if test "$with_perl" = yes; then
18319 ac_save_CPPFLAGS=$CPPFLAGS
18320 CPPFLAGS="$CPPFLAGS -I$perl_archlibexp/CORE"
18321 ac_fn_c_check_header_compile "$LINENO" "perl.h" "ac_cv_header_perl_h" "#include <EXTERN.h>
18323 if test "x$ac_cv_header_perl_h" = xyes; then :
18326 as_fn_error $? "header file <perl.h> is required for Perl" "$LINENO" 5
18330 # While we're at it, check that we can link to libperl.
18331 # On most platforms, if perl.h is there then libperl.so will be too, but at
18332 # this writing Debian packages them separately. There is no known reason to
18333 # waste cycles on separate probes for the Tcl or Python libraries, though.
18334 pgac_save_LIBS=$LIBS
18335 LIBS="$perl_embed_ldflags"
18336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libperl" >&5
18337 $as_echo_n "checking for libperl... " >&6; }
18338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18339 /* end confdefs.h. */
18341 #include <EXTERN.h>
18352 if ac_fn_c_try_link "$LINENO"; then :
18353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18354 $as_echo "yes" >&6; }
18356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18357 $as_echo "no" >&6; }
18358 as_fn_error $? "libperl library is required for Perl" "$LINENO" 5
18360 rm -f core conftest.err conftest.$ac_objext \
18361 conftest$ac_exeext conftest.$ac_ext
18362 LIBS=$pgac_save_LIBS
18363 CPPFLAGS=$ac_save_CPPFLAGS
18366 # check for <Python.h>
18367 if test "$with_python" = yes; then
18368 ac_save_CPPFLAGS=$CPPFLAGS
18369 CPPFLAGS="$python_includespec $CPPFLAGS"
18370 ac_fn_c_check_header_mongrel "$LINENO" "Python.h" "ac_cv_header_Python_h" "$ac_includes_default"
18371 if test "x$ac_cv_header_Python_h" = xyes; then :
18374 as_fn_error $? "header file <Python.h> is required for Python" "$LINENO" 5
18378 CPPFLAGS=$ac_save_CPPFLAGS
18382 # Check for DocBook and tools
18384 if test -z "$XMLLINT"; then
18385 for ac_prog in xmllint
18387 # Extract the first word of "$ac_prog", so it can be a program name with args.
18388 set dummy $ac_prog; ac_word=$2
18389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18390 $as_echo_n "checking for $ac_word... " >&6; }
18391 if ${ac_cv_path_XMLLINT+:} false; then :
18392 $as_echo_n "(cached) " >&6
18396 ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
18399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18400 for as_dir in $PATH
18403 test -z "$as_dir" && as_dir=.
18404 for ac_exec_ext in '' $ac_executable_extensions; do
18405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18406 ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
18407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18417 XMLLINT=$ac_cv_path_XMLLINT
18418 if test -n "$XMLLINT"; then
18419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18420 $as_echo "$XMLLINT" >&6; }
18422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18423 $as_echo "no" >&6; }
18427 test -n "$XMLLINT" && break
18431 # Report the value of XMLLINT in configure's output in all cases.
18432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XMLLINT" >&5
18433 $as_echo_n "checking for XMLLINT... " >&6; }
18434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
18435 $as_echo "$XMLLINT" >&6; }
18439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DocBook XML V4.2" >&5
18440 $as_echo_n "checking for DocBook XML V4.2... " >&6; }
18441 if ${pgac_cv_check_docbook+:} false; then :
18442 $as_echo_n "(cached) " >&6
18444 cat >conftest.xml <<EOF
18445 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
18447 <title>test</title>
18449 <title>random</title>
18451 <title>testsect</title>
18458 pgac_cv_check_docbook=no
18460 if test -n "$XMLLINT"; then
18461 $XMLLINT --noout --valid conftest.xml 1>&5 2>&1
18462 if test $? -eq 0; then
18463 pgac_cv_check_docbook=yes
18468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_check_docbook" >&5
18469 $as_echo "$pgac_cv_check_docbook" >&6; }
18471 have_docbook=$pgac_cv_check_docbook
18474 if test -z "$DBTOEPUB"; then
18475 for ac_prog in dbtoepub
18477 # Extract the first word of "$ac_prog", so it can be a program name with args.
18478 set dummy $ac_prog; ac_word=$2
18479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18480 $as_echo_n "checking for $ac_word... " >&6; }
18481 if ${ac_cv_path_DBTOEPUB+:} false; then :
18482 $as_echo_n "(cached) " >&6
18486 ac_cv_path_DBTOEPUB="$DBTOEPUB" # Let the user override the test with a path.
18489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18490 for as_dir in $PATH
18493 test -z "$as_dir" && as_dir=.
18494 for ac_exec_ext in '' $ac_executable_extensions; do
18495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18496 ac_cv_path_DBTOEPUB="$as_dir/$ac_word$ac_exec_ext"
18497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18507 DBTOEPUB=$ac_cv_path_DBTOEPUB
18508 if test -n "$DBTOEPUB"; then
18509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18510 $as_echo "$DBTOEPUB" >&6; }
18512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18513 $as_echo "no" >&6; }
18517 test -n "$DBTOEPUB" && break
18521 # Report the value of DBTOEPUB in configure's output in all cases.
18522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DBTOEPUB" >&5
18523 $as_echo_n "checking for DBTOEPUB... " >&6; }
18524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBTOEPUB" >&5
18525 $as_echo "$DBTOEPUB" >&6; }
18528 if test -z "$XSLTPROC"; then
18529 for ac_prog in xsltproc
18531 # Extract the first word of "$ac_prog", so it can be a program name with args.
18532 set dummy $ac_prog; ac_word=$2
18533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18534 $as_echo_n "checking for $ac_word... " >&6; }
18535 if ${ac_cv_path_XSLTPROC+:} false; then :
18536 $as_echo_n "(cached) " >&6
18540 ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
18543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18544 for as_dir in $PATH
18547 test -z "$as_dir" && as_dir=.
18548 for ac_exec_ext in '' $ac_executable_extensions; do
18549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18550 ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
18551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18561 XSLTPROC=$ac_cv_path_XSLTPROC
18562 if test -n "$XSLTPROC"; then
18563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18564 $as_echo "$XSLTPROC" >&6; }
18566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18567 $as_echo "no" >&6; }
18571 test -n "$XSLTPROC" && break
18575 # Report the value of XSLTPROC in configure's output in all cases.
18576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XSLTPROC" >&5
18577 $as_echo_n "checking for XSLTPROC... " >&6; }
18578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
18579 $as_echo "$XSLTPROC" >&6; }
18582 if test -z "$FOP"; then
18585 # Extract the first word of "$ac_prog", so it can be a program name with args.
18586 set dummy $ac_prog; ac_word=$2
18587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18588 $as_echo_n "checking for $ac_word... " >&6; }
18589 if ${ac_cv_path_FOP+:} false; then :
18590 $as_echo_n "(cached) " >&6
18594 ac_cv_path_FOP="$FOP" # Let the user override the test with a path.
18597 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18598 for as_dir in $PATH
18601 test -z "$as_dir" && as_dir=.
18602 for ac_exec_ext in '' $ac_executable_extensions; do
18603 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18604 ac_cv_path_FOP="$as_dir/$ac_word$ac_exec_ext"
18605 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18615 FOP=$ac_cv_path_FOP
18616 if test -n "$FOP"; then
18617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18618 $as_echo "$FOP" >&6; }
18620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18621 $as_echo "no" >&6; }
18625 test -n "$FOP" && break
18629 # Report the value of FOP in configure's output in all cases.
18630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FOP" >&5
18631 $as_echo_n "checking for FOP... " >&6; }
18632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FOP" >&5
18633 $as_echo "$FOP" >&6; }
18638 # Check for test tools
18640 if test "$enable_tap_tests" = yes; then
18641 # Check for necessary modules, unless user has specified the "prove" to use;
18642 # in that case it's her responsibility to have a working configuration.
18643 # (prove might be part of a different Perl installation than perl, eg on
18644 # MSys, so the result of AX_PROG_PERL_MODULES could be irrelevant anyway.)
18645 if test -z "$PROVE"; then
18646 # Test::More and Time::HiRes are supposed to be part of core Perl,
18647 # but some distros omit them in a minimal installation.
18658 # Make sure we have perl
18659 if test -z "$PERL"; then
18660 # Extract the first word of "perl", so it can be a program name with args.
18661 set dummy perl; ac_word=$2
18662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18663 $as_echo_n "checking for $ac_word... " >&6; }
18664 if ${ac_cv_prog_PERL+:} false; then :
18665 $as_echo_n "(cached) " >&6
18667 if test -n "$PERL"; then
18668 ac_cv_prog_PERL="$PERL" # Let the user override the test.
18670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18671 for as_dir in $PATH
18674 test -z "$as_dir" && as_dir=.
18675 for ac_exec_ext in '' $ac_executable_extensions; do
18676 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18677 ac_cv_prog_PERL="perl"
18678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18687 PERL=$ac_cv_prog_PERL
18688 if test -n "$PERL"; then
18689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
18690 $as_echo "$PERL" >&6; }
18692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18693 $as_echo "no" >&6; }
18699 if test "x$PERL" != x; then
18700 ax_perl_modules_failed=0
18701 for ax_perl_module in 'IPC::Run' 'Test::More 0.87' 'Time::HiRes' ; do
18702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5
18703 $as_echo_n "checking for perl module $ax_perl_module... " >&6; }
18705 # Would be nice to log result here, but can't rely on autoconf internals
18706 $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1
18707 if test $? -ne 0; then
18708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18709 $as_echo "no" >&6; };
18710 ax_perl_modules_failed=1
18712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
18713 $as_echo "ok" >&6; };
18717 # Run optional shell commands
18718 if test "$ax_perl_modules_failed" = 0; then
18723 as_fn_error $? "Additional Perl modules are required to run TAP tests" "$LINENO" 5
18726 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5
18727 $as_echo "$as_me: WARNING: could not find perl" >&2;}
18730 # Now make sure we know where prove is
18731 if test -z "$PROVE"; then
18732 for ac_prog in prove
18734 # Extract the first word of "$ac_prog", so it can be a program name with args.
18735 set dummy $ac_prog; ac_word=$2
18736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18737 $as_echo_n "checking for $ac_word... " >&6; }
18738 if ${ac_cv_path_PROVE+:} false; then :
18739 $as_echo_n "(cached) " >&6
18743 ac_cv_path_PROVE="$PROVE" # Let the user override the test with a path.
18746 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18747 for as_dir in $PATH
18750 test -z "$as_dir" && as_dir=.
18751 for ac_exec_ext in '' $ac_executable_extensions; do
18752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18753 ac_cv_path_PROVE="$as_dir/$ac_word$ac_exec_ext"
18754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18764 PROVE=$ac_cv_path_PROVE
18765 if test -n "$PROVE"; then
18766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18767 $as_echo "$PROVE" >&6; }
18769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18770 $as_echo "no" >&6; }
18774 test -n "$PROVE" && break
18778 # Report the value of PROVE in configure's output in all cases.
18779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PROVE" >&5
18780 $as_echo_n "checking for PROVE... " >&6; }
18781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROVE" >&5
18782 $as_echo "$PROVE" >&6; }
18785 if test -z "$PROVE"; then
18786 as_fn_error $? "prove not found" "$LINENO" 5
18792 # We have to run the thread test near the end so we have all our symbols
18793 # defined. Cross compiling throws a warning.
18795 if test "$enable_thread_safety" = yes; then
18796 if test "$PORTNAME" != "win32"
18798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking thread safety of required library functions" >&5
18799 $as_echo_n "checking thread safety of required library functions... " >&6; }
18803 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
18804 LIBS="$LIBS $PTHREAD_LIBS"
18805 if test "$cross_compiling" = yes; then :
18806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: maybe" >&5
18807 $as_echo "maybe" >&6; }
18808 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
18809 *** Skipping thread test program because of cross-compile build.
18810 *** Run the program in src/test/thread on the target machine.
18812 $as_echo "$as_me: WARNING:
18813 *** Skipping thread test program because of cross-compile build.
18814 *** Run the program in src/test/thread on the target machine.
18817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18818 /* end confdefs.h. */
18819 #include "$srcdir/src/test/thread/thread_test.c"
18821 if ac_fn_c_try_run "$LINENO"; then :
18822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18823 $as_echo "yes" >&6; }
18825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18826 $as_echo "no" >&6; }
18827 as_fn_error $? "thread test program failed
18828 This platform is not thread-safe. Check the file 'config.log' or compile
18829 and run src/test/thread/thread_test for the exact reason.
18830 Use --disable-thread-safety to disable thread safety." "$LINENO" 5
18832 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18833 conftest.$ac_objext conftest.beam conftest.$ac_ext
18839 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** skipping thread test on Win32" >&5
18840 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
18844 # If compiler will take -Wl,--as-needed (or various platform-specific
18845 # spellings thereof) then add that to LDFLAGS. This is much easier than
18846 # trying to filter LIBS to the minimum for each executable.
18847 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
18848 # libreadline; therefore we postpone testing it until we know what library
18849 # dependencies readline has. The test code will try to link with $LIBS.
18850 if test "$with_readline" = yes; then
18851 link_test_func=readline
18853 link_test_func=exit
18856 if test "$PORTNAME" = "darwin"; then
18857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
18858 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
18859 if ${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+:} false; then :
18860 $as_echo_n "(cached) " >&6
18862 pgac_save_LDFLAGS=$LDFLAGS
18863 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
18864 if test "$cross_compiling" = yes; then :
18865 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
18867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18868 /* end confdefs.h. */
18869 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18878 if ac_fn_c_try_run "$LINENO"; then :
18879 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
18881 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
18883 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18884 conftest.$ac_objext conftest.beam conftest.$ac_ext
18887 LDFLAGS="$pgac_save_LDFLAGS"
18889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
18890 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
18891 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
18892 LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
18895 elif test "$PORTNAME" = "openbsd"; then
18896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,-Bdynamic" >&5
18897 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
18898 if ${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+:} false; then :
18899 $as_echo_n "(cached) " >&6
18901 pgac_save_LDFLAGS=$LDFLAGS
18902 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
18903 if test "$cross_compiling" = yes; then :
18904 pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
18906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18907 /* end confdefs.h. */
18908 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18917 if ac_fn_c_try_run "$LINENO"; then :
18918 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
18920 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
18922 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18923 conftest.$ac_objext conftest.beam conftest.$ac_ext
18926 LDFLAGS="$pgac_save_LDFLAGS"
18928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
18929 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
18930 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
18931 LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
18935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -Wl,--as-needed" >&5
18936 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
18937 if ${pgac_cv_prog_cc_ldflags__Wl___as_needed+:} false; then :
18938 $as_echo_n "(cached) " >&6
18940 pgac_save_LDFLAGS=$LDFLAGS
18941 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
18942 if test "$cross_compiling" = yes; then :
18943 pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
18945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18946 /* end confdefs.h. */
18947 extern void $link_test_func (); void (*fptr) () = $link_test_func;
18956 if ac_fn_c_try_run "$LINENO"; then :
18957 pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
18959 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
18961 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18962 conftest.$ac_objext conftest.beam conftest.$ac_ext
18965 LDFLAGS="$pgac_save_LDFLAGS"
18967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
18968 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
18969 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
18970 LDFLAGS="$LDFLAGS -Wl,--as-needed"
18975 # Create compiler version string
18976 if test x"$GCC" = x"yes" ; then
18977 cc_string=`${CC} --version | sed q`
18978 case $cc_string in [A-Za-z]*) ;; *) cc_string="GCC $cc_string";; esac
18979 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
18980 cc_string=`${CC} -V 2>&1 | sed q`
18986 cat >>confdefs.h <<_ACEOF
18987 #define PG_VERSION_STR "PostgreSQL $PG_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
18991 # Supply a numeric version string for use by 3rd party add-ons
18992 # awk -F is a regex on some platforms, and not on others, so make "." a tab
18993 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
18995 $AWK '{printf "%d%04d", $1, $2}'`"
18997 cat >>confdefs.h <<_ACEOF
18998 #define PG_VERSION_NUM $PG_VERSION_NUM
19004 # Begin output steps
19006 { $as_echo "$as_me:${as_lineno-$LINENO}: using compiler=$cc_string" >&5
19007 $as_echo "$as_me: using compiler=$cc_string" >&6;}
19008 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS=$CFLAGS" >&5
19009 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
19010 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS=$CPPFLAGS" >&5
19011 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
19012 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS=$LDFLAGS" >&5
19013 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
19014 # Currently only used when LLVM is used
19015 if test "$with_llvm" = yes ; then
19016 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXX=$CXX" >&5
19017 $as_echo "$as_me: using CXX=$CXX" >&6;}
19018 { $as_echo "$as_me:${as_lineno-$LINENO}: using CXXFLAGS=$CXXFLAGS" >&5
19019 $as_echo "$as_me: using CXXFLAGS=$CXXFLAGS" >&6;}
19020 { $as_echo "$as_me:${as_lineno-$LINENO}: using CLANG=$CLANG" >&5
19021 $as_echo "$as_me: using CLANG=$CLANG" >&6;}
19022 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&5
19023 $as_echo "$as_me: using BITCODE_CFLAGS=$BITCODE_CFLAGS" >&6;}
19024 { $as_echo "$as_me:${as_lineno-$LINENO}: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&5
19025 $as_echo "$as_me: using BITCODE_CXXFLAGS=$BITCODE_CXXFLAGS" >&6;}
19028 # prepare build tree if outside source tree
19029 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
19030 # Note 2: /bin/pwd might be better than shell's built-in at getting
19031 # a symlink-free name.
19032 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
19036 if test "$no_create" != yes; then
19037 $as_echo_n "preparing build tree... " >&6
19038 pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
19039 $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
19040 || as_fn_error $? "failed" "$LINENO" 5
19041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
19042 $as_echo "done" >&6; }
19048 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
19051 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
19054 if test "$PORTNAME" = "win32"; then
19055 ac_config_commands="$ac_config_commands check_win32_symlinks"
19059 ac_config_headers="$ac_config_headers src/include/pg_config.h"
19062 ac_config_headers="$ac_config_headers src/include/pg_config_ext.h"
19065 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
19068 cat >confcache <<\_ACEOF
19069 # This file is a shell script that caches the results of configure
19070 # tests run on this system so they can be shared between configure
19071 # scripts and configure runs, see configure's option --config-cache.
19072 # It is not useful on other systems. If it contains results you don't
19073 # want to keep, you may remove or edit it.
19075 # config.status only pays attention to the cache file if you give it
19076 # the --recheck option to rerun configure.
19078 # `ac_cv_env_foo' variables (set or unset) will be overridden when
19079 # loading this file, other *unset* `ac_cv_foo' will be assigned the
19080 # following values.
19084 # The following way of writing the cache mishandles newlines in values,
19085 # but we know of no workaround that is simple, portable, and efficient.
19086 # So, we kill variables containing newlines.
19087 # Ultrix sh set writes to stderr and can't be redirected directly,
19088 # and sets the high bit in the cache file unless we assign to the vars.
19090 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19091 eval ac_val=\$$ac_var
19095 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19096 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19099 _ | IFS | as_nl) ;; #(
19100 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19101 *) { eval $ac_var=; unset $ac_var;} ;;
19107 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19108 *${as_nl}ac_space=\ *)
19109 # `set' does not quote correctly, so add quotes: double-quote
19110 # substitution turns \\\\ into \\, and sed turns \\ into \.
19113 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19116 # `set' quotes correctly as required by POSIX, so do not add quotes.
19117 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19126 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19128 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19130 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19131 if test -w "$cache_file"; then
19132 if test "x$cache_file" != "x/dev/null"; then
19133 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19134 $as_echo "$as_me: updating cache $cache_file" >&6;}
19135 if test ! -f "$cache_file" || test -h "$cache_file"; then
19136 cat confcache >"$cache_file"
19138 case $cache_file in #(
19140 mv -f confcache "$cache_file"$$ &&
19141 mv -f "$cache_file"$$ "$cache_file" ;; #(
19143 mv -f confcache "$cache_file" ;;
19148 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19149 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19154 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19155 # Let make expand exec_prefix.
19156 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19158 DEFS=-DHAVE_CONFIG_H
19163 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19164 # 1. Remove the extension, and $U if already installed.
19165 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19166 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19167 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19168 # will be set to the directory where LIBOBJS objects are built.
19169 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19170 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
19172 LIBOBJS=$ac_libobjs
19174 LTLIBOBJS=$ac_ltlibobjs
19179 : "${CONFIG_STATUS=./config.status}"
19181 ac_clean_files_save=$ac_clean_files
19182 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19183 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19184 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19186 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
19188 # Generated by $as_me.
19189 # Run this file to recreate the current configuration.
19190 # Compiler output produced by configure, useful for debugging
19191 # configure, is in config.log if it exists.
19194 ac_cs_recheck=false
19197 SHELL=\${CONFIG_SHELL-$SHELL}
19200 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19201 ## -------------------- ##
19202 ## M4sh Initialization. ##
19203 ## -------------------- ##
19205 # Be more Bourne compatible
19206 DUALCASE=1; export DUALCASE # for MKS sh
19207 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19210 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19211 # is contrary to our usage. Disable this feature.
19212 alias -g '${1+"$@"}'='"$@"'
19213 setopt NO_GLOB_SUBST
19215 case `(set -o) 2>/dev/null` in #(
19227 # Printing a long string crashes Solaris 7 /usr/bin/printf.
19228 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19229 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19230 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19231 # Prefer a ksh shell builtin over an external printf program on Solaris,
19232 # but without wasting forks for bash or zsh.
19233 if test -z "$BASH_VERSION$ZSH_VERSION" \
19234 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19235 as_echo='print -r --'
19236 as_echo_n='print -rn --'
19237 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19238 as_echo='printf %s\n'
19239 as_echo_n='printf %s'
19241 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19242 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19243 as_echo_n='/usr/ucb/echo -n'
19245 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19246 as_echo_n_body='eval
19250 expr "X$arg" : "X\\(.*\\)$as_nl";
19251 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19253 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19255 export as_echo_n_body
19256 as_echo_n='sh -c $as_echo_n_body as_echo'
19258 export as_echo_body
19259 as_echo='sh -c $as_echo_body as_echo'
19262 # The user is always right.
19263 if test "${PATH_SEPARATOR+set}" != set; then
19265 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19266 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19273 # We need space, tab and new line, in precisely that order. Quoting is
19274 # there to prevent editors from complaining about space-tab.
19275 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
19276 # splitting by setting IFS to empty value.)
19279 # Find who we are. Look in the path if we contain no directory separator.
19282 *[\\/]* ) as_myself=$0 ;;
19283 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19284 for as_dir in $PATH
19287 test -z "$as_dir" && as_dir=.
19288 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19294 # We did not find ourselves, most probably we were run as `sh COMMAND'
19295 # in which case we are not to be found in the path.
19296 if test "x$as_myself" = x; then
19299 if test ! -f "$as_myself"; then
19300 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19304 # Unset variables that we do not need and which cause bugs (e.g. in
19305 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19306 # suppresses any "Segmentation fault" message there. '((' could
19307 # trigger a bug in pdksh 5.2.14.
19308 for as_var in BASH_ENV ENV MAIL MAILPATH
19309 do eval test x\${$as_var+set} = xset \
19310 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19323 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19326 # as_fn_error STATUS ERROR [LINENO LOG_FD]
19327 # ----------------------------------------
19328 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19329 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
19330 # script with STATUS, using 1 if that was 0.
19333 as_status=$1; test $as_status -eq 0 && as_status=1
19335 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19336 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
19338 $as_echo "$as_me: error: $2" >&2
19339 as_fn_exit $as_status
19343 # as_fn_set_status STATUS
19344 # -----------------------
19345 # Set $? to STATUS, without forking.
19346 as_fn_set_status ()
19349 } # as_fn_set_status
19351 # as_fn_exit STATUS
19352 # -----------------
19353 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19357 as_fn_set_status $1
19363 # Portably unset VAR.
19366 { eval $1=; unset $1;}
19368 as_unset=as_fn_unset
19369 # as_fn_append VAR VALUE
19370 # ----------------------
19371 # Append the text in VALUE to the end of the definition contained in VAR. Take
19372 # advantage of any shell optimizations that allow amortized linear growth over
19373 # repeated appends, instead of the typical quadratic growth present in naive
19375 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19376 eval 'as_fn_append ()
19387 # as_fn_arith ARG...
19388 # ------------------
19389 # Perform arithmetic evaluation on the ARGs, and store the result in the
19390 # global $as_val. Take advantage of shells that can avoid forks. The arguments
19391 # must be portable across $(()) and expr.
19392 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
19393 eval 'as_fn_arith ()
19400 as_val=`expr "$@" || test $? -eq 1`
19405 if expr a : '\(a\)' >/dev/null 2>&1 &&
19406 test "X`expr 00001 : '.*\(...\)'`" = X001; then
19412 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
19413 as_basename=basename
19418 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
19424 as_me=`$as_basename -- "$0" ||
19425 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19426 X"$0" : 'X\(//\)$' \| \
19427 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
19429 sed '/^.*\/\([^/][^/]*\)\/*$/{
19443 # Avoid depending upon Character Ranges.
19444 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19445 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19446 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19447 as_cr_digits='0123456789'
19448 as_cr_alnum=$as_cr_Letters$as_cr_digits
19450 ECHO_C= ECHO_N= ECHO_T=
19451 case `echo -n x` in #(((((
19453 case `echo 'xy\c'` in
19454 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
19456 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
19463 rm -f conf$$ conf$$.exe conf$$.file
19464 if test -d conf$$.dir; then
19465 rm -f conf$$.dir/conf$$.file
19468 mkdir conf$$.dir 2>/dev/null
19470 if (echo >conf$$.file) 2>/dev/null; then
19471 if ln -s conf$$.file conf$$ 2>/dev/null; then
19473 # ... but there are two gotchas:
19474 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
19475 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
19476 # In both cases, we have to default to `cp -pR'.
19477 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
19479 elif ln conf$$.file conf$$ 2>/dev/null; then
19487 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
19488 rmdir conf$$.dir 2>/dev/null
19493 # Create "$as_dir" as a directory, including parents if necessary.
19498 -*) as_dir=./$as_dir;;
19500 test -d "$as_dir" || eval $as_mkdir_p || {
19504 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19505 *) as_qdir=$as_dir;;
19507 as_dirs="'$as_qdir' $as_dirs"
19508 as_dir=`$as_dirname -- "$as_dir" ||
19509 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19510 X"$as_dir" : 'X\(//\)[^/]' \| \
19511 X"$as_dir" : 'X\(//\)$' \| \
19512 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19513 $as_echo X"$as_dir" |
19514 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19518 /^X\(\/\/\)[^/].*/{
19531 test -d "$as_dir" && break
19533 test -z "$as_dirs" || eval "mkdir $as_dirs"
19534 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
19538 if mkdir -p . 2>/dev/null; then
19539 as_mkdir_p='mkdir -p "$as_dir"'
19541 test -d ./-p && rmdir ./-p
19546 # as_fn_executable_p FILE
19547 # -----------------------
19548 # Test if FILE is an executable regular file.
19549 as_fn_executable_p ()
19551 test -f "$1" && test -x "$1"
19552 } # as_fn_executable_p
19553 as_test_x='test -x'
19554 as_executable_p=as_fn_executable_p
19556 # Sed expression to map a string onto a valid CPP name.
19557 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
19559 # Sed expression to map a string onto a valid variable name.
19560 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
19564 ## ----------------------------------- ##
19565 ## Main body of $CONFIG_STATUS script. ##
19566 ## ----------------------------------- ##
19568 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
19570 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19571 # Save the log message, to keep $0 and so on meaningful, and to
19572 # report actual input values of CONFIG_FILES etc. instead of their
19573 # values after options handling.
19575 This file was extended by PostgreSQL $as_me 12devel, which was
19576 generated by GNU Autoconf 2.69. Invocation command line was
19578 CONFIG_FILES = $CONFIG_FILES
19579 CONFIG_HEADERS = $CONFIG_HEADERS
19580 CONFIG_LINKS = $CONFIG_LINKS
19581 CONFIG_COMMANDS = $CONFIG_COMMANDS
19584 on `(hostname || uname -n) 2>/dev/null | sed 1q`
19589 case $ac_config_files in *"
19590 "*) set x $ac_config_files; shift; ac_config_files=$*;;
19593 case $ac_config_headers in *"
19594 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
19598 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19599 # Files that config.status was made for.
19600 config_files="$ac_config_files"
19601 config_headers="$ac_config_headers"
19602 config_links="$ac_config_links"
19603 config_commands="$ac_config_commands"
19607 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19609 \`$as_me' instantiates files and other configuration actions
19610 from templates according to the current configuration. Unless the files
19611 and actions are specified as TAGs, all are instantiated by default.
19613 Usage: $0 [OPTION]... [TAG]...
19615 -h, --help print this help, then exit
19616 -V, --version print version number and configuration settings, then exit
19617 --config print configuration, then exit
19618 -q, --quiet, --silent
19619 do not print progress messages
19620 -d, --debug don't remove temporary files
19621 --recheck update $as_me by reconfiguring in the same conditions
19622 --file=FILE[:TEMPLATE]
19623 instantiate the configuration file FILE
19624 --header=FILE[:TEMPLATE]
19625 instantiate the configuration header FILE
19627 Configuration files:
19630 Configuration headers:
19633 Configuration links:
19636 Configuration commands:
19639 Report bugs to <pgsql-bugs@postgresql.org>."
19642 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19643 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
19645 PostgreSQL config.status 12devel
19646 configured by $0, generated by GNU Autoconf 2.69,
19647 with options \\"\$ac_cs_config\\"
19649 Copyright (C) 2012 Free Software Foundation, Inc.
19650 This config.status script is free software; the Free Software Foundation
19651 gives unlimited permission to copy, distribute and modify it."
19658 test -n "\$AWK" || AWK=awk
19661 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19662 # The default lists apply if the user does not specify any file.
19668 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19669 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
19673 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19685 # Handling of the options.
19686 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19688 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
19689 $as_echo "$ac_cs_version"; exit ;;
19690 --config | --confi | --conf | --con | --co | --c )
19691 $as_echo "$ac_cs_config"; exit ;;
19692 --debug | --debu | --deb | --de | --d | -d )
19694 --file | --fil | --fi | --f )
19697 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19698 '') as_fn_error $? "missing file argument" ;;
19700 as_fn_append CONFIG_FILES " '$ac_optarg'"
19701 ac_need_defaults=false;;
19702 --header | --heade | --head | --hea )
19705 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19707 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
19708 ac_need_defaults=false;;
19710 # Conflict between --help and --header
19711 as_fn_error $? "ambiguous option: \`$1'
19712 Try \`$0 --help' for more information.";;
19713 --help | --hel | -h )
19714 $as_echo "$ac_cs_usage"; exit ;;
19715 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19716 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19719 # This is an error.
19720 -*) as_fn_error $? "unrecognized option: \`$1'
19721 Try \`$0 --help' for more information." ;;
19723 *) as_fn_append ac_config_targets " $1"
19724 ac_need_defaults=false ;;
19730 ac_configure_extra_args=
19732 if $ac_cs_silent; then
19734 ac_configure_extra_args="$ac_configure_extra_args --silent"
19738 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19739 if \$ac_cs_recheck; then
19740 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
19742 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
19743 CONFIG_SHELL='$SHELL'
19744 export CONFIG_SHELL
19749 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19753 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19754 ## Running $as_me. ##
19760 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19763 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19765 # Handling of arguments.
19766 for ac_config_target in $ac_config_targets
19768 case $ac_config_target in
19769 "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
19770 "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
19771 "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
19772 "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
19773 "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
19774 "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
19775 "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
19776 "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
19777 "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
19778 "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
19779 "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
19780 "src/include/pg_config_ext.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config_ext.h" ;;
19781 "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
19783 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
19788 # If the user did not use the arguments to specify the items to instantiate,
19789 # then the envvar interface is used. Set only those that are not.
19790 # We use the long form for the default assignment because of an extremely
19791 # bizarre bug on SunOS 4.1.3.
19792 if $ac_need_defaults; then
19793 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19794 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19795 test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
19796 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19799 # Have a temporary directory for convenience. Make it in the build tree
19800 # simply because there is no reason against having it here, and in addition,
19801 # creating and moving files from /tmp can sometimes cause problems.
19802 # Hook for its removal unless debugging.
19803 # Note that there is a small window in which the directory will not be cleaned:
19804 # after its creation but before its name has been assigned to `$tmp'.
19808 trap 'exit_status=$?
19809 : "${ac_tmp:=$tmp}"
19810 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
19812 trap 'as_fn_exit 1' 1 2 13 15
19814 # Create a (secure) tmp directory for tmp files.
19817 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
19821 tmp=./conf$$-$RANDOM
19822 (umask 077 && mkdir "$tmp")
19823 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
19826 # Set up the scripts for CONFIG_FILES section.
19827 # No need to generate them if there are no CONFIG_FILES.
19828 # This happens for instance with `./config.status config.h'.
19829 if test -n "$CONFIG_FILES"; then
19832 ac_cr=`echo X | tr X '\015'`
19833 # On cygwin, bash can eat \r inside `` if the user requested igncr.
19834 # But we know of no other shell where ac_cr would be empty at this
19835 # point, so we can use a bashism as a fallback.
19836 if test "x$ac_cr" = x; then
19837 eval ac_cr=\$\'\\r\'
19839 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
19840 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
19843 ac_cs_awk_cr=$ac_cr
19846 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
19851 echo "cat >conf$$subs.awk <<_ACEOF" &&
19852 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
19854 } >conf$$subs.sh ||
19855 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19856 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
19858 for ac_last_try in false false false false false :; do
19859 . ./conf$$subs.sh ||
19860 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19862 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
19863 if test $ac_delim_n = $ac_delim_num; then
19865 elif $ac_last_try; then
19866 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
19868 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
19871 rm -f conf$$subs.sh
19873 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19874 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
19878 s/^/S["/; s/!.*/"]=/
19888 s/\(.\{148\}\)..*/\1/
19890 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
19895 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19902 s/\(.\{148\}\)..*/\1/
19904 s/["\\]/\\&/g; s/^/"/; s/$/"/
19908 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
19913 ' <conf$$subs.awk | sed '
19918 ' >>$CONFIG_STATUS || ac_write_fail=1
19919 rm -f conf$$subs.awk
19920 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19922 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
19923 for (key in S) S_is_set[key] = 1
19929 nfields = split(line, field, "@")
19931 len = length(field[1])
19932 for (i = 2; i < nfields; i++) {
19934 keylen = length(key)
19935 if (S_is_set[key]) {
19937 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
19938 len += length(value) + length(field[++i])
19949 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19950 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
19951 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
19954 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
19955 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
19958 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
19959 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
19960 # trailing colons and then remove the whole line if VPATH becomes empty
19961 # (actually we leave an empty line to preserve line numbers).
19962 if test "x$srcdir" = x.; then
19963 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
19981 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19982 fi # test -n "$CONFIG_FILES"
19984 # Set up the scripts for CONFIG_HEADERS section.
19985 # No need to generate them if there are no CONFIG_HEADERS.
19986 # This happens for instance with `./config.status Makefile'.
19987 if test -n "$CONFIG_HEADERS"; then
19988 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
19992 # Transform confdefs.h into an awk script `defines.awk', embedded as
19993 # here-document in config.status, that substitutes the proper values into
19994 # config.h.in to produce config.h.
19996 # Create a delimiter string that does not exist in confdefs.h, to ease
19997 # handling of long lines.
19999 for ac_last_try in false false :; do
20000 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
20001 if test -z "$ac_tt"; then
20003 elif $ac_last_try; then
20004 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
20006 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20010 # For the awk script, D is an array of macro values keyed by name,
20011 # likewise P contains macro parameters if any. Preserve backslash
20012 # newline sequences.
20014 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
20016 s/.\{148\}/&'"$ac_delim"'/g
20019 s/^[ ]*#[ ]*define[ ][ ]*/ /
20026 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20028 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
20032 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20033 D["\1"]=" \3\\\\\\n"\\/p
20035 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
20040 s/.\{148\}/&'"$ac_delim"'/g
20045 s/["\\]/\\&/g; s/^/"/; s/$/"/p
20048 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
20050 ' <confdefs.h | sed '
20051 s/'"$ac_delim"'/"\\\
20052 "/g' >>$CONFIG_STATUS || ac_write_fail=1
20054 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20055 for (key in D) D_is_set[key] = 1
20058 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
20060 split(line, arg, " ")
20061 if (arg[1] == "#") {
20065 defundef = substr(arg[1], 2)
20068 split(mac1, mac2, "(") #)
20070 prefix = substr(line, 1, index(line, defundef) - 1)
20071 if (D_is_set[macro]) {
20072 # Preserve the white space surrounding the "#".
20073 print prefix "define", macro P[macro] D[macro]
20076 # Replace #undef with comments. This is necessary, for example,
20077 # in the case of _POSIX_SOURCE, which is predefined and required
20078 # on some systems where configure will not decide to define it.
20079 if (defundef == "undef") {
20080 print "/*", prefix defundef, macro, "*/"
20088 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20089 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
20090 fi # test -n "$CONFIG_HEADERS"
20093 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :L $CONFIG_LINKS :C $CONFIG_COMMANDS"
20098 :[FHLC]) ac_mode=$ac_tag; continue;;
20100 case $ac_mode$ac_tag in
20102 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
20103 :[FH]-) ac_tag=-:-;;
20104 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20121 -) ac_f="$ac_tmp/stdin";;
20122 *) # Look for the file first in the build tree, then in the source tree
20123 # (if the path is not absolute). The absolute path cannot be DOS-style,
20124 # because $ac_f cannot contain `:'.
20128 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
20130 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
20132 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
20133 as_fn_append ac_file_inputs " '$ac_f'"
20136 # Let's still pretend it is `configure' which instantiates (i.e., don't
20137 # use $as_me), people would be surprised to read:
20138 # /* config.h. Generated by config.status. */
20139 configure_input='Generated from '`
20140 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
20142 if test x"$ac_file" != x-; then
20143 configure_input="$ac_file. $configure_input"
20144 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
20145 $as_echo "$as_me: creating $ac_file" >&6;}
20147 # Neutralize special characters interpreted by sed in replacement strings.
20148 case $configure_input in #(
20149 *\&* | *\|* | *\\* )
20150 ac_sed_conf_input=`$as_echo "$configure_input" |
20151 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20152 *) ac_sed_conf_input=$configure_input;;
20156 *:-:* | *:-) cat >"$ac_tmp/stdin" \
20157 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
20162 ac_dir=`$as_dirname -- "$ac_file" ||
20163 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20164 X"$ac_file" : 'X\(//\)[^/]' \| \
20165 X"$ac_file" : 'X\(//\)$' \| \
20166 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20167 $as_echo X"$ac_file" |
20168 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20172 /^X\(\/\/\)[^/].*/{
20185 as_dir="$ac_dir"; as_fn_mkdir_p
20189 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20191 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20192 # A ".." for each directory in $ac_dir_suffix.
20193 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20194 case $ac_top_builddir_sub in
20195 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20196 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20199 ac_abs_top_builddir=$ac_pwd
20200 ac_abs_builddir=$ac_pwd$ac_dir_suffix
20201 # for backward compatibility:
20202 ac_top_builddir=$ac_top_build_prefix
20205 .) # We are building in place.
20207 ac_top_srcdir=$ac_top_builddir_sub
20208 ac_abs_top_srcdir=$ac_pwd ;;
20209 [\\/]* | ?:[\\/]* ) # Absolute name.
20210 ac_srcdir=$srcdir$ac_dir_suffix;
20211 ac_top_srcdir=$srcdir
20212 ac_abs_top_srcdir=$srcdir ;;
20213 *) # Relative name.
20214 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20215 ac_top_srcdir=$ac_top_build_prefix$srcdir
20216 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
20218 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
20228 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20229 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
20231 ac_MKDIR_P=$MKDIR_P
20233 [\\/$]* | ?:[\\/]* ) ;;
20234 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
20238 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20239 # If the template does not know about datarootdir, expand it.
20240 # FIXME: This hack should be removed a few years after 2.60.
20241 ac_datarootdir_hack=; ac_datarootdir_seen=
20252 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20253 *datarootdir*) ac_datarootdir_seen=yes;;
20254 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20255 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20256 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
20258 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20259 ac_datarootdir_hack='
20260 s&@datadir@&$datadir&g
20261 s&@docdir@&$docdir&g
20262 s&@infodir@&$infodir&g
20263 s&@localedir@&$localedir&g
20264 s&@mandir@&$mandir&g
20265 s&\\\${datarootdir}&$datarootdir&g' ;;
20269 # Neutralize VPATH when `$srcdir' = `.'.
20270 # Shell code in configure.ac might set extrasub.
20271 # FIXME: do we really want to maintain this feature?
20272 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20273 ac_sed_extra="$ac_vpsub
20276 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20278 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20279 s|@configure_input@|$ac_sed_conf_input|;t t
20280 s&@top_builddir@&$ac_top_builddir_sub&;t t
20281 s&@top_build_prefix@&$ac_top_build_prefix&;t t
20282 s&@srcdir@&$ac_srcdir&;t t
20283 s&@abs_srcdir@&$ac_abs_srcdir&;t t
20284 s&@top_srcdir@&$ac_top_srcdir&;t t
20285 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20286 s&@builddir@&$ac_builddir&;t t
20287 s&@abs_builddir@&$ac_abs_builddir&;t t
20288 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20289 s&@INSTALL@&$ac_INSTALL&;t t
20290 s&@MKDIR_P@&$ac_MKDIR_P&;t t
20291 $ac_datarootdir_hack
20293 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
20294 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20296 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
20297 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
20298 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
20299 "$ac_tmp/out"`; test -z "$ac_out"; } &&
20300 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20301 which seems to be undefined. Please make sure it is defined" >&5
20302 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
20303 which seems to be undefined. Please make sure it is defined" >&2;}
20305 rm -f "$ac_tmp/stdin"
20307 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
20308 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
20310 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20316 if test x"$ac_file" != x-; then
20318 $as_echo "/* $configure_input */" \
20319 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
20320 } >"$ac_tmp/config.h" \
20321 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20322 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
20323 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
20324 $as_echo "$as_me: $ac_file is unchanged" >&6;}
20327 mv "$ac_tmp/config.h" "$ac_file" \
20328 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
20331 $as_echo "/* $configure_input */" \
20332 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
20333 || as_fn_error $? "could not create -" "$LINENO" 5
20341 if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
20344 # Prefer the file from the source tree if names are identical.
20345 if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
20346 ac_source=$srcdir/$ac_source
20349 { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
20350 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
20352 if test ! -r "$ac_source"; then
20353 as_fn_error $? "$ac_source: file not found" "$LINENO" 5
20357 # Try a relative symlink, then a hard link, then a copy.
20359 [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
20360 *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
20362 ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
20363 ln "$ac_source" "$ac_file" 2>/dev/null ||
20364 cp -p "$ac_source" "$ac_file" ||
20365 as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
20368 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
20369 $as_echo "$as_me: executing $ac_file commands" >&6;}
20374 case $ac_file$ac_mode in
20375 "check_win32_symlinks":C)
20376 # Links sometimes fail undetected on Mingw -
20377 # so here we detect it and warn the user
20378 for FILE in $CONFIG_LINKS
20380 # test -e works for symlinks in the MinGW console
20381 test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** link for $FILE -- please fix by hand" >&5
20382 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
20385 "src/include/pg_config.h":H)
20386 # Update timestamp for pg_config.h (see Makefile.global)
20387 echo >src/include/stamp-h
20389 "src/include/pg_config_ext.h":H)
20390 # Update timestamp for pg_config_ext.h (see Makefile.global)
20391 echo >src/include/stamp-ext-h
20393 "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
20401 ac_clean_files=$ac_clean_files_save
20403 test $ac_write_fail = 0 ||
20404 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
20407 # configure is writing to config.log, and then calls config.status.
20408 # config.status does its own redirection, appending to config.log.
20409 # Unfortunately, on DOS this fails, as config.log is still kept open
20410 # by configure, so config.status won't be able to write to it; its
20411 # output is simply discarded. So we exec the FD to /dev/null,
20412 # effectively closing config.log, so it can be properly (re)opened and
20413 # appended to by config.status. When coming back to configure, we
20414 # need to make the FD available again.
20415 if test "$no_create" != yes; then
20417 ac_config_status_args=
20418 test "$silent" = yes &&
20419 ac_config_status_args="$ac_config_status_args --quiet"
20421 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
20423 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20424 # would make configure fail if this is the last instruction.
20425 $ac_cs_success || as_fn_exit 1
20427 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
20428 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
20429 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}